eaLib API Docs
Last Modified : January 7 2002

mss.ea.rec
Class MPListRecombination

java.lang.Object
  |
  +--mss.ea.core.GeneticOperator
        |
        +--mss.ea.rec.Recombination
              |
              +--mss.ea.rec.ChromosomeRecombination
                    |
                    +--mss.ea.rec.ListRecombination
                          |
                          +--mss.ea.rec.MPListRecombination

public class MPListRecombination
extends ListRecombination

Multipoint Crossover for lists. This operator produces two children from two parents. For the number of intersection na obtains: 0 < na < width( list ).

Since:
0.1
Version:
0.1 (06-14-2001)
Author:
Andreas Rummler

Field Summary
protected  int intersection
          Number of intersections.
protected  int[] intersectionPoints
          Intersection points.
protected  java.util.Random rand
          Random generator.
 
Fields inherited from class mss.ea.rec.Recombination
quantity, required
 
Fields inherited from class mss.ea.core.GeneticOperator
description, ID, name
 
Constructor Summary
MPListRecombination(int intersectionNumber)
          Constructor.
MPListRecombination(int[] intersectionPoints)
          Constructor with intersection points.
 
Method Summary
 ListChromosome[] recombine(ListChromosome[] cra)
          Performs the recombination.
 
Methods inherited from class mss.ea.rec.ListRecombination
recombine
 
Methods inherited from class mss.ea.rec.Recombination
getQuantity, getRequired
 
Methods inherited from class mss.ea.core.GeneticOperator
getDescription, getID, getName, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

rand

protected java.util.Random rand
Random generator.

intersection

protected int intersection
Number of intersections.

intersectionPoints

protected int[] intersectionPoints
Intersection points.
Constructor Detail

MPListRecombination

public MPListRecombination(int intersectionNumber)
Constructor.
Parameters:
intersectionNumber - number of intersections of the lists

MPListRecombination

public MPListRecombination(int[] intersectionPoints)
Constructor with intersection points. This constructor should only be used for debugging purposes.
Parameters:
intersectionPoints - array with intersection points
Method Detail

recombine

public ListChromosome[] recombine(ListChromosome[] cra)
                           throws RecombinationException
Performs the recombination.
Overrides:
recombine in class ListRecombination
Parameters:
cra - array with at least two two parents
Returns:
array with two children
Throws:
RecombinationException - never thrown in current state

eaLib API Docs
Last Modified : January 7 2002

Copyright © 2000-2001 Technical University of Ilmenau, Department ESS