org.dishevelled.evolve.fitness
Class UniformFitness<I>

java.lang.Object
  extended by org.dishevelled.evolve.fitness.UniformFitness<I>
Type Parameters:
I - individual type
All Implemented Interfaces:
Fitness<I>

public final class UniformFitness<I>
extends Object
implements Fitness<I>

Uniform fitness function.

Version:
$Revision: 1059 $ $Date: 2012-01-03 14:03:02 -0600 (Tue, 03 Jan 2012) $
Author:
Michael Heuer

Field Summary
(package private) static double DEFAULT_SCORE
          Default score, 1.0d.
 
Constructor Summary
UniformFitness()
          Create a new uniform fitness function with the default score of 1.0d.
UniformFitness(double score)
          Create a new uniform fitness function with the specified score.
 
Method Summary
 Double score(I individual)
          Return a measure of fitness for the specified individual.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_SCORE

static final double DEFAULT_SCORE
Default score, 1.0d.

See Also:
Constant Field Values
Constructor Detail

UniformFitness

public UniformFitness()
Create a new uniform fitness function with the default score of 1.0d.


UniformFitness

public UniformFitness(double score)
Create a new uniform fitness function with the specified score.

Parameters:
score - uniform fitness score
Method Detail

score

public Double score(I individual)
Return a measure of fitness for the specified individual.

Specified by:
score in interface Fitness<I>
Parameters:
individual - individual
Returns:
a measure of fitness for the specified individual


Copyright (c) 2005-2012 held jointly by the individual authors. Licensed under the GNU Lesser General Public License (LGPL).