Returns the Fitness value weighted by some function. Use the RSGeneticBase.TRSCustomGeneticComponent.OnEvaluateWeightedFitness event to specify the weighting.
The genetic components can guide the search for the best individual by using the weighted fitness instead of the regular fitness. The weighted fitness allows optimization for something other than the pure fitness. For example, with genetic programming, the weighted fitness can be used to weight the fitness for smaller programs. The FitnessMethod specifies whether the Fitness or the WeightedFitness is used in the search.
Note that the Fitness is always used for determining if we have found the "best" individual for termination purposes.
Namespace: RSGeneticBase
Delphi |
public |
Property Value
Type: TGAFitness