net.sourceforge.cilib.moo.iterationstrategies
Class ArchivingIterationStrategy<E extends PopulationBasedAlgorithm>

java.lang.Object
  extended by net.sourceforge.cilib.moo.iterationstrategies.ArchivingIterationStrategy<E>
Type Parameters:
E - The PopulationBasedAlgorithm that will have it's entities' positions added to the archive as potential solutions.
All Implemented Interfaces:
Serializable, IterationStrategy<E>, Cloneable

public class ArchivingIterationStrategy<E extends PopulationBasedAlgorithm>
extends Object
implements IterationStrategy<E>

A generic multi-objective IterationStrategy class that wraps another IterationStrategy and is responsible for populating the Archive of Pareto optimal solutions after the execution of the inner IterationStrategy class.

Author:
Wiehann Matthysen
See Also:
Serialized Form

Constructor Summary
ArchivingIterationStrategy()
           
ArchivingIterationStrategy(ArchivingIterationStrategy<E> copy)
           
 
Method Summary
 Archive getArchive()
           
 ArchivingIterationStrategy<E> getClone()
          Create a cloned copy of the current object and return it.
 IterationStrategy<PopulationBasedAlgorithm> getIterationStrategy()
           
 void performIteration(E algorithm)
          Perform the iteration of the PopulationBasedAlgorithm.
 void setArchive(Archive archive)
           
 void setIterationStrategy(IterationStrategy<PopulationBasedAlgorithm> iterationStrategy)
           
protected  void updateArchive(Topology<? extends Entity> population)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ArchivingIterationStrategy

public ArchivingIterationStrategy()

ArchivingIterationStrategy

public ArchivingIterationStrategy(ArchivingIterationStrategy<E> copy)
Method Detail

getClone

public ArchivingIterationStrategy<E> getClone()
Description copied from interface: IterationStrategy
Create a cloned copy of the current object and return it. In general the created copy will be a deep copy of the provided instance. As a result this operation an be quite expensive if used incorrectly.

Specified by:
getClone in interface IterationStrategy<E extends PopulationBasedAlgorithm>
Specified by:
getClone in interface Cloneable
Returns:
An exact clone of the current object instance.
See Also:
Object.clone()

setIterationStrategy

public void setIterationStrategy(IterationStrategy<PopulationBasedAlgorithm> iterationStrategy)

getIterationStrategy

public IterationStrategy<PopulationBasedAlgorithm> getIterationStrategy()

updateArchive

protected void updateArchive(Topology<? extends Entity> population)

performIteration

public void performIteration(E algorithm)
Description copied from interface: IterationStrategy
Perform the iteration of the PopulationBasedAlgorithm.

Due to the nature of the PopulationBasedAlgorithms, the actual manner in which the algorithm's iteration is performed is deferred to the specific iteration strategy being used.

This implies that the general structure of the iteration for a specific flavour of algorithm is constant with modifications on that algorithm being made. For example, within a Genetic Algorithm you would expect:

  1. Parent individuals to be selected in some manner
  2. A crossover process to be done on the selected parent individuals to create the offspring
  3. A mutation process to alter the generated offspring
  4. Recombine the existing parent individuals and the generated offspring to create the next generation

Specified by:
performIteration in interface IterationStrategy<E extends PopulationBasedAlgorithm>
Parameters:
algorithm - The algorithm to perform the iteration process on.

setArchive

public void setArchive(Archive archive)

getArchive

public Archive getArchive()


Copyright © 2009 CIRG. All Rights Reserved.