Package org.moeaframework.algorithm
Class EpsilonMOEA
java.lang.Object
org.moeaframework.algorithm.AbstractAlgorithm
org.moeaframework.algorithm.AbstractEvolutionaryAlgorithm
org.moeaframework.algorithm.EpsilonMOEA
- All Implemented Interfaces:
Algorithm,EpsilonBoxEvolutionaryAlgorithm,EvolutionaryAlgorithm,Extensible,Configurable,Named,Stateful
public class EpsilonMOEA
extends AbstractEvolutionaryAlgorithm
implements EpsilonBoxEvolutionaryAlgorithm
Implementation of the ε-MOEA algorithm. The ε-MOEA is a steady-state algorithm, meaning only one
individual in the population is evolved per step, and uses an ε-dominance archive to maintain a well-spread
set of Pareto-optimal solutions.
References:
- Deb et al. "A Fast Multi-Objective Evolutionary Algorithm for Finding Well-Spread Pareto-Optimal Solutions." KanGAL Report No 2003002. Feb 2003.
-
Field Summary
Fields inherited from class org.moeaframework.algorithm.AbstractAlgorithm
initialized, numberOfEvaluations, problem, terminated -
Constructor Summary
ConstructorsConstructorDescriptionEpsilonMOEA(Problem problem) Constructs the ε-MOEA algorithm with default settings.EpsilonMOEA(Problem problem, int initialPopulationSize, Population population, EpsilonBoxDominanceArchive archive, Selection selection, Variation variation, Initialization initialization) Constructs the ε-MOEA algorithm with the specified components.EpsilonMOEA(Problem problem, int initialPopulationSize, Population population, EpsilonBoxDominanceArchive archive, Selection selection, Variation variation, Initialization initialization, DominanceComparator dominanceComparator) Constructs the ε-MOEA algorithm with the specified components. -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddToPopulation(Solution newSolution) Adds the new solution to the population if is non-dominated with the current population, removing either a randomly-selected dominated solution or a non-dominated solution.voidapplyConfiguration(TypedProperties properties) Applies the properties to this instance.Returns the current non-dominated archive of the best solutions generated by this evolutionary algorithm, ornullif no archive is used.Gets the current configuration of this instance.getName()Returns the name of this algorithm.voiditerate()Performs one iteration of the algorithm.voidsetArchive(EpsilonBoxDominanceArchive archive) Sets the archive used by this algorithm.voidsetInitialPopulationSize(int initialPopulationSize) Sets the initial population size.voidsetVariation(Variation variation) Replaces the variation operator to be used by this algorithm.Methods inherited from class org.moeaframework.algorithm.AbstractEvolutionaryAlgorithm
getInitialization, getInitialPopulationSize, getPopulation, getResult, getVariation, initialize, loadState, saveState, setArchive, setInitialization, setPopulationMethods inherited from class org.moeaframework.algorithm.AbstractAlgorithm
assertNotInitialized, evaluate, getExtensions, getNumberOfEvaluations, getProblem, isInitialized, isTerminated, step, terminateMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.moeaframework.algorithm.Algorithm
evaluate, evaluateAll, evaluateAll, getNumberOfEvaluations, getProblem, getResult, initialize, isInitialized, isTerminated, run, run, step, terminateMethods inherited from interface org.moeaframework.algorithm.EvolutionaryAlgorithm
getPopulationMethods inherited from interface org.moeaframework.algorithm.extension.Extensible
addExtension, getExtensions, removeExtension
-
Constructor Details
-
EpsilonMOEA
Constructs the ε-MOEA algorithm with default settings.- Parameters:
problem- the problem
-
EpsilonMOEA
public EpsilonMOEA(Problem problem, int initialPopulationSize, Population population, EpsilonBoxDominanceArchive archive, Selection selection, Variation variation, Initialization initialization) Constructs the ε-MOEA algorithm with the specified components.- Parameters:
problem- the problem being solvedinitialPopulationSize- the initial population sizepopulation- the population used to store solutionsarchive- the archive used to store the resultselection- the selection operatorvariation- the variation operatorinitialization- the initialization method
-
EpsilonMOEA
public EpsilonMOEA(Problem problem, int initialPopulationSize, Population population, EpsilonBoxDominanceArchive archive, Selection selection, Variation variation, Initialization initialization, DominanceComparator dominanceComparator) Constructs the ε-MOEA algorithm with the specified components.- Parameters:
problem- the problem being solvedinitialPopulationSize- the initial population sizepopulation- the population used to store solutionsarchive- the archive used to store the resultselection- the selection operatorvariation- the variation operatorinitialization- the initialization methoddominanceComparator- the dominance comparator used by theaddToPopulation(org.moeaframework.core.Solution)method
-
-
Method Details
-
getName
Description copied from interface:AlgorithmReturns the name of this algorithm. Whenever possible, this name should match the name recognized byAlgorithmFactory. -
iterate
public void iterate()Description copied from class:AbstractAlgorithmPerforms one iteration of the algorithm. This method should be overridden by implementations to perform each logical iteration of the algorithm.- Specified by:
iteratein classAbstractAlgorithm
-
addToPopulation
Adds the new solution to the population if is non-dominated with the current population, removing either a randomly-selected dominated solution or a non-dominated solution.- Parameters:
newSolution- the new solution being added to the population
-
getArchive
Description copied from interface:EvolutionaryAlgorithmReturns the current non-dominated archive of the best solutions generated by this evolutionary algorithm, ornullif no archive is used.- Specified by:
getArchivein interfaceEpsilonBoxEvolutionaryAlgorithm- Specified by:
getArchivein interfaceEvolutionaryAlgorithm- Overrides:
getArchivein classAbstractEvolutionaryAlgorithm- Returns:
- the current non-dominated archive of the best solutions generated by this evolutionary algorithm,
or
nullif no archive is used
-
setArchive
Sets the archive used by this algorithm. This value can not be set after initialization.- Parameters:
archive- the archive
-
setVariation
Description copied from class:AbstractEvolutionaryAlgorithmReplaces the variation operator to be used by this algorithm.- Overrides:
setVariationin classAbstractEvolutionaryAlgorithm- Parameters:
variation- the variation operator
-
setInitialPopulationSize
public void setInitialPopulationSize(int initialPopulationSize) Description copied from class:AbstractEvolutionaryAlgorithmSets the initial population size. This value can not be set after initialization.- Overrides:
setInitialPopulationSizein classAbstractEvolutionaryAlgorithm- Parameters:
initialPopulationSize- the initial population size
-
applyConfiguration
Description copied from interface:ConfigurableApplies the properties to this instance. It is strongly recommended to apply a configuration immediately after creating the instance, as some properties can not be changed after the class is used. Exceptions may be thrown if attempting to set such properties.After calling this method, we encourage users to call
TypedProperties.warnIfUnaccessedProperties()to verify all properties were processed. This can identify simple mistakes like typos.If overriding this method, properties should only be updated if a new value is provided. Additionally, if updating any
Configurableobjects inside this object, they should be updated before callingsuper.applyConfiguration(properties).- Specified by:
applyConfigurationin interfaceConfigurable- Parameters:
properties- the user-defined properties
-
getConfiguration
Description copied from interface:ConfigurableGets the current configuration of this instance. In theory, these properties should be able to create a duplicate instance. Note however, they are unlikely to behave identically due to random numbers and other transient fields.- Specified by:
getConfigurationin interfaceConfigurable- Returns:
- the properties defining this instance
-