public class NeighborPermutationMixed extends Object implements NeighborPermutation
Randomly selects between NeighborPermutationSwap,
NeighborPermutationInsert, and NeighborPermutationRevert.
| Constructor and Description |
|---|
NeighborPermutationMixed(NeighborPermutationSwap swap,
NeighborPermutationInsert insert,
NeighborPermutationRevert revert,
Rand random)
Constructs a
NeighborPermutationMixed operator for the
PermutationGenotype. |
| Modifier and Type | Method and Description |
|---|---|
void |
neighbor(PermutationGenotype<?> genotype)
Moves the
Genotype to a neighbor. |
@Inject public NeighborPermutationMixed(NeighborPermutationSwap swap, NeighborPermutationInsert insert, NeighborPermutationRevert revert, Rand random)
NeighborPermutationMixed operator for the
PermutationGenotype.swap - the swap permutationinsert - the insert permutationrevert - the revert permutationrandom - the random number generatorpublic void neighbor(PermutationGenotype<?> genotype)
NeighborGenotype to a neighbor.neighbor in interface Neighbor<PermutationGenotype<?>>genotype - the Genotype to be changed