Fitness function
A fitness function is the objective function of an evolutionary (optimization) algorithm (EA). Occasionally a fitness function is also described as part of an objective function or vice versa. Like evolutionary algorithms, fitness functions have a biological model, biological fitness , which indicates the degree of adaptation of an organism to its environment. In evolutionary algorithms, the fitness of a candidate describes how well he solves the underlying optimization problem. The fitness function uses the properties of an attempted solution to calculate how well this "individual" is suitable as a solution to the problem posed.
A fitness function does not necessarily have to be able to calculate an absolute value, since it is often enough to compare candidates in order to select the better one. A relative statement of fitness (candidate a is better than b ) is sufficient in some cases, e.g. B. in the tournament selection .
If a solution is sought for several problems at the same time ( multi-objective optimization ) and these cannot be combined, the fitness function does not return a single value , but a tuple .
Examples
A passenger seat for aircraft is to be optimized, there are various objectives for this:
- it should be as light as possible;
- it should be as round as possible and not angular;
- it should be inexpensive to manufacture;
- it should use as little material as possible that is difficult to recycle.
The fitness function then uses the geometry parameters to calculate a tuple with four numbers ("the smaller the number, the better"):
{ Weight ; Sum_of_ edge lengths; Manufacturing costs; Mass_bad material}
Different seat geometries can then be classified on the basis of their associated tuples: Which variant is the easiest, which costs the least?