MCScheduling 1.0
Set of Algorithms for Solving Mixed-Criticality Scheduling
|
The roulette wheel selection is one of the standard fitness-proportional selection methods. More...
Public Member Functions | |
CRouletteWheelSelector (CConfiguration configuration) | |
Instantiates a new roulette wheel selector. | |
void | notify (CConfiguration configuration) |
Invoked when the genetic algorithm is about to be executed. | |
override void | select (CPopulation population, CPopulation matingPool, int toSelectCount) |
Selects a chromosome from the specified population according to its fitness. |
The roulette wheel selection is one of the standard fitness-proportional selection methods.
It chooses chromosomes according to their fitness value in such a way that the fitter the chromosome the more probability it has of being selected. It does not guarantee, tough, that the fittest chromosome is being selected, it is just more likely it will happen, and that is why it is a good idea to use elitism along with this selector.
The selector works in this way: the population's total fitness score is represented by a pie chart - a roulette wheel - a slice of the wheel is assigned to an individual chromosome of the population, and the size of the slice is proportional to the chromosome's fitness, i.e. the fitter the chromosome, the bigger the slice. Then the wheel is spun, and a ball tossed in it. The chromosome whose slice the ball stops on is then selected and inserted into so called mating pool. This process is repeated until the mating pool is full (the desired number of selected chromosomes has been reached).
MCScheduling.GeneticAlgorithm.CRouletteWheelSelector.CRouletteWheelSelector | ( | CConfiguration | configuration | ) |
Instantiates a new roulette wheel selector.
configuration | The configuration of the genetic algorithm that will utilize this selector. |
NullReferenceException | If confuguration is null. |
void MCScheduling.GeneticAlgorithm.CRouletteWheelSelector.notify | ( | CConfiguration | configuration | ) |
Invoked when the genetic algorithm is about to be executed.
configuration | The configuration of the genetic algorithm that uses this selector. |
Implements MCScheduling.GeneticAlgorithm.IConfigurationDependent.
override void MCScheduling.GeneticAlgorithm.CRouletteWheelSelector.select | ( | CPopulation | population, |
CPopulation | matingPool, | ||
int | toSelectCount | ||
) | [virtual] |
Selects a chromosome from the specified population according to its fitness.
See the description of the algorithm in the description of this class.
population | The population the chromosome will be selected from. |
matingPool | The mating pool the chromosome will be inserted into. |
toSelectCount | The total number of chromosomes to select. |
Implements MCScheduling.GeneticAlgorithm.CBaseSelectionOperator.