All Packages Class Hierarchy This Package Previous Next Index
Class gpsys.Population
java.lang.Object
|
+----gpsys.Population
- public class Population
- extends Object
- implements Serializable
A Population holds all the Individuals of a generation. Additional
information is maintained such as the current generation number, the
average fitness and complexity of the Individuals, and the best individual
in the Population.
- Author:
- Adil Qureshi
Department of Computer Science,
University College London,
Gower St,
London WC1E 6BT,
UK.
-
averageComplexity
- The average number of nodes in the Individuals of the Population.
-
averageFitness
- The average fitness of the Population.
-
best
- The fittest Individual in the Population.
-
generation
- The current generation number.
-
gpParameters
- The GP parameters for the problem.
-
p
- The Individuals in this population.
-
Population(GPParameters)
-
-
evolve()
-
-
report(PrintWriter)
- Print a report of the population using the specified PrintWriter.
-
updateStats()
- Update the statistics for the Population.
p
public Individual p[]
- The Individuals in this population.
generation
public int generation
- The current generation number.
best
public Individual best
- The fittest Individual in the Population.
averageFitness
public Fitness averageFitness
- The average fitness of the Population.
averageComplexity
public double averageComplexity
- The average number of nodes in the Individuals of the Population.
gpParameters
public GPParameters gpParameters
- The GP parameters for the problem.
Population
public Population(GPParameters gpParameters)
evolve
public void evolve()
updateStats
public void updateStats()
- Update the statistics for the Population. This involves finding the
individual with the highest fitness, calculating the average fitness
over the population and calculating the average complexity over the
population.
report
public void report(PrintWriter pw)
- Print a report of the population using the specified PrintWriter. The
report includes the generation number just completed, the date and time
of completion, the average Fitness, the average complexity and a dump
of the best Individual.
- Parameters:
- The - PrintWriter to use to write the report.
All Packages Class Hierarchy This Package Previous Next Index