MCScheduling 1.0
Set of Algorithms for Solving Mixed-Criticality Scheduling
|
The base public class for implementation of a genetic operator. More...
Public Member Functions | |
CGeneticOperator (CConfiguration configuration) | |
Creates and initializes the base crossover operator. | |
void | setConfiguration (CConfiguration configuration) |
Sets the configuration of a genetic algorithm that uses this operator. | |
CConfiguration | getConfiguration () |
Returns a configuration of a genetic algorithm that uses this operator. | |
Static Public Member Functions | |
static void | swapGenes (IChromosome x, IChromosome y, int i, int j) |
Performes a swap of the i-th gene in the first specified chromosome with the j-th gene in the second. | |
static void | swapGenes (IChromosome x, int i, int j) |
Performes a swap of the i-th gene with the j-th gene in the specified chromosome. | |
static void | swap< T > (ref T x, ref T y) |
Swaps the contents of the specified variables, i.e. | |
Protected Member Functions | |
void | getChromosomeSection (out int start, out int span, int minSpan, int maxSpan) |
Determines a random start point and span to a section given a minimum and maximum span size. |
The base public class for implementation of a genetic operator.
MCScheduling.GeneticAlgorithm.CGeneticOperator.CGeneticOperator | ( | CConfiguration | configuration | ) |
Creates and initializes the base crossover operator.
configuration | The configuration of the genetic algorithm that will utilize this operator. |
NullReferenceException | If confuguration is null. |
void MCScheduling.GeneticAlgorithm.CGeneticOperator.getChromosomeSection | ( | out int | start, |
out int | span, | ||
int | minSpan, | ||
int | maxSpan | ||
) | [protected] |
Determines a random start point and span to a section given a minimum and maximum span size.
start | The section's start point. |
span | The section's span. |
minSpan | The minimum span of the created section. |
maxSpan | The maximum span of the created section. |
CConfiguration MCScheduling.GeneticAlgorithm.CGeneticOperator.getConfiguration | ( | ) |
Returns a configuration of a genetic algorithm that uses this operator.
void MCScheduling.GeneticAlgorithm.CGeneticOperator.setConfiguration | ( | CConfiguration | configuration | ) |
Sets the configuration of a genetic algorithm that uses this operator.
configuration | The configuration of a genetic algorithm that uses this operator. |
static void MCScheduling.GeneticAlgorithm.CGeneticOperator.swap< T > | ( | ref T | x, |
ref T | y | ||
) | [static] |
Swaps the contents of the specified variables, i.e.
assigns the value of x to y, and vice versa.
x | The first variable whose content will be swapped. |
y | The second variable whose content will be swapped. |
static void MCScheduling.GeneticAlgorithm.CGeneticOperator.swapGenes | ( | IChromosome | x, |
IChromosome | y, | ||
int | i, | ||
int | j | ||
) | [static] |
Performes a swap of the i-th gene in the first specified chromosome with the j-th gene in the second.
x | The first chromosome whose gene will be swapped. |
y | The second chromosome whose gene will be swapped. |
i | The position of the gene in the first chromosome that will be swapped. |
j | The position of the gene in the second chromosome that will be swapped. |
static void MCScheduling.GeneticAlgorithm.CGeneticOperator.swapGenes | ( | IChromosome | x, |
int | i, | ||
int | j | ||
) | [static] |
Performes a swap of the i-th gene with the j-th gene in the specified chromosome.
x | The chromosome whose genes will be swapped. |
i | The position of the first gene that will be swapped. |
j | The position of the second gene that will be swapped. |