Crossover operators

Crossover operators (a.k.a. recombinators) in EvoLP work on two parents a and b to generate 1 offspring. All operators are derived from the EvoLP.Recombinator abstract type, and some of them have parameters to control how the recombination is performed. Crossover methods are independent of the data contained in an individual, and are instead dependent on its representation.

Currently, crossover is only implemented for vector individuals.

Selecting a crossover operator

Deprecated from EvoLP 1.4

All crossover operators have been renamed to recombinators since EvoLP 1.4. The old names will be deprecated in a future major release. Be sure to check the new type ontology.

EvoLP provides many built-in recombinators.


Single point, two point and uniform crossover operators work on vectors of any numeric type (binary or continuous representations). Using them on permutation-based vectors could generate unfeasible solutions.

For continuous domains

For permutation representations

Order One (OX1) allows for feasibility to be preserved after recombination.

Performing the crossover

After "instantiating" a recombinator, you can use the cross function. cross operates on two parents a and b to generate a new candidate solution. All operators return a new individual, and in the process no individual is modified.

cross(::SinglePointRecombinator, a, b)

Single point crossover between parents a and b, at a random point in the chromosome.

cross(::TwoPointRecombinator, a, b)

Two point crossover between parents a and b, at two random points in the chromosome.

crossover(::UniformRecombinator, a, b)

Uniform crossover between parents a and b. Each gene of the chromosome is randomly selected from one of the parents.

cross(C::InterpolationRecombinator, a, b)

Linear Interpolation crossover between parents a and b. The resulting individual is the addition of a scaled version of each of the parents, using C.λ as a control parameter.

cross(::OX1Recombinator, a, b)

Order 1 crossover between permutation parents a and b. A substring from a is copied directly to the offspring, and the remaining values are copied in the order they appear in b.

To obtain a second individual during crossover, use the cross method swapping the arguments.