public class Nsga2 extends Object implements Selector
Nsga2Module,
"A Fast Elitist Non-Dominated Sorting Genetic Algorithm for
Multi-Objective Optimization: NSGA-II, K. Deb, Samir Agrawal, Amrit
Pratap, and T. Meyarivan, Parallel MockProblem Solving from Nature,
2000"| Constructor and Description |
|---|
Nsga2(Rand random,
int tournament,
FrontDensityIndicator indicator)
|
| Modifier and Type | Method and Description |
|---|---|
List<List<Individual>> |
fronts(Collection<Individual> individuals)
Evaluate the fronts and set the correspondent rank values.
|
Collection<Individual> |
getLames(int n,
Collection<Individual> population)
|
Collection<Individual> |
getParents(int mu,
Collection<Individual> population)
Selects a subset of
Individuals and returns it as a new
Collection. |
void |
init(int maxsize)
Sets the maximal number of
Individuals. |
@Inject public Nsga2(Rand random, int tournament, FrontDensityIndicator indicator)
random - the random number generatortournament - the tournament valuepublic void init(int maxsize)
SelectorIndividuals.public Collection<Individual> getParents(int mu, Collection<Individual> population)
SelectorIndividuals and returns it as a new
Collection. These so called parents can be used to form the next
generation.getParents in interface Selectormu - the number of parents to selectpopulation - the list of individualspublic Collection<Individual> getLames(int n, Collection<Individual> population)
Selectorlambda Individuals and returns it as
a new Collection. These individuals can be erased in the next
generation.public List<List<Individual>> fronts(Collection<Individual> individuals)
individuals - the individuals