求解旅行商问题的不同交叉算子(IJISA-V7-N11-3)
遗传算法解决旅行商问题求解复杂性思考

遗传算法解决旅行商问题求解复杂性思考旅行商问题(Traveling Salesman Problem,TSP)是一个经典的组合优化问题,主要涉及在给定一组城市和其之间的距离的情况下,寻找最短路径,使得旅行商可以访问每个城市并返回起始城市。
由于需要考虑全排列的情况,TSP在计算上通常是一个复杂且困难的问题。
遗传算法(Genetic Algorithm,GA)是一种模拟自然进化的算法。
在解决复杂问题时,遗传算法模拟了生物进化的基本原理,通过自然选择和遗传操作,逐代优化个体的适应度,从而找到解决问题的最佳解。
在使用遗传算法解决TSP时,个体通常表示为城市的排列序列,适应度函数定义为这个序列所对应路线的总长度。
下面将从两个方面对遗传算法解决TSP的复杂性进行思考:问题的复杂性和算法的复杂性。
首先,旅行商问题本身是一个NP-hard问题。
NP-hard问题是指在多项式时间内无法求解的问题。
TSP的复杂性由于需要考虑所有城市间的距离,而随着城市数量的增加,问题的规模呈指数级增长。
这导致在实际情况下,对于较大规模的TSP 问题,找到最优解是非常困难的。
遗传算法作为一种启发式算法,能够找到较好的近似解,在解决复杂问题时取得了较好的效果。
遗传算法通过不断迭代演化种群,逐步优化解的质量。
但是,由于TSP问题本身的困难性,遗传算法无法保证找到全局最优解,因为它受限于初始种群和搜索空间的选择。
此外,遗传算法的收敛速度也受到问题规模的影响。
其次,遗传算法本身也具有一定的复杂性。
需要设置合适的参数,如种群大小、交叉率、变异率等,以及遗传操作的策略。
不同的参数和策略选择可能导致不同的解决效果。
因此,在应用遗传算法解决TSP问题时,需要进行合理的参数配置和算法优化。
在实际应用中,基于遗传算法的TSP求解器已经取得了一定的成果。
通过对问题进行合理的建模和参数调优,可以在可接受的时间内得到较优的解。
此外,还有许多改进的遗传算法策略可以用于提高求解效率,如多父代遗传算法、局部搜索等。
算法论文:旅行商问题的求解方法(动态规划法和贪心法)讲解

旅行商问题的求解方法摘要旅行商问题(TSP问题)时是指旅行家要旅行n个城市然后回到出发城市,要求各个城市经历且仅经历一次,并要求所走的路程最短。
该问题又称为货郎担问题、邮递员问题、售货员问题,是图问题中最广为人知的问题。
本文主要介绍用蛮力法、动态规划法、贪心法和分支限界法求解TSP问题,其中重点讨论动态规划法和贪心法,并给出相应求解程序。
关键字:旅行商问题;动态规划法;贪心法;分支限界法1引言旅行商问题(TSP)是组合优化问题中典型的NP-完全问题,是许多领域内复杂工程优化问题的抽象形式。
研究TSP的求解方法对解决复杂工程优化问题具有重要的参考价值。
关于TSP的完全有效的算法目前尚未找到,这促使人们长期以来不断地探索并积累了大量的算法。
归纳起来,目前主要算法可分成传统优化算法和现代优化算法。
在传统优化算法中又可分为:最优解算法和近似方法。
最优解算法虽然可以得到精确解,但计算时间无法忍受,因此就产生了各种近似方法,这些近似算法虽然可以较快地求得接近最优解的可行解,但其接近最优解的程度不能令人满意。
但限于所学知识和时间限制,本文重点只讨论传统优化算法中的动态规划法、贪心法和分支限界法,并对蛮力法做简单介绍,用以比较。
2正文2.1蛮力法2.1.1蛮力法的设计思想蛮力法所依赖的基本技术是扫描技术,即采用一定的策略将待求解问题的所有元素一次处理一次,从而找出问题的解。
一次处理所有元素的是蛮力法的关键,为了避免陷入重复试探,应保证处理过的元素不再被处理。
在基本的数据结构中,一次处理每个元素的方法是遍历。
2.1.2算法讨论用蛮力法解决TSP问题,可以找出所有可能的旅行路线,从中选取路径长度最短的简单回路。
如对于图1,我们求解过程如下:(1)路径:1->2->3->4->1;路径长度:18;(2)路径:1->2->4->3->1;路径长度:11;(3)路径:1->3->2->4->1;路径长度:23;(4)路径:1->3->4->2->1;路径长度:11;(5) 路径:1->4->2->3->1;路径长度:18;(6) 路径:1->4->3->2->1;路径长度:18;从中,我们可以知道,路径(2)和(4)路径长度最短。
求解旅行商问题的几种智能算法

3 收稿日期 :2009 年 9 月 25 日 ,修回日期 :2009 年 10 月 18 日 作者简介 :朱献文 ,女 ,硕士研究生 ,研究方向 :人工智能 ,人工生命 。李福荣 ,女 ,硕士研究生 ,研究方向 :软件工程 。
© 1994-2010 China Academic Journal Electronic Publishing House. All rights reserved.
1) 初始化每条路径上的信息素浓度 。 2) 把 m 只蚂蚁随机的放在 n 个城市上 。 3) 让每一只蚂蚁根据概率函数寻找出一条可 行的路径 。概率函数一般由两个城市间的距离以 及两城市间的信息素浓度所构成 。 4) 计算出 m 只蚂蚁所找到的路径的长度 ,并 选出本次最优路径 。 5) 根据本次蚂蚁的访问情况 ,更新本次最优 路径每条边上的信息素浓度 。 6) 判断算法是否满足终止条件 ,若满足则输 出结果 ,否则转到步骤 2) 。 蚁群算法的优点是它同时具有自适应 、自组 织 、正向反馈 、本质并行的特点 ,但是其搜索时间较 长 ,而且容易因为受到寻优过程中早期发现的较好 解的影响而陷入局部最优解 ,使搜索停滞 。 3. 3 Hopfield 神经网络 Hopfield 神经网络是 1982 年由美国物理学家 Hopfield 教授提出的一种单层反馈神经网络 ,并在 1985 年将其应用于 TSP 问题的求解[6] 。该方法将 问题的合法解映射为一个换位矩阵 ,并构造合适的 能量函数 。随着网络状态的变化 ,其能量不断减 少 ,最后达到平衡时 ,将得到一个局部最优解 ,即满 足换位矩阵要求的能量函数的最小值与问题的最 优解相对应 。该算法求解 TSP 问题的步骤为[7] : 1) 把 TSP 问题映射为换位矩阵 ,表示每一条 可能路径 ,并写出相应的距离表达式 。 2) 把 TSP 问题的换位矩阵集合与 N2 神经元
建模经典问题——旅行商问题图文 文档全文预览

目录第7章 旅行商问题1.问题概述2.求解算法2.1.下界和上界算法2.2.分支定界法2.3.动态规划法2.5.近似算法2.5.竞赛题
2
§7-1 问题概述一 、数学模型1.标准TSP旅行商问题(简称TSP ), 也称货郎担问题或 旅行推销员问题,是运筹学中一个著名的问题,其 一般提法为:有一个旅行商从城市1出发,需要到 城市2、3、 …、n 去推销货物,最后返回城市1,若 任意两个城市间的距离已知,则该旅行商应如何选 择其最佳行走路线?
18
TS 多面体研究中的一个重要问题就是寻找能导出Q” 最大面的不等式, Grotschel 等人发现了一类很重要的能导 出最大面的梳子不等式,并予以了证明。此外,还有其它 能导出最大面的不等式,如团树不等式等。可见, Q" 的最 大面极多,曾经计算过由梳子不等式所导出的最大面个数 如表7-1所示:表 7 - 1
27
对结点i的e(i)1, 边e(i)1 的一个结点为i, 另 一 个结点为j=dmi n_j(i,1), 若e(i)1 也是结点j 关联边 中最小的两条边之一,即i =dmin_j(j,1) 或 i=dmin_j(j,2 ), 则对边e(i)1 来说就不需要调整,否则 按以下方式调整:
8
从严格的数学意义而言,瓶颈TSP (简称BTSP )并没有降低问题的难度,也未能提供任何特殊的解决 办法。瓶颈TSP的数学模型与标准TSP类似,仅目标函 数不同:min Z=max{d,·xi|i,jeV}
由于目标函数为瓶颈值,故求得的最佳巡回路 线与标准TSP的往往截然不同。
16
称X为路线T的关联向量,其m=n(n-2)/2 个分量中,恰好 有个为1,其余的都为0。图有许多H amilt on回路,设为T₁.T₂.…T,, 对应的关联向 量记为X₁,X₂…X 。, 在m维空间Rm中,考虑这些向量生成的 凸包( convex hull) Q":
组合优化中的旅行商问题求解

组合优化中的旅行商问题求解在组合优化领域中,旅行商问题(Traveling Salesman Problem,TSP)是一类具有重要实际应用价值和理论研究意义的问题。
该问题要求在给定一系列城市和各城市之间的距离情况下,找到一条最短路径,使得旅行商能够恰好访问每个城市一次,并最终回到出发城市。
TSP在计算机科学、运筹学和数学等多个领域都得到了广泛的关注和研究。
1. TSP的数学建模旅行商问题可以用图论中的图来描述和解决。
首先,我们将每个城市表示为图中的一个节点,城市之间的距离表示为节点之间的边。
若每对节点之间的边都有权重,表示相应城市之间的距离,旅行商问题就可以转化为求解图的最短哈密顿回路(Hamiltonian cycle)的问题。
2. 求解TSP的经典算法2.1 蛮力算法蛮力算法是最简单直观的求解TSP的方法,它遍历所有可能的路径,并计算出总的路径长度,然后选择最短路径作为解。
然而,蛮力算法的时间复杂度为O(n!),当城市数量增加时,计算时间将呈指数级增长,因此适用于城市数量较少的情况。
2.2 最邻近插入算法最邻近插入算法从一个起始城市开始,每次选择离当前城市最近的未访问城市作为下一个访问城市,直到访问完所有城市,并回到起始城市。
该算法的时间复杂度为O(n^2),但它可能会得到次优解,因为贪心策略在选择下一个城市时只考虑了当前状态,没有考虑到整体最优解。
2.3 分支限界法分支限界法是一种基于回溯的求解TSP的优化方法,其思想是通过剪枝操作,去掉一些分支,从而减少搜索空间。
该算法首先选择一个起始城市,然后逐步扩展路径,每次选择一个未访问的城市,并通过计算路径长度来更新当前最优路径。
同时,在搜索过程中,根据当前路径长度和已知的最短路径长度,进行剪枝操作,以减少无效的计算。
分支限界法可以得到较优的解,但其时间复杂度仍然较高,因此在处理大规模问题时可能会面临困难。
3. 近似算法及元启发式算法为了求解大规模问题或提高求解效率,研究者们提出了许多近似算法和元启发式算法。
旅行商问题的动态顺序插入交叉算子的研究

旅行 商 问题 的动 态顺 序 插入 交叉 算子 的研 究
孙 海 雷 , 琼荪 , 刘 胡上尉
( 重庆大学 数理学院, 重庆 4 03 ) 000
摘
(u h i i 7 13 c m sn al0 @ .o ) e0 6 要: 针对 旅行 商 (S ) T P 问题 的特点 , 遗传 算法 的 交叉 过程 中对 边 的邻接 状 况采 用 了新 的评 在
维普资讯
第2 7卷 第 3期
20 0 7年 3月
文 章 编 号 :0 1— o l 20 )3— 6 3 0 10 9 8 (0 7 0 0 3 — 2
计 算 机应 用
Co mpue p ia in trAp lc to s
Vo . 7 No 3 12 .
Abtat codn ec aatrt so t vl a s npo l ( S ) e r svr prt ,dnmi odr s c:A cri t t h r e sc f r e l ma r e T P ,anw co oe oea r ya c re r g oh c i i a s e bm s o i et rsoe ( O C prt ,w s ei e ,w i o ie re srcosvr n sdteged e ci t tg n rc svr D I)o a o a s n d h hcmb dodrne r oe due r y l tnsa y s o e r d g c n i t s a h e s e o re
连接状 态 , 每边赋予权重 , 即城 市问的距 离) 设 D是 由顶 点 i , 到达顶点 间的距 离所组成 的距 离矩 阵, 之 如果任意两个城 市
基于遗传算法的旅行商问题的求解研究

基于遗传算法的旅行商问题的求解研究旅行商问题是指给定一组城市以及任意两个城市之间的距离,求解一个最短路径,使得旅行商可以依次经过每个城市并最终返回起始城市。
由于旅行商问题属于NP-hard问题,传统的求解方法往往需要枚举所有可能的路径,导致计算复杂度非常高。
因此,本文将讨论采用遗传算法来解决旅行商问题的研究。
遗传算法是一种模拟自然进化过程的优化算法,其中涉及到种群的初始化、个体的选择、交叉和变异等操作。
在应用遗传算法求解旅行商问题时,首先需要构建一个由候选解(也称为个体)组成的初始种群。
一个候选解可以被表示为一个按顺序排列的城市序列。
接下来,根据某种适应度函数(也称为评估函数),对每个个体进行评估,得到其适应度值。
适应度值可以根据个体的路径总长度来计算,即越短路径的个体适应度值越高。
然后,根据适应度值,选择一定数量的个体作为父代,进行交叉和变异操作,生成新的个体,并加入到下一代种群中。
通过多次迭代,不断更新种群,直到达到停止条件,得到一个较优的解。
在实际应用中,采用遗传算法求解旅行商问题存在一些关键问题需要考虑。
首先,需要确定合适的编码方式来表示候选解。
常见的编码方式有二进制编码、格雷编码和排列编码等,其中排列编码适用于本文所要解决的问题。
其次,选择适当的交叉和变异操作对种群进行演化。
交叉操作可以将两个父代的个体部分基因交换,以产生新的个体;而变异操作可以随机改变个体中的某些基因,以增加个体的多样性。
此外,还需要确定合适的停止条件,以便算法能够在合理的时间内终止。
在实验研究中,可以选择一些经典的旅行商问题实例进行测试和比较。
例如,可以选取德国柏林52个城市的旅行商问题实例,使用遗传算法进行求解,并与其他经典算法进行对比,如蚁群算法、模拟退火算法等。
通过比较不同算法的求解结果和效率,可以评估遗传算法在旅行商问题上的优势和不足之处。
此外,为了进一步提高遗传算法的求解效果,还可以采用一些改进的策略。
例如,引入不同的种群选择策略,如轮盘赌选择、锦标赛选择等,以增加选择的随机性和多样性。
遗传算法求解旅行商问题

遗传算法求解旅行商问题程荣北京电子科技职业学院北京100176摘要:旅行商问题是一个组合优化问题,具有重要的实际意义。
而遗传算法是求解旅行商问题的典型算法之一。
本文首先 介绍了旅行商问题的定义以及它的研究背景、发展现状和常用算法。
在此基础上,详细阐述了遗传算法原理。
通过改进这些算 子,改进了传统的遗传算法,提高了算法的效率,降低了它的时间及空间复杂度。
本文使用路径总长度的倒数作为适应度函数,保 证了解向着最优化方向发展。
然后选择部分交叉算子来产生新个体,保证了迭代的效率。
变异算子利用位点变异,使算法变得简 单,易行。
最后,使用MATLAB 语言进行编程,解决了城市数目分别为15和25时的两个实际问题。
通过对这两个问题的收敛速4科教论坛_________________________________________________________________________________科技风2017年8月下D 01:10.19392/j. cnki. 1671-7341.201716037度的对比、分析,总结了遗传算法求解旅行商问题的特点。
关键词!旅行商问题;遗传算法;MATLAB 旅行商问题是优化组合问题研究中一个著名而经典的问 题,它的研究价值也就不言而喻。
在实际问题里,一个大家都 熟知的例子就是利用机器给电路板钻孔的优化设计问题。
此 外旅行商问题的实际应用还体现在交通管理规划方面。
交通 管理的主要的目的是在复杂的地理网络结构中优化决定车辆 的线路来减少交通费用。
旅行商问题的应用例子还包括:设计 安全,合理,有效率的交通网,从而减少交通拥堵;如何来规划 出更好地物流线路,缩小运营界产生的成本,减少资源消耗等。
由于旅行商问题具有这么重要的实际意义,求解旅行商问 题算法也就随之发展起来。
最早的解决方法是线性规划,后来 陆续产生了多种求解旅行商问题的算法。
其中大致可以分为 精确算法,近似算法,智能算法。
- 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
- 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
- 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
I.J. Intelligent Systems and Applications, 2015, 11, 19-25Published Online October 2015 in MECS (/)DOI: 10.5815/ijisa.2015.11.03Assessing Different Crossover Operators for Travelling Salesman ProblemImtiaz Hussain KhanDepartment of Computer Science, King Abdulaziz University Jeddah, P.O.Box 80200, Saudi ArabiaE-mail: ihkhan@.saAbstract—Many crossover operators have been proposed in literature on evolutionary algorithms, however, it is still unclear which crossover operator works best for a given optimization problem. In this study, eight different crossover operators specially designed for travelling salesman problem, namely, Two-Point Crossover, Partially Mapped Crossover, Cycle Crossover, Shuffle Crossover, Edge Recombination Crossover, Uniform Order-based Crossover, Sub-tour Exchange Crossover, and Sequential Constructive Crossover are evaluated empirically. The select crossover operators were implemented to build an experimental setup upon which simulations were run. Four benchmark instances of travelling salesman problem, two symmetric (ST70 and TSP225) and two asymmetric (FTV100 and FTV170), were used to thoroughly assess the select crossover operators. The performance of these operators was analyzed in terms of solution quality and computational cost. It was found that Sequential Constructive Crossover outperformed other operators in attaining 'good' quality solution, whereas Two-Point Crossover outperformed other operators in terms of computational cost. It was also observed that the performance of different crossover operators is much better for relatively small number of cities, both in terms of solution quality and computational cost, however, for relatively large number of cities their performance greatly degrades.Index Terms—Crossover Operators, Travelling Salesman Problem, Evaluation of Crossover Operators, Evolutionary Algorithms.I.I NTRODUCTIONDifferent evolutionary techniques [1-3] have been proposed in literature to solve complex optimization problems. These techniques differ in implementation, but, all of them have very similar formalization of the problem. They start by an initial population of candidate solutions and then apply nature-inspired variation and selection mechanism on select candidate solutions to produce new solutions (offspring), in an iterative fashion. The process is repeated unless some stopping criteria are met. The central idea is that the solutions with better fitness value (according to a given fitness function) will guide the search process towards the optimal solution in the search space. The sketch of an evolutionary algorithm is depicted in Fig. 1.At the heart of these algorithms is a crossover operator which introduces variation in the population in a systematic way. The crossover operator is stochastic (i.e., probabilistic based) which merges information from two or more parents to produce one or more offspring. Crossover serves two complementary search abilities: exploitation and exploration. That is, it provides new points for further testing upon hyper planes already represented in the population (exploitation), and it also introduces representatives of new hyper planes into the population (exploration).Fig.1. Schematic diagram of an evolutionary algorithmIn literature, different crossover operators have been proposed: Two-Point Crossover (TPX) [4], Partially Mapped Crossover (PMX) [5], Cycle Crossover (CX) [6], Shuffle Crossover (SX) [7], Edge Recombination Crossover (ERX) [8], Uniform Order-based Crossover (UOX) [9], Sub-tour Exchange Crossover (SEX) [10], and Sequential Constructive Crossover (SCX) [11]. These operators have primarily been designed to solve one of the most widely studied optimization problem, Traveling Salesman Problem (TSP), however, they can be adapted to solve other complex optimization problems as well, e.g. scheduling problem.In this study, the above-mentioned crossover operators are empirically evaluated against four benchmark instances of travelling salesman problem, two symmetric and two asymmetric instances.The rest of this article is organized as follows. In Section 2, we give a background overview ofdifferentcrossover operators. The evaluation criteria and test problems are described in Section 3. The empirical study is outlined in Section 4, followed by discussion in Section 5. The article concludes in Section 6.II. B ACKGROUND AND R ELATED W ORK Different crossover operators have been proposed in literature on evolutionary algorithms, and different studies have been conducted to evaluate the performance of these operators. In [15], the authors compared ten different crossover operators on numerical optimization problems. The select crossover operators are used in genetic algorithms with binary representation. They found that both uniform crossover and reduced surrogate crossover offer competitive performance. In another study [16] , the authors compared the performance of eight different crossover operators on vehicle routing problem. They reported that the best performance was achieved by combining the different crossover operators, whereas the individual performance of the different operators was not good enough to solve the vehicle routing problem. In [17], the authors proposed three crossover operators, namely GA-like one-point, sub-tree, and semantic aware sub-tree, for postfix genetic programming. They evaluated the performance of these on select real-valued symbolic regression problems. They found that the semantic aware sub-tree crossover is best among the three crossover operators.In what follows, we review the most commonly used crossover operators to solve TSP.A. Two-point CrossoverTwo-Point Crossover (TPX) is a typical form of n-point crossover proposed by De Jong [4]. In TPX, two crossover points are pseudo-randomly selected at the same position from each parent chromosome. The parent chromosomes are then split at the crossover points chosen and all data beyond the two select points in either chromosomes is swapped between the two parent chromosomes effectively yielding two offspring.B. Partially Mapped CrossoverPartially Mapped Crossover (PMX) [5] is a two-point crossover. However, unlike the standard two-point crossover as described above, PMX yields one offspring as follows. Two crossover points are selected at the same position from each parent chromosome, and then in a first step the genes are copied from the second parent between the two cut points to the offspring. Then, in a second step, the remaining genes in the offspring before and after the cut point are copied from the first parent in the order in which they appear therein. In case, a gene has already been provided by the second parent (in the first step), the corresponding (i.e. mapped) genes are copied from the first parent, hence the term partially mapped.C. Cycle CrossoverCycle Crossover (CX) [6] generates offspring by first identifying cycles between two parent chromosomes, and then these cycles are copied from the respective parent chromosomes to form offspring. At the heart of CX is a cycle formation method which works as follows. It starts with the first gene of the first parent, visits the gene at the same position of the second parent, and then goes to the position with the same gene in the first parent, effectively forming a cycle. The same process is repeated to form the remaining cycles. Finally, the indices that form a cycle are used to produce offspring in alternating order.D. Shuffle CrossoverShuffle Crossover (SX) [7] is a variant of one-point crossover in which, first, the genes are pseudo-randomly shuffled in the parents before applying the crossover. Then after recombination, the genes are shuffled back in reverse order, in the offspring.E. Edge Recombination CrossoverEdge Recombination Crossover (ERX) [8] operator starts by constructing an edge map from nodes which lists all the incoming and outgoing connections for two parents. If a node appears twice, it is marked negative to signify a common edge. This edge map is subsequently used to generate offspring in such a way that the parent structure be preserved as much as possible. The nodes having negative values or with the fewest remaining adjacent nodes are selected before the nodes with more adjacent nodes.F. Uniform Order-based CrossoverUniform Order-based Crossover (UOX) [9] is different than other crossover operators as it uses a uniform crossover mask (0s and 1s) to construct offspring. In a first cycle, the operator copies genes from the first parent in the slots where the mask has a 1. Then in a second cycle, the remaining genes are copied in the order they appear in the second parent to complete the empty slots in the offspring.G. Sub-tour Exchange CrossoverSub-tour Exchange Crossover (SEX) developed by Yamamura [10] is used to solve a problem with vary huge data like TSP. It starts by identifying sub-tours including common nodes in both parents. Then, it constructs offspring by copying parents' paths and exchanging the subtours. This crossover operator tends to preserve parent structure by inheriting edges from parents.H. Sequential Constructive CrossoverThe Sequential Constructive Crossover (SCX) [11] operator constructs an offspring from a pair of parents using better edges in the parents. SCX also uses the better edges even if they are not in the parents’ structure, which permits it to introduce new and good edges to the offspring. The SCX operator works as follows. It starts with the first node, say s, in the first parent and searches sequentially through each parent to find a legitimate node (not visited yet) in each parent. Suppose the nodes x and y are found as legitimate nodes, the operator constructs a new edge (s, x) if distance(s, x) < distance(s, y),otherwise the new edge (s, y) is constructed. The process is repeated until the offspring is completed. Since the operator preserves the good edges from each parent and also introduces some better edges, it guides the search towards an optimal solution.III.P ERFORMANCE M EASURE AND E VALUATIONB ENCHMARKDifferent evaluation measures have been suggested in literature to measure the performance of an evolutionary algorithm. In this study, solution quality expressed in terms of cost-minimization is considered the only performance measure. The performance of the select crossover operators was evaluated against one of the most widely studied optimization problem, TSP. TSP is an NP-hard combinatorial optimization problem, in which a salesman has to visit N cities (nodes) by starting the trip from a given city and returning back to the starting city to complete a tour. The constraint is that each and every city should be visited, and it should be visited exactly once. The objective is to find a minimum length tour, which captures resemblance of different real life cost-minimization problems like spreading a wide-area network. Two types of TSP problems are generally studied: Symmetric TSP and Asymmetric TSP. In a symmetric TSP, the distance between two node x and y is the same as the distance between y and x, whereas in an asymmetric TSP the distance between two node x and y may be different than the distance between y and x. Four benchmark instances of TSP were solved, two symmetric and two asymmetric. The two symmetric instances were ST70 (70 cities) and TSP225 (225 cities), the asymmetric instances were FTV100 (100 cities) and FTV170 (170 cities) [15]. The best known solutions for these problem instances are: 675, 3919, 1788, 2755, respectively [18].IV.T HE E XPERIMENTA. Experimental SetupWe implemented the system in Matlab-R2009a to run the simulations on a Sony Vaio Core i5-2430M, with 2.4 GHz speed and 4 GB RAM (DDR3). A brief description of this implementation is outlined below.∙The solutions were encoded as permutation vectors, where the length of a solution (tour) wasthe number of nodes in the respective probleminstance.∙The fitness function was tour length realized as distance between the adjacent cities; the objectivewas to find the minimum cost tour.∙Initial population was sampled randomly; the population size was kept 100 throughout the study. ∙Parent selection was realized probabilistically asroulette wheel indexes to calculate probabilities asinverse distances divided by sum of inversedistances (of all candidate solutions in the currentpopulation).∙Crossover and mutation probabilities were kept 0.8 and 0.01 [19], respectively, throughout this study. ∙An elitism based survivor selection was implemented, which guarantees that the bestsolutions from the current generation carry over tothe next generation, unaltered.∙The maximum number of generations were kept 50000 throughout the study.In each generation, best and average fitness of population were recorded, similar in spirit to [20], for each crossover operator.B. Results and AnalysisThe simulation results in terms of solution quality and speed were recorded for the competing crossover operators on the select problem. We measured the quality of a solution in terms of percentage surplus error value as shown in Equation 1, where optimal value is the known global optimum.Error=(solution value−optimal value)optimal value∗100 (1)An ANOVA test was also administered to test whether the apparent differences in the performance gain are statistically significant or not. Table 1 shows the solution-quality results averaged over 20 independent runs, including the overall best solution (Best), the mean of best-of-run solution averaged over 20 runs (Mean), and the standard deviation in best-of-run solution (Std Dev). The results indicate that overall the Sequential Constructive Crossover (SCX) outperformed all other crossover operators, with Edge Recombination Crossover (ERX) offering worst performance. These results are also evident from Fig. 2 and Fig. 3, which depict the evolutions of solutions TSP-70 cities and TSP-100 cities instances, respectively. An ANOVA analysis further revealed that the solution-quality results differed significantly across different crossover operators for the four select problem instances: F (7, 31) = 2.94, F-critical = 2.42, p < 0.05.Table 2 shows the execution time to complete 50000 generations, again, averaged over 20 independent runs. The results indicate that TPX (Two-point Crossover) completes the required number of generations much faster than the other operators, while ERX (Edge Recombination Crossover) being the slowest one; these results are also evident in Fig. 4. Again, the ANOVA analysis showed that the CPU-time results differed significantly across different crossover operators: F (7, 31) = 8.47, F-critical = 2.39, p < 0.05.Table 1. Solution quality (percentage surplus error)Fig.2. Convergence graph of different crossover operators for TSP-70 cities (symmetric) instanceFig.3. Convergence graph of different crossover operators for TSP-100 cities (asymmetric) instancex 104GenerationsS u r p l u s e r r o r (%)ST70: TSP 70 Citiesx 104GenerationsS u r p l u s e r r o r (%)FTV100: TSP 100 CitiesTable 2. Mean computational time (seconds) to complete 50000 generationsFig.4. Average execution time of different crossover operators to complete 50000 generationsV.D ISCUSSIONIn the present study, the performance of different crossover operators was evaluated against two dimensions: solution quality and execution time. The study revealed some interesting results.∙First, even though not a single crossover operator was able to find the best known solution for thefour select TSP instances (the best known solutions:ST70 = 675, TSP225 = 3919, FTV100 = 1788,FTV170 = 2755) [15], overall, SequentialConstructive Crossover (SCX) offered the bestperformance: on each test problem, the surpluserror was marginally above the best known solutionas compared to other operators. Interestinglyenough, SCX also offered competitive performancein execution time, even though not the fastest one. ∙Second, Edge Recombination Crossover (ERX) is very slow because of its complex nature, involvinglots of computations to construct edge maps. Onemight expect that this sophisticated and complexcomputation benefit in attaining a good quality solution, however, the results suggest otherwise.ERX is found both the slowest in speed and worst in solution quality. Interestingly, Two-Point Crossover (TPX) was observed as the fastest operator. This may be because TPX is relatively simple, it just finds two crossover points, split along those points and glue parts alternating between parents.∙When the number of cities is small (e.g., ST70), the performance of different crossover operators is much better as compared to large number of cities(e.g., FTV170). To this end, we combined theresults of relatively smaller number of cities ST70 and FTV100, and the results of relatively larger number of cities FTV170 and TSP225, for both solution quality and computational time. The ANOVA analysis on these combined results revealed that the results differed significantly between small and large problems: (Solution quality: F(1, 7) = 2.95, F-critical = 2.13, p < 0.05;Time: F(1, 7) = 7.06, F-critical = 2.68, p < 0.05).This may be interpreted as the different crossoveroperators evaluated in this study are not that muchscalable and their performance may degrade whenthe problem complexity increases.∙Another interesting result came to fore during the analysis of results. The select crossover operatorscan be clustered into three different groups basedon solution quality: SCX in one group, with thebest overall performance, TPX and SX in anothergroup, with the worst overall performance andPMX, CX, ERX, UOX and SEX in yet anothergroup, with medium performance. These results areevident from Fig. 2 and Fig. 3. ANOVA analysisfurther revealed that the difference between threeclusters are highly significant: F(2, 11) = 6.91, F-critical = 4.26, p < 0.01.∙Finally, it was expected, before analysis of the results, that the solution quality of the differentcrossover operators would be better for symmetricproblems as compared to asymmetric problems.However, the results indicate that there is nosignificant difference among these crossoveroperators for symmetric and asymmetric problems:F(1, 7) = 0.85, F-critical = 4.06, p = 0.47.VI.C ONCLUSIONIn this study, eight different crossover operators were evaluated empirically against two instances of travelling salesman problem (TSP-29 city and TSP-70 city). The select crossover operators were implemented to build an experimental setup upon which simulations were run. The performance of these operators was analyzed in terms of solution quality and computational cost. It was found that SCX outperformed other operators in attaining 'good' quality solution, whereas TPX outperformed other operators in terms of computational cost. Moreover, the select crossover operators can be clustered into three different groups based on solution quality: SCX in one group, with the best overall performance, TPX and SX in another group, with the worst overall performance and PMX, CX, ERX, UOX and SEX in yet another group, with medium performance.The present study also revealed that the performance of different crossover operators is much better for relatively small number of cities (e.g. 70 cities), both in terms of solution quality and computational time. However, the performance of these operators deteriorated when the number of cities were relatively large (e.g. 170 cities). This raises an interesting question on the scalability of these crossover operators. We conjecture that the performance of these operators may degrade when the problem complexity increases. Interestingly, we did not observe any significant difference on the performance of the select crossover operators for symmetric and asymmetric TSP problems, meaning that they perform equally good on both symmetric and asymmetric problems.R EFERENCES[1]Rechenberg. Evolutionsstrategie: optimierung technischersysteme und prinzipien der biologischen evolution.Frommann-Holzboog, Stuttgart Germany, 1973.[2]J. H. Holland. Adaptation in natural and artificial systems.University of Michigan Press, Ann Arbor, MI, 1975. [3]J. R. Koza and R. Poli. Genetic Programming: On theprogramming of computers by means of natural selection (complex adaptive systems). MIT Press, Cambridge, MA, 1992.[4]K.A. De Jong. An analysis of the behaviour of a class ofgenetic adaptive systems. Doctoral dissertation, University of Michigan, 1975.[5] D. Goldberg and R. Lingle. Alleles, loci, and the travellingsalesman problem. In proceedings of the first international conference on genetic algorithms and their applications, 1985, 154-159.[6]I. Oliver, D. Smith and J. Holland. A study of permutationcrossover operators on the travelling salesman problem. In proceedings of the second international conference on genetic algorithms and their applications, 1987, 224-230. [7] D. Whitley, T. Starkweather and D. Shaner. The travellingsalesman and sequence scheduling: quality solutions using genetic edge recombination. In handbook of genetic algorithms, 1990, 350-372.[8]T. Starkweather, S. Mcdaniel, K. E. Mathias, L. D.Whitley and C. Whitley. A comparison of genetic sequencing operators. In proceedings of the fourth international conference on genetic algorithms, 1991, 69-76.[9]M. Yamamura, T. Ono and S. Kobayashi. Character-preserving genetic algorithms for travelling salesman problem. Journal of the Japanese society for artificial intelligence, 1992: 7(6), 1049-1059.[10]G. Syswerda. Order-based genetic algorithms and thegraph coloring problem. In handbook of genetic algorithms, L. Davis, ed. Van Nostrand Reinhold. 1991.[11]G. Reinelt. Tsplib, universität heidelberg, 1995. RetrievedMarch 14, 2015, from http://www.iwr.uniheidelberg.de/groups/comopt/software/TSPLIB95/.[12]R. A. Caruana, L. J. Eshelman and J. D. Schaffer.Representation and hidden bias II: eliminating defining length bias in genetic search via shuffle crossover. In proceedings of the eleventh international joint conference on artificial intelligence, Detroit, Michigan, USA, 1989, 750–755.[13]K. A. De Jong W. M. and Spears. A formal analysis of therole of multi-point crossover in genetic algorithms, Annals of Mathematics and Artificial Intelligence, 1992, 5(1): 1–26.[14]M. Mitchell. An introduction to genetic algorithms. TheMIT Press, Cambridge, USA, 1999.[15]S. Picek, M. Golub and D. Jakobovic. Evaluation ofCrossover Operator Performance in Genetic Algorithms with Binary Representation. In proceedings of bio-inspired computing and applications (lecture notes in computer series), Springer Berlin Heidelberg, 2012, 223-230. [16]K. Puljic and R. Manger. Comparison of eightevolutionary crossover operators for the vehicle routing problem. Journal of mathematical communications, 2013: 18, 359-375.[17]V. K. Dabhi and S. Chaudhary. Performance comparisonof crossover operators for postfix genetic programming.International journal of metaheuristics, 2014: 3(3), 244-264.[18]D. Dumitrescu, B. Lazzerini, B., L. C. Jain and A.Dumitrescu. Evolutionary Computation. CRC Press, Florida, USA, 2000.[19]S. Picek and M. Golub. Comparison of a crossoveroperator in binary-coded genetic algorithms. WSEAS transactions on computation, 2010: 9(9), 1064-1073. [20]I. H. Khan. A comparative study of EAG and PBIL onlarge-scale global optimization problems. Journal of applied computational intelligence and soft computing.Hindawi publications, 2014, 10 pages.Authors’ ProfilesImtiaz Hussain Khan is an assistantprofessor in Department of ComputerScience at King Abdulaziz University,Jeddah, Kingdom of Saudi Arabia. Hereceived his MS in Computer Science fromthe University of Essex UK in 2005 and PhDin Natural Language Generation from theUniversity of Aberdeen UK in 2010. His areas of research are Natural Language Processing and Evolutionary Computation.How to cite this paper: Imtiaz Hussain Khan,"Assessing Different Crossover Operators for Travelling Salesman Problem", International Journal of Intelligent Systems and Applications (IJISA), vol.7, no.11, pp.19-25, 2015. DOI: 10.5815/ijisa.2015.11.03。