A point on both parents' chromosomes is picked randomly, and designated a 'crossover point'. Bits to the right of that point are swapped between the two parent chromosomes. This results in two offspring, each carrying some genetic information from both parents.
In two-point crossover, two crossover points are picked randomly from the parent chromosomes. The bits in between the two points are swapped between the parent organisms.
Two-point crossover is equivalent to performing two single-point crossovers with different crossover points. This strategy can be generalized to k-point crossover for any positive integer k, picking k crossover points.
In uniform crossover, typically, each bit is chosen from either parent with equal probability. Other mixing ratios are sometimes used, resulting in offspring which inherit more genetic information from one parent than the other.
In a uniform crossover, we don’t divide the chromosome into segments, rather we treat each gene separately. In this, we essentially flip a coin for each chromosome to decide whether or not it will be included in the off-spring.
For the crossover operators presented above and for most other crossover operators for bit strings, it holds that they can also be applied accordingly to integer or real-valued genomes whose genes each consist of an integer or real-valued number. Instead of individual bits, integer or real-valued numbers are then simply copied into the child genome. The offspring lie on the remaining corners of the hyperbody spanned by the two parents
P
1
=
(
1.5
,
6
,
8
)
{\displaystyle P_{1}=(1.5,6,8)}
and
P
2
=
(
7
,
2
,
1
)
{\displaystyle P_{2}=(7,2,1)}
, as exemplified in the accompanying image for the three-dimensional case.
If the rules of the uniform crossover for bit strings are applied during the generation of the offspring, this is also called discrete recombination.
In this recombination operator, the allele values of the child genome
a
i
{\displaystyle a_{i}}
are generated by mixing the alleles of the two parent genomes
a
i
,
P
1
{\displaystyle a_{i,P_{1}}}
and
a
i
,
P
2
{\displaystyle a_{i,P_{2}}}
:
α
i
=
α
i
,
P
1
⋅
β
i
+
α
i
,
P
2
⋅
(
1
−
β
i
)
w
i
t
h
β
i
∈
[
−
d
,
1
+
d
]
{\displaystyle \alpha _{i}=\alpha _{i,P_{1}}\cdot \beta _{i}+\alpha _{i,P_{2}}\cdot \left(1-\beta _{i}\right)\quad {\mathsf {with}}\quad \beta _{i}\in \left[-d,1+d\right]}
randomly equally distributed per gene
i
{\displaystyle i}
The choice of the interval
[
−
d
,
1
+
d
]
{\displaystyle [-d,1+d]}
causes that besides the interior of the hyperbody spanned by the allele values of the parent genes additionally a certain environment for the range of values of the offspring is in question. A value of
0.25
{\displaystyle 0.25}
is recommended for
d
{\displaystyle d}
to counteract the tendency to reduce the allele values that otherwise exists at
d
=
0
{\displaystyle d=0}
.
The adjacent figure shows for the two-dimensional case the range of possible new alleles of the two exemplary parents
P
1
=
(
3
,
6
)
{\displaystyle P_{1}=(3,6)}
and
P
2
=
(
9
,
2
)
{\displaystyle P_{2}=(9,2)}
in intermediate recombination. The offspring of discrete recombination
C
1
{\displaystyle C_{1}}
and
C
2
{\displaystyle C_{2}}
are also plotted. Intermediate recombination satisfies the arithmetic calculation of the allele values of the child genome required by virtual alphabet theory. Discrete and intermediate recombination are used as a standard in the evolution strategy.
In order to avoid the generation of invalid offspring, special crossover operators for permutations have been developed which fulfill the basic requirements of such operators for permutations, namely that all elements of the initial permutation are also present in the new one and only the order is changed. It can be distinguished between combinatorial tasks, where all sequences are admissible, and those where there are constraints in the form of inadmissible partial sequences. A well-known representative of the first task type is the traveling salesman problem (TSP), where the goal is to visit a set of cities exactly once on the shortest tour. An example of the constrained task type is the scheduling of multiple workflows. Workflows involve sequence constraints on some of the individual work steps. For example, a thread cannot be cut until the corresponding hole has been drilled in a workpiece. Such problems are also called order-based permutations.
In the following, two crossover operators are presented as examples, the partially mapped crossover (PMX) motivated by the TSP and the order crossover (OX1) designed for order-based permutations. A second offspring can be produced in each case by exchanging the parent chromosomes.
The PMX operator was designed as a recombination operator for TSP like Problems. The explanation of the procedure is illustrated by an example:
The order crossover goes back to Davis in its original form and is presented here in a slightly generalized version with more than two crossover points. It transfers information about the relative order from the second parent to the offspring. First, the number and position of the crossover points are determined randomly. The resulting gene sequences are then processed as described below:
Among other things, order crossover is well suited for scheduling multiple workflows, when used in conjunction with 1- and n-point crossover.
Over time, a large number of crossover operators for permutations have been proposed, so the following list is only a small selection. For more information, the reader is referred to the literature.
The usual approach to solving TSP-like problems by genetic or, more generally, evolutionary algorithms, presented earlier, is either to repair illegal descendants or to adjust the operators appropriately so that illegal offspring do not arise in the first place. Alternatively, Riazi suggests the use of a double chromosome representation, which avoids illegal offspring.
Davis, Lawrence (1991). Handbook of genetic algorithms. New York: Van Nostrand Reinhold. ISBN 0-442-00173-8. OCLC 23081440. 0-442-00173-8
Eiben, A.E.; Smith, J.E. (2015). "Representation, Mutation, and Recombination". Introduction to Evolutionary Computing. Natural Computing Series (2nd ed.). Berlin, Heidelberg: Springer. pp. 49–78. doi:10.1007/978-3-662-44874-8. ISBN 978-3-662-44873-1. S2CID 20912932. 978-3-662-44873-1
Yu, Xinjie; Gen, Mitsuo (2010). "Encoding and Operators". Introduction to evolutionary algorithms. Decision Engineering. London: Springer. pp. 40–63. doi:10.1007/978-1-84996-129-5. ISBN 978-1-84996-129-5. OCLC 654380156. 978-1-84996-129-5
Yu, Xinjie; Gen, Mitsuo (2010). "Variation Operators for Permutation Code". Introduction to Evolutionary Algorithms. Decision Engineering. London: Springer. pp. 285–299. doi:10.1007/978-1-84996-129-5. ISBN 978-1-84996-128-8. 978-1-84996-128-8
Booker, Lashon B.; Fogel, David B.; Whitley, Darrell; Angeline, Peter J.; Eiben, A.E. (2000). "Recombination". In Bäck, Thomas; Fogel, David B.; Michalewicz, Zbigniew (eds.). Evolutionary computation. Vol. 1, Basic algorithms and operators. Bristol: Institute of Physics Pub. pp. 256–307. ISBN 0-585-30560-9. OCLC 45730387. 0-585-30560-9
Syswerda, Gilbert (1989), Schaffer, J.D. (ed.), "Uniform crossover in genetic algorithms", Proceedings of the 3rd International Conference on Genetic Algorithms (ICGA), San Francisco: Morgan Kaufmann, pp. 2–9, ISBN 1558600663 1558600663
Eiben, A.E.; Smith, J.E. (2015). "Recombination Operators for Real-Valued Representation". Introduction to Evolutionary Computing. Natural Computing Series (2nd ed.). Berlin, Heidelberg: Springer. pp. 65–67. doi:10.1007/978-3-662-44874-8. ISBN 978-3-662-44873-1. S2CID 20912932. 978-3-662-44873-1
Eiben, A.E.; Smith, J.E. (2015). "Recombination Operators for Real-Valued Representation". Introduction to Evolutionary Computing. Natural Computing Series (2nd ed.). Berlin, Heidelberg: Springer. pp. 65–67. doi:10.1007/978-3-662-44874-8. ISBN 978-3-662-44873-1. S2CID 20912932. 978-3-662-44873-1
Yu, Xinjie; Gen, Mitsuo (2010). "Real Code and Related Operators". Introduction to Evolutionary Algorithms. Decision Engineering. London: Springer. pp. 45–63. doi:10.1007/978-1-84996-129-5. ISBN 978-1-84996-128-8. 978-1-84996-128-8
Mühlenbein, Heinz; Schlierkamp-Voosen, Dirk (1993). "Predictive Models for the Breeder Genetic Algorithm I. Continuous Parameter Optimization". Evolutionary Computation. 1 (1): 25–49. doi:10.1162/evco.1993.1.1.25. ISSN 1063-6560. S2CID 16085506. https://direct.mit.edu/evco/article/1/1/25-49/1093
Goldberg, David E. (1991). "Real-coded Genetic Algorithms, Virtual Alphabets, and Blocking". Complex Syst. 5 (2): 139–167. https://www.complex-systems.com/abstracts/v05_i02_a02/
Stender, J.; Hillebrand, E.; Kingdon, J. (1994). Genetic algorithms in optimisation, simulation, and modelling. Amsterdam: IOS Press. ISBN 90-5199-180-0. OCLC 47216370. 90-5199-180-0
Schwefel, Hans-Paul (1995). Evolution and optimum seeking. New York: Wiley. ISBN 0-471-57148-2. OCLC 30701094. 0-471-57148-2
Larrañaga, P.; Kuijpers, C.M.H.; Murga, R.H.; Inza, I.; Dizdarevic, S. (1999). "Genetic Algorithms for the Travelling Salesman Problem: A Review of Representations and Operators". Artificial Intelligence Review. 13 (2): 129–170. doi:10.1023/A:1006529012972. S2CID 10284682. http://link.springer.com/10.1023/A:1006529012972
Goldberg, David E.; Lingle, R. (1985), Grefenstette, John J. (ed.), "Alleles, loci, and the traveling salesman problem", Proceedings of the First International Conference on Genetic Algorithms and Their Applications (ICGA), Hillsdale, N.J.: Lawrence Erlbaum Associates, pp. 154–159, ISBN 0-8058-0426-9, OCLC 19702892 0-8058-0426-9
Eiben, A.E.; Smith, J.E. (2015). "Recombination for Permutation Representation". Introduction to Evolutionary Computing. Natural Computing Series (2nd ed.). Berlin, Heidelberg: Springer. pp. 70–74. doi:10.1007/978-3-662-44874-8. ISBN 978-3-662-44873-1. S2CID 20912932. 978-3-662-44873-1
Davis, Lawrence (1991). Handbook of genetic algorithms. New York: Van Nostrand Reinhold. ISBN 0-442-00173-8. OCLC 23081440. 0-442-00173-8
Jakob, Wilfried; Quinte, Alexander; Stucky, Karl-Uwe; Süß, Wolfgang (2008), Rudolph, Günter; Jansen, Thomas; Beume, Nicola; Lucas, Simon (eds.), "Fast Multi-objective Scheduling of Jobs to Constrained Resources Using a Hybrid Evolutionary Algorithm", Parallel Problem Solving from Nature – PPSN X, vol. LNCS 5199, Berlin, Heidelberg: Springer, pp. 1031–1040, doi:10.1007/978-3-540-87700-4_102, ISBN 978-3-540-87699-1, retrieved 2023-01-14 978-3-540-87699-1
Davis, Lawrence (1991). Handbook of genetic algorithms. New York: Van Nostrand Reinhold. ISBN 0-442-00173-8. OCLC 23081440. 0-442-00173-8
Booker, Lashon B.; Fogel, David B.; Whitley, Darrell; Angeline, Peter J.; Eiben, A.E. (2000). "Recombination". In Bäck, Thomas; Fogel, David B.; Michalewicz, Zbigniew (eds.). Evolutionary computation. Vol. 1, Basic algorithms and operators. Bristol: Institute of Physics Pub. pp. 256–307. ISBN 0-585-30560-9. OCLC 45730387. 0-585-30560-9
Eiben, A.E.; Smith, J.E. (2015). "Recombination for Permutation Representation". Introduction to Evolutionary Computing. Natural Computing Series (2nd ed.). Berlin, Heidelberg: Springer. pp. 70–74. doi:10.1007/978-3-662-44874-8. ISBN 978-3-662-44873-1. S2CID 20912932. 978-3-662-44873-1
Larrañaga, P.; Kuijpers, C.M.H.; Murga, R.H.; Inza, I.; Dizdarevic, S. (1999). "Genetic Algorithms for the Travelling Salesman Problem: A Review of Representations and Operators". Artificial Intelligence Review. 13 (2): 129–170. doi:10.1023/A:1006529012972. S2CID 10284682. http://link.springer.com/10.1023/A:1006529012972
Oliver, I.M.; Smith, D.J.; Holland, J. (1987), Grefenstette, John J. (ed.), "A study of permutation crossover operators on the travelling salesman problem", Proceedings of the Second International Conference on Genetic Algorithms and Their Applications (ICGA), Hillsdale, N.J.: Lawrence Erlbaum Associates, pp. 224–230, ISBN 978-0-8058-0158-3 978-0-8058-0158-3
Eiben, A.E.; Smith, J.E. (2015). "Recombination for Permutation Representation". Introduction to Evolutionary Computing. Natural Computing Series (2nd ed.). Berlin, Heidelberg: Springer. pp. 70–74. doi:10.1007/978-3-662-44874-8. ISBN 978-3-662-44873-1. S2CID 20912932. 978-3-662-44873-1
Booker, Lashon B.; Fogel, David B.; Whitley, Darrell; Angeline, Peter J.; Eiben, A.E. (2000). "Recombination". In Bäck, Thomas; Fogel, David B.; Michalewicz, Zbigniew (eds.). Evolutionary computation. Vol. 1, Basic algorithms and operators. Bristol: Institute of Physics Pub. pp. 256–307. ISBN 0-585-30560-9. OCLC 45730387. 0-585-30560-9
Syswerda, Gilbert (1991). "Schedule Optimization Using Genetic Algorithms". In Davis, Lawrence (ed.). Handbook of genetic algorithms. New York: Van Nostrand Reinhold. pp. 332–349. ISBN 0-442-00173-8. OCLC 23081440. 0-442-00173-8
Booker, Lashon B.; Fogel, David B.; Whitley, Darrell; Angeline, Peter J.; Eiben, A.E. (2000). "Recombination". In Bäck, Thomas; Fogel, David B.; Michalewicz, Zbigniew (eds.). Evolutionary computation. Vol. 1, Basic algorithms and operators. Bristol: Institute of Physics Pub. pp. 256–307. ISBN 0-585-30560-9. OCLC 45730387. 0-585-30560-9
Syswerda, Gilbert (1991). "Schedule Optimization Using Genetic Algorithms". In Davis, Lawrence (ed.). Handbook of genetic algorithms. New York: Van Nostrand Reinhold. pp. 332–349. ISBN 0-442-00173-8. OCLC 23081440. 0-442-00173-8
Whitley, Darrell; Starkweather, Timothy; Fuquay, D'Ann (1989), Schaffer, J.D. (ed.), "Scheduling Problems and Traveling Salesmen: The Genetic Edge Recombination Operator", Proceedings of the 3rd International Conference on Genetic Algorithms (ICGA), San Francisco: Morgan Kaufmann, pp. 133–140, ISBN 1558600663 1558600663
Eiben, A.E.; Smith, J.E. (2015). "Recombination for Permutation Representation". Introduction to Evolutionary Computing. Natural Computing Series (2nd ed.). Berlin, Heidelberg: Springer. pp. 70–74. doi:10.1007/978-3-662-44874-8. ISBN 978-3-662-44873-1. S2CID 20912932. 978-3-662-44873-1
Larrañaga, P.; Kuijpers, C.M.H.; Murga, R.H.; Inza, I.; Dizdarevic, S. (1999). "Genetic Algorithms for the Travelling Salesman Problem: A Review of Representations and Operators". Artificial Intelligence Review. 13 (2): 129–170. doi:10.1023/A:1006529012972. S2CID 10284682. http://link.springer.com/10.1023/A:1006529012972
Larrañaga, P.; Kuijpers, C.M.H.; Murga, R.H.; Inza, I.; Dizdarevic, S. (1999). "Genetic Algorithms for the Travelling Salesman Problem: A Review of Representations and Operators". Artificial Intelligence Review. 13 (2): 129–170. doi:10.1023/A:1006529012972. S2CID 10284682. http://link.springer.com/10.1023/A:1006529012972
Booker, Lashon B.; Fogel, David B.; Whitley, Darrell; Angeline, Peter J.; Eiben, A.E. (2000). "Recombination". In Bäck, Thomas; Fogel, David B.; Michalewicz, Zbigniew (eds.). Evolutionary computation. Vol. 1, Basic algorithms and operators. Bristol: Institute of Physics Pub. pp. 256–307. ISBN 0-585-30560-9. OCLC 45730387. 0-585-30560-9
Dzubera, John; Whitley, Darrell (1994), Davidor, Yuval; Schwefel, Hans-Paul; Männer, Reinhard (eds.), "Advanced correlation analysis of operators for the traveling salesman problem", Parallel Problem Solving from Nature — PPSN III, vol. 866, Berlin, Heidelberg: Springer, pp. 68–77, doi:10.1007/3-540-58484-6_251, ISBN 978-3-540-58484-1, retrieved 2023-01-15 978-3-540-58484-1
Booker, Lashon B.; Fogel, David B.; Whitley, Darrell; Angeline, Peter J.; Eiben, A.E. (2000). "Recombination". In Bäck, Thomas; Fogel, David B.; Michalewicz, Zbigniew (eds.). Evolutionary computation. Vol. 1, Basic algorithms and operators. Bristol: Institute of Physics Pub. pp. 256–307. ISBN 0-585-30560-9. OCLC 45730387. 0-585-30560-9
Blanton, Joe L.; Wainwright, Roger L. (1993), Forrest, Stephanie (ed.), "Multiple Vehicle Routing with Time and Capacity Constraints Using Genetic Algorithms", Proceedings of the 5th International Conference on Genetic Algorithms (ICGA), San Francisco: Morgan Kaufmann, pp. 452–459, ISBN 978-1-55860-299-1 978-1-55860-299-1
Ahmed, Zakir Hussain (2000). Sequential Constructive Sampling and Related approaches to Combinatorial Optimization (PhD). Tezpur University, India.
Riazi, Amin (14 October 2019). "Genetic algorithm and a double-chromosome implementation to the traveling salesman problem". SN Applied Sciences. 1 (11). doi:10.1007/s42452-019-1469-1. /wiki/Doi_(identifier)