GetPopulParam

<< Click to Display Table of Contents >>

Navigation:  »No topics above this level«

GetPopulParam

Return to chapter overview

 

GetPopulParam(Population As Integer, GenerationNum As Integer, PopulationSize As Integer, TotalChromo As Integer, TotalPool As Integer, TotalEnumChromo As Integer)

Purpose: This function returns the main parameters of the population currently evolving in memory. GetPopulParam is useful for debugging.

 

Arguments:

Population is the number of the population for which you desire to know the parameters.

GenerationNum is the integer variable where the number of generations will be stored.  GALIB32.DLL contains an internal generation counter which increments after the Reproduce function is called.

PopulationSize is the integer variable where the number of individuals will be stored.

TotalChromo is the integer variable where the total number of chromosomes will be stored.

TotalPool is the integer variable where the total number of chromosome pools will be stored.

TotalEnumChromo is the integer variable where the total number of enumerated chromosomes will be stored.

 

Example: i = GetPopulParam(PopNum, GenNum, PopSize, TotChromo, TotPool, TotEnumChromo)

 

This example stores the generation counter value in the variable GenNum, the population size in PopSize, the total number of chromosomes in TotChromo, the total number of selection pools in TotPool, and the total number of enumerated chromosomes in TotEnumChromo.  All parameters are returned for the population specified by the PopNum variable.

 

Related Functions:  none