public class ElitisticListPopulation extends ListPopulation
Constructor and Description |
---|
ElitisticListPopulation(int populationLimit,
double elitismRate)
Creates a new ListPopulation instance and initializes its inner
chromosome list.
|
ElitisticListPopulation(java.util.List<Chromosome> chromosomes,
int populationLimit,
double elitismRate)
Creates a new ElitisticListPopulation instance.
|
Modifier and Type | Method and Description |
---|---|
double |
getElitismRate()
Access the elitism rate.
|
Population |
nextGeneration()
Start the population for the next generation.
|
void |
setElitismRate(double elitismRate)
Sets the elitism rate, i.e.
|
addChromosome, getChromosomes, getFittestChromosome, getPopulationLimit, getPopulationSize, iterator, setChromosomes, setPopulationLimit, toString
public ElitisticListPopulation(java.util.List<Chromosome> chromosomes, int populationLimit, double elitismRate)
chromosomes
- list of chromosomes in the populationpopulationLimit
- maximal size of the populationelitismRate
- how many best chromosomes will be directly transferred to the
next generation [in %]public ElitisticListPopulation(int populationLimit, double elitismRate)
populationLimit
- maximal size of the populationelitismRate
- how many best chromosomes will be directly transferred to the
next generation [in %]public Population nextGeneration()
elitismRate
percents of the best
chromosomes are directly copied to the next generation.
public void setElitismRate(double elitismRate)
elitismRate
- how many best chromosomes will be directly transferred to the
next generation [in %]public double getElitismRate()
"Copyright © 2010 - 2020 Adobe Systems Incorporated. All Rights Reserved"