JGAP

examples.multiobjective
Class MOFitnessEvaluator

java.lang.Object
  extended by examples.multiobjective.MOFitnessEvaluator
All Implemented Interfaces:
java.io.Serializable, FitnessEvaluator

public class MOFitnessEvaluator
extends java.lang.Object
implements FitnessEvaluator

Fitness evaluator for multi objectives example. Determines which of two vectors with multiobjective values is fitter. In our example, the fitter vector is the one for which the sum of the values is smaller.

Since:
2.6
See Also:
Serialized Form

Constructor Summary
MOFitnessEvaluator()
           
 
Method Summary
 boolean isFitter(double a_fitness_value1, double a_fitness_value2)
          Not to be called in multi-objectives context!
 boolean isFitter(IChromosome a_chrom1, IChromosome a_chrom2)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MOFitnessEvaluator

public MOFitnessEvaluator()
Method Detail

isFitter

public boolean isFitter(double a_fitness_value1,
                        double a_fitness_value2)
Not to be called in multi-objectives context! Instead, oOther method below applies for multi-objectives.

Specified by:
isFitter in interface FitnessEvaluator
Parameters:
a_fitness_value1 - ignored
a_fitness_value2 - ignored
Returns:
always a RuntimeException
Since:
2.6

isFitter

public boolean isFitter(IChromosome a_chrom1,
                        IChromosome a_chrom2)
Specified by:
isFitter in interface FitnessEvaluator

JGAP