#include <cChoosOperator.h>
List of all members.
Detailed Description
Definition at line 63 of file cChoosOperator.h.
Constructor & Destructor Documentation
enviroment::cChoosOperator::cChoosOperator |
( |
| ) |
|
virtual enviroment::cChoosOperator::~cChoosOperator |
( |
| ) |
|
|
virtual |
Member Function Documentation
virtual cOperation* enviroment::cChoosOperator::choosOperator |
( |
| ) |
const |
|
virtual |
This method selects an operator. The selection method is weelselction. Every operator has a propability p_i of selection which, is proportional to it's fitnessvalue plus the ratio of the fitnesssum of all operations divieded by the number of operations and 1000 .
minFitness = the minimum fitness (
- See also:
- cOperatorFitnessAlgorithm::getMinFitness()) minFitness2 = minFitness - fitnesssum / (#operations * 1000)) fitnesssum2 = fitnesssum - minFitness2 * #operations p_i = (fitness_i - minFitness2) / fitnesssum2
- Returns:
- a pointer to the choosen operator, or NULL if non can be selected Beware: You have to delete the returned object after usage.
This method clones this object.
- Returns:
- a clone of this object
virtual std::string enviroment::cChoosOperator::getClassName |
( |
| ) |
const |
|
virtual |
- Returns:
- the name of this class
The documentation for this class was generated from the following file: