摘要
在遗传算法中,面向路径测试数据自动生成存在迭代次数多、效率低的问题。为此,提出一种改进型的遗传算法。通过分析被测源程序得到其结构信息,并利用该结构信息,控制遗传算法中交叉、变异操作发生的位置及范围,提高遗传操作的精确性和目的性。实验结果表明,与传统遗传算法相比,该算法具有更快的收敛速度,测试数据生成效率更高。
For the problem that Genetic Algorithm(GA) suffers from large iteration times and low efficiency in path-oriented test data generation, this paper proposes a Modified Genetic Algorithm(MGA), through analyzing the source code, structural information is gained and used to control the crossover and mutation point and range in order to make the genetic operation more accurate and purposeful. Experimental result shows that MGA has faster convergence speed and higher test data generation efficiency compared with traditional genetic algorithm.
出处
《计算机工程》
CAS
CSCD
2012年第4期158-161,共4页
Computer Engineering
基金
国家自然科学基金资助项目(61073035
60903002)
关键词
遗传算法
面向路径
测试数据生成
程序结构信息
分支表达式
交叉
变异
Genetic Algorithm(GA)
path-oriented
test data generation
program structural information
branch expression
crossover
mutation