|
MOEA Framework 2.5 API Specification |
|||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||
java.lang.Objectorg.moeaframework.algorithm.AbstractAlgorithm
org.moeaframework.algorithm.pso.AbstractPSOAlgorithm
public abstract class AbstractPSOAlgorithm
Abstract multi-objective particle swarm optimizer (MOPSO).
| Field Summary | |
|---|---|
protected NondominatedPopulation |
archive
The archive of non-dominated solutions; or null of no external
archive is sued. |
protected DominanceComparator |
dominanceComparator
Comparator for updating the local best particles. |
protected DominanceComparator |
leaderComparator
Comparator for selecting leaders. |
protected FitnessBasedArchive |
leaders
The leaders. |
protected int |
leaderSize
The number of leaders. |
protected Solution[] |
localBestParticles
The local best particles. |
protected Variation |
mutation
Mutation operator, or null if no mutation is defined. |
protected Solution[] |
particles
The particles. |
protected int |
swarmSize
The number of particles. |
protected double[][] |
velocities
The speed / velocity of each particle. |
| Fields inherited from class org.moeaframework.algorithm.AbstractAlgorithm |
|---|
initialized, numberOfEvaluations, problem, terminated |
| Constructor Summary | |
|---|---|
AbstractPSOAlgorithm(Problem problem,
int swarmSize,
int leaderSize,
DominanceComparator leaderComparator,
DominanceComparator dominanceComparator,
FitnessBasedArchive leaders,
NondominatedPopulation archive,
Variation mutation)
Constructs a new abstract PSO algorithm. |
|
| Method Summary | |
|---|---|
NondominatedPopulation |
getResult()
Returns the current best-known result. |
protected void |
initialize()
Performs any initialization that is required by this algorithm. |
protected void |
iterate()
Performs one iteration of the algorithm. |
protected void |
mutate()
Applies the mutation operator to all particles. |
protected void |
mutate(int i)
Applies the mutation operator to an individual particle. |
protected Solution |
selectLeader()
Randomly select a leader. |
protected void |
updateLocalBest()
Updates the local best particles. |
protected void |
updatePosition(int i)
Update the position of an individual particle. |
protected void |
updatePositions()
Update the positions of all particles. |
protected void |
updateVelocities()
Update the speeds of all particles. |
protected void |
updateVelocity(int i)
Update the speed of an individual particle. |
| Methods inherited from class org.moeaframework.algorithm.AbstractAlgorithm |
|---|
evaluate, evaluateAll, evaluateAll, finalize, getNumberOfEvaluations, getProblem, getState, isInitialized, isTerminated, setState, step, terminate |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected int swarmSize
protected int leaderSize
protected Solution[] particles
protected Solution[] localBestParticles
protected FitnessBasedArchive leaders
protected NondominatedPopulation archive
null of no external
archive is sued.
protected double[][] velocities
protected DominanceComparator leaderComparator
protected DominanceComparator dominanceComparator
protected Variation mutation
null if no mutation is defined.
| Constructor Detail |
|---|
public AbstractPSOAlgorithm(Problem problem,
int swarmSize,
int leaderSize,
DominanceComparator leaderComparator,
DominanceComparator dominanceComparator,
FitnessBasedArchive leaders,
NondominatedPopulation archive,
Variation mutation)
problem - the problemswarmSize - the number of particlesleaderSize - the number of leadersleaderComparator - comparator for selecting leadersdominanceComparator - comparator for updating the local best
particlesleaders - non-dominated population for storing the leadersarchive - non-dominated population for storing the external archive;
or null if no external archive is definedmutation - mutation operator, or null if no mutation is
defined| Method Detail |
|---|
protected void updateVelocities()
protected void updateVelocity(int i)
i - the index of the particleprotected void updatePositions()
protected void updatePosition(int i)
i - the index of the particleprotected Solution selectLeader()
protected void updateLocalBest()
protected void mutate()
protected void mutate(int i)
i - the index of the particlepublic NondominatedPopulation getResult()
Algorithm
protected void initialize()
AbstractAlgorithmAbstractAlgorithm.step(), but may also be called manually prior to any invocations
of step. Implementations should always invoke
super.initialize() to ensure the hierarchy is initialized
correctly.
initialize in class AbstractAlgorithmprotected void iterate()
AbstractAlgorithm
iterate in class AbstractAlgorithm
|
MOEA Framework 2.5 API Specification |
|||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||