|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object Population
public class Population
Field Summary | |
---|---|
static int |
DEFAULT_POPULATION_SIZE
A constant that will be used as the default size of the population |
Constructor Summary | |
---|---|
Population(int initialSize,
java.lang.String chain)
A constructor of arity 2 to initialize the Population. |
|
Population(java.lang.String chain)
A constructor of arity 1 to initialize the Population. |
Method Summary | |
---|---|
void |
evolve()
The method evolve selects parent chromosomes. |
Chromosome |
getFittest()
The instance method public Chromosome getFittest() returns the "best" individual of the population, i.e. |
java.lang.String |
toString()
Returns a String representation of this Population. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int DEFAULT_POPULATION_SIZE
Constructor Detail |
---|
public Population(int initialSize, java.lang.String chain)
size
- is the size of the population, the number of chromosomes to be
createdchain
- is the chain for which a fold is soughtpublic Population(java.lang.String chain)
chain
- is the chain for which a fold is soughtMethod Detail |
---|
public void evolve()
public Chromosome getFittest()
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |