Fitness / fitness function / fitness landscape
A fitness function is a particular type of objective function that is used to summarise, as a single figure of merit, how close a given design solution is to achieving the set aims. The function takes a candidate solution to the problem as input and produces as output how “fit” our how “good” the solution is with respect to the problem in consideration.[2]
Requirements for a fitness function:
- The fitness function should be clearly defined. The reader should be able to clearly understand how the fitness score is calculated.
- The fitness function should be implemented efficiently. If the fitness function becomes the bottleneck of the algorithm, then the overall efficiency of the genetic algorithm will be reduced.
- The fitness function should quantitatively measure how to fit a given solution is in solving the problem.
- The fitness function should generate intuitive results. The best/worst candidates should have best/worst score values.