JavaGenes, NASA Ames. Written largely by Al Globus

gov.nasa.javaGenes.core
Class ProductFitnessFunction

java.lang.Object
  extended bygov.nasa.javaGenes.core.FitnessFunction
      extended bygov.nasa.javaGenes.core.FitnessFunctionMultiObjective
          extended bygov.nasa.javaGenes.core.FitnessFunctionMultiObjectiveToOne
              extended bygov.nasa.javaGenes.core.ProductFitnessFunction
All Implemented Interfaces:
java.io.Serializable

public class ProductFitnessFunction
extends FitnessFunctionMultiObjectiveToOne

this fitness function is a product of fitness functions times their weights with one added to the fitness. One is the minimum fitness (the objectives are assumed to have positive fitness). Weights are generally expected be less than one, although that is not required. If the weighted fitenss before adding one is smaller than one, then the weight will have a strong effect on the total fitness. If the weighted fitness before adding one is large, then the scaling by weight will have little effect.

One is added because the best fitness is assumed to be zero and multiplication changes direction when below one.

This approach was recommended by Greg Hornby

See Also:
Serialized Form

Field Summary
 
Fields inherited from class gov.nasa.javaGenes.core.FitnessFunctionMultiObjective
fitnessFunctions, weights
 
Fields inherited from class gov.nasa.javaGenes.core.FitnessFunction
name
 
Constructor Summary
ProductFitnessFunction()
           
 
Method Summary
 Fitness evaluateFitness(Evolvable evolvable)
           
 
Methods inherited from class gov.nasa.javaGenes.core.FitnessFunctionMultiObjectiveToOne
getNameArray, numberOfObjectives
 
Methods inherited from class gov.nasa.javaGenes.core.FitnessFunctionMultiObjective
add, add, bestDouble, getFitnessFunction, getNewFitness, getWeight, makeFiles, toString, worstDouble
 
Methods inherited from class gov.nasa.javaGenes.core.FitnessFunction
getFunction, getName, isNewFunction, report, setName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ProductFitnessFunction

public ProductFitnessFunction()
Method Detail

evaluateFitness

public Fitness evaluateFitness(Evolvable evolvable)
Overrides:
evaluateFitness in class FitnessFunctionMultiObjective

JavaGenes, NASA Ames. Written largely by Al Globus