
Watchmaker Framework for Evolutionary Computation API (Version 0.7.1) 

PREV CLASS NEXT CLASS  FRAMES NO FRAMES  
SUMMARY: NESTED  FIELD  CONSTR  METHOD  DETAIL: FIELD  CONSTR  METHOD 
java.lang.Object org.uncommons.watchmaker.framework.operators.AbstractCrossover<char[]> org.uncommons.watchmaker.framework.operators.CharArrayCrossover
public class CharArrayCrossover
Crossover with a configurable number of points (fixed or random) for arrays of primitive chars.
Constructor Summary  

CharArrayCrossover()
Default is singlepoint crossover, applied to all parents. 

CharArrayCrossover(int crossoverPoints)
Crossover with a fixed number of crossover points. 

CharArrayCrossover(int crossoverPoints,
Probability crossoverProbability)
Crossover with a fixed number of crossover points. 

CharArrayCrossover(NumberGenerator<Integer> crossoverPointsVariable)
Crossover with a variable number of crossover points. 

CharArrayCrossover(NumberGenerator<Integer> crossoverPointsVariable,
NumberGenerator<Probability> crossoverProbabilityVariable)
Sets up a crossover implementation that uses a variable number of crossover points. 
Method Summary  

protected List<char[]> 
mate(char[] parent1,
char[] parent2,
int numberOfCrossoverPoints,
Random rng)
Perform crossover on a pair of parents to generate a pair of offspring. 
Methods inherited from class org.uncommons.watchmaker.framework.operators.AbstractCrossover 

apply 
Methods inherited from class java.lang.Object 

clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait 
Constructor Detail 

public CharArrayCrossover()
public CharArrayCrossover(int crossoverPoints)
crossoverPoints
 The constant number of crossover points
to use for all crossover operations.public CharArrayCrossover(int crossoverPoints, Probability crossoverProbability)
crossoverProbability
.
crossoverPoints
 The constant number of crossover points
to use for all crossover operations.crossoverProbability
 The probability that, once selected,
a pair of parents will be subjected to crossover rather than
being copied, unchanged, into the output population.public CharArrayCrossover(NumberGenerator<Integer> crossoverPointsVariable)
crossoverPointsVariable
 A random variable that provides a number
of crossover points for each crossover operation.public CharArrayCrossover(NumberGenerator<Integer> crossoverPointsVariable, NumberGenerator<Probability> crossoverProbabilityVariable)
crossoverProbabilityVariable
parameter.
crossoverPointsVariable
 A variable that provides a (possibly constant,
possibly random) number of crossover points for each crossover operation.crossoverProbabilityVariable
 A variable that controls the probability
that, once selected, a pair of parents will be subjected to crossover rather
than being copied, unchanged, into the output population.Method Detail 

protected List<char[]> mate(char[] parent1, char[] parent2, int numberOfCrossoverPoints, Random rng)
mate
in class AbstractCrossover<char[]>
parent1
 One of two individuals that provides the source material
for generating offspring.parent2
 One of two individuals that provides the source material
for generating offspring.numberOfCrossoverPoints
 The number of crossovers performed on the
two parents.rng
 A source of randomness used to determine the location of
crossover points.

Watchmaker Framework for Evolutionary Computation API (Version 0.7.1) 

PREV CLASS NEXT CLASS  FRAMES NO FRAMES  
SUMMARY: NESTED  FIELD  CONSTR  METHOD  DETAIL: FIELD  CONSTR  METHOD 