eaLib API Docs
Last Modified : January 7 2002

mss.ea.core
Class SortedSteadyPopulation

java.lang.Object
  |
  +--mss.ea.core.GeneticOperator
        |
        +--mss.ea.core.AbstractPopulation
              |
              +--mss.ea.core.SortedPopulation
                    |
                    +--mss.ea.core.SortedSteadyPopulation
All Implemented Interfaces:
java.util.EventListener, IndividualGate, NotificationListener

public class SortedSteadyPopulation
extends SortedPopulation

Sorted population with a steady number of individuals.

Since:
0.1
Version:
$Revision: 1.2 $ $Date: 2001/11/12 16:53:50 $
Author:
Andreas Rummler

Field Summary
protected  int maxInd
          Maximal number of individuals in this population.
 
Fields inherited from class mss.ea.core.SortedPopulation
comp, pop
 
Fields inherited from class mss.ea.core.AbstractPopulation
filter, gc
 
Fields inherited from class mss.ea.core.GeneticOperator
description, ID, name
 
Constructor Summary
SortedSteadyPopulation(IndividualComparator comp, int maxInd)
          Constructor with individual comparator.
SortedSteadyPopulation(int maxInd)
          Constructor.
 
Method Summary
 void add(Individual i)
          Adds an individual.
 void add(Individual[] ia)
          Adds an array with individuals to the population.
 void add(java.util.Vector iv)
          Deprecated. should not be used any longer
protected  void updateSize()
          Updates the size of the internal array.
 
Methods inherited from class mss.ea.core.SortedPopulation
get, getAverage, getBest, getComparator, getIndex, getWorst, remove, remove, removeAll, replace, setComparator, size, subList, toArray, toCollection
 
Methods inherited from class mss.ea.core.AbstractPopulation
add, add, getCounter, getFilter, getStream, notificationSignal, setFilter, toStream
 
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

maxInd

protected int maxInd
Maximal number of individuals in this population.
Constructor Detail

SortedSteadyPopulation

public SortedSteadyPopulation(int maxInd)
Constructor.
Parameters:
maxInd - maximal number of individuals in this population

SortedSteadyPopulation

public SortedSteadyPopulation(IndividualComparator comp,
                              int maxInd)
Constructor with individual comparator.
Parameters:
comp - individual comparator
maxInd - maximal number of individuals in this population
Method Detail

add

public void add(Individual i)
Adds an individual.
Overrides:
add in class SortedPopulation
Parameters:
i - individual to add

add

public void add(Individual[] ia)
Adds an array with individuals to the population.
Overrides:
add in class SortedPopulation
Parameters:
ia - array with individuals

add

public void add(java.util.Vector iv)
Deprecated. should not be used any longer

Adds a vector with individuals to the population.
Overrides:
add in class SortedPopulation
Parameters:
iv - vector with individuals

updateSize

protected void updateSize()
Updates the size of the internal array. All individuals having a bigger index than allowed are removed from the population.

eaLib API Docs
Last Modified : January 7 2002

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