|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectgpalta.core.Individual
public abstract class Individual
Individuals are the objects that form the population and are modified throughout the evolution. The most common kind of Individual is a Tree, and this is what most applications should use. This class can be extended to create other types of evolutionary objects
Field Summary | |
---|---|
boolean |
fitCalculated
|
double |
hits
|
Constructor Summary | |
---|---|
Individual()
|
Method Summary | |
---|---|
abstract Individual |
deepClone()
Get a new, totally independent copy of this individual. |
abstract Output |
eval(ProblemData problemData)
|
abstract void |
evalVect(Output out,
TempVectorFactory tempVectorFactory,
ProblemData problemData)
|
abstract int |
getSize()
Get the size of this Individual, hopefully without recalculating it (ie. in the case of a Tree, without descending every node). |
boolean |
isOnPop()
Ask whether this Individual is already part of the population |
double |
readFitness()
Read this individual's fitness, without recalculating it |
void |
setFitness(double fit)
Store the fitness, so it doesn't need to be recalculated |
void |
setOnPop(boolean flag)
Record that this Individual was selected and is part of the population |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public boolean fitCalculated
public double hits
Constructor Detail |
---|
public Individual()
Method Detail |
---|
public abstract int getSize()
public abstract Individual deepClone()
public double readFitness()
public void setFitness(double fit)
fit
- The fitness valuepublic void setOnPop(boolean flag)
public boolean isOnPop()
public abstract Output eval(ProblemData problemData)
public abstract void evalVect(Output out, TempVectorFactory tempVectorFactory, ProblemData problemData)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |