|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.encog.ml.genetic.genome.Chromosome
public class Chromosome
Implements a chromosome to genetic algorithm. This is an abstract class. Other classes are provided in this book that use this base class to train neural networks or provide an answer to the traveling salesman problem. Chromosomes are made up of genes. Genomes in this genetic algorithm consist of one or more chromosomes.
| Constructor Summary | |
|---|---|
Chromosome()
|
|
| Method Summary | |
|---|---|
void |
add(Gene gene)
Add a gene. |
Gene |
get(int i)
Get an individual gene. |
Gene |
getGene(int gene)
Get the specified gene. |
List<Gene> |
getGenes()
Used the get the entire gene list. |
int |
size()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Chromosome()
| Method Detail |
|---|
public final void add(Gene gene)
gene - The gene to add.public final Gene get(int i)
i - The index of the gene.
public final Gene getGene(int gene)
gene - The specified gene.
public final List<Gene> getGenes()
public final int size()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||