问题描述
在Matlab中我需要帮助:我需要找出如何在FlowShop中交叉遗传算法的任何两个序列,例如
I need help in Matlab: I need to find out how to Crossover any two sequences for genetic alghorithm in FlowShop, e.g.
第二个序列= 7 8 9 10 5 4 2 1 3 6
2nd sequence = 7 8 9 10 5 4 2 1 3 6
分频后,后代应该是
后代2 = 7 8 9 10 1 5 4 3 2 6
offspring 2 = 7 8 9 10 1 5 4 3 2 6
交叉应确保每个数字在子代序列中不会重复.谁能告诉我该怎么做?
Crossover should be such that each number doesn't repeat itself in the offspring sequence. Can anyone tell me how to do this?
推荐答案
为置换编码定义了许多现有的分频器.其中以下内容对您有用:
There are a number of existing crossovers defined for permutation encodings. Among them the following would be useful for you:
- 循环交叉
- 部分匹配的分频器
- 类似制服的跨界车
- 基于位置的分频器
这些分频器旨在保留作业在排列中的位置.您可以在 HeuristicLab .浏览源文件,您还可以找到描述这些交叉的科学文章的引用.
These crossovers aim to preserve the position of the job in the permutation. You can find implementations in C# in the PermutationEncoding plugin of HeuristicLab. Browse the source files and you can also find references to scientific articles that describe these crossovers.
这篇关于流水车间调度的遗传算法的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!