|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface Evolvable
This interface allows any class to be evolvable by org.jscience.computing.ai.evolutionary.GeneticAlgorithm. It is derived
from Comparable so they classes can be efficiently sorted by
the GA. Invariably, this is done by fitness.
| Method Summary | |
|---|---|
void |
calculateFitness()
Calculate the fitness of this object. |
double |
getFitness()
Return the fitness of this object. |
Evolvable |
mate(Evolvable partner)
Mate with another Evolvable type. |
void |
mutate()
Mutate the class data. |
void |
randomInitialize()
Initialize the class to random values. |
| Methods inherited from interface java.lang.Comparable |
|---|
compareTo |
| Method Detail |
|---|
void randomInitialize()
void mutate()
Evolvable mate(Evolvable partner)
Evolvable type. It is entirely up
to the class implementator how to implement the mating; one-point,
two-point crossover etc.
partner - the other mate.
this and partner.void calculateFitness()
double getFitness()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||