jenes.performance
Class TSPCrossover

java.lang.Object
  extended by jenes.stage.AbstractStage<T>
      extended by jenes.stage.operator.Operator<T>
          extended by jenes.stage.operator.Crossover<IntegerChromosome>
              extended by jenes.performance.TSPCrossover

public class TSPCrossover
extends Crossover<IntegerChromosome>


Nested Class Summary
 
Nested classes/interfaces inherited from class jenes.stage.operator.Crossover
Crossover.Statistics
 
Field Summary
 
Fields inherited from class jenes.stage.operator.Crossover
probability
 
Fields inherited from class jenes.stage.operator.Operator
random, statistics
 
Fields inherited from class jenes.stage.AbstractStage
biggerIsBetter, ga
 
Constructor Summary
TSPCrossover(double probability)
           
 
Method Summary
protected  void cross(Individual<IntegerChromosome>[] offsprings)
          Executes the crossover.
static void main(java.lang.String[] args)
           
protected  int spread()
          Returns the number of individuals involved by this crossover operator
 
Methods inherited from class jenes.stage.operator.Crossover
getProbability, init, process, setProbability
 
Methods inherited from class jenes.stage.operator.Operator
getStatistics, updateStatistics
 
Methods inherited from class jenes.stage.AbstractStage
dispose, isBiggerBetter, setBiggerIsBetter, setBiggerIsBetter
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TSPCrossover

public TSPCrossover(double probability)
Method Detail

spread

protected int spread()
Description copied from class: Crossover
Returns the number of individuals involved by this crossover operator

Specified by:
spread in class Crossover<IntegerChromosome>
Returns:
the number of individuals required by crossover

cross

protected void cross(Individual<IntegerChromosome>[] offsprings)
Description copied from class: Crossover
Executes the crossover. At the invocation time the specified array contains the individuals to be modify by cross; at the return time it contains the output crossover individuals.

Specified by:
cross in class Crossover<IntegerChromosome>
Parameters:
offsprings - the individuals to be modified.

main

public static void main(java.lang.String[] args)