Package org.moeaframework.core.selection
Class DifferentialEvolutionSelection
java.lang.Object
org.moeaframework.core.selection.DifferentialEvolutionSelection
- All Implemented Interfaces:
Selection
Selection operator to be used in conjunction with the
DifferentialEvolutionVariation
operator. The
select
method returns the solutions [currentIndex, r1, r2, ...]
, where currentIndex
is
set using the setCurrentIndex(int)
method and r1, r2, ...
are randomly selected solutions. The
returned solutions are guaranteed to have unique indices in the population, but the solutions themselves may not
be unique if the population contains duplicate solutions.-
Constructor Summary
ConstructorDescriptionConstructs a differential evolution selection operator. -
Method Summary
Modifier and TypeMethodDescriptionSolution[]
select
(int arity, Population population) Returns an array of lengtharity
of solutions selected from the specified population.void
setCurrentIndex
(int currentIndex) Sets the current index, which is the index of the first solution returned by theselect
method.
-
Constructor Details
-
DifferentialEvolutionSelection
public DifferentialEvolutionSelection()Constructs a differential evolution selection operator.
-
-
Method Details
-
setCurrentIndex
public void setCurrentIndex(int currentIndex) Sets the current index, which is the index of the first solution returned by theselect
method. If set to-1
, then the current index is randomly assigned each timeselect(int, Population)
is invoked.- Parameters:
currentIndex
- the current index
-
select
Description copied from interface:Selection
Returns an array of lengtharity
of solutions selected from the specified population.
-