GPLIB++
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
gplib::GeneralPropagation Class Referenceabstract

The base class for genetic algorithm propagation methods. More...

#include <GeneralPropagation.h>

Inheritance diagram for gplib::GeneralPropagation:
Inheritance graph
[legend]

Public Member Functions

virtual void NextGeneration ()=0
 
void SetParams (const double mutation, const double crossover)
 
 GeneralPropagation (GeneralSelect *const LocalSelect, GeneralPopulation *const LocalPopulation, GeneralRNG *const LocalRandom)
 
virtual ~GeneralPropagation ()
 
 GeneralPropagation (GeneralPropagation &Old)
 

Protected Member Functions

virtual void Crossover (tpopmember &father, tpopmember &mother)
 
virtual void Mutation (tpopmember &child)
 

Protected Attributes

GeneralSelect *const Select
 
GeneralPopulation *const Population
 
GeneralRNG *const Random
 
double MutationProb
 
double CrossoverProb
 

Detailed Description

The base class for genetic algorithm propagation methods.

This class defines the common functionality that is necessary to generate a new population from the current generation. The implementation details depend on the type of GA and Population encoding and those classes have to match to do anything useful.

Definition at line 17 of file GeneralPropagation.h.

Constructor & Destructor Documentation

gplib::GeneralPropagation::GeneralPropagation ( GeneralSelect *const  LocalSelect,
GeneralPopulation *const  LocalPopulation,
GeneralRNG *const  LocalRandom 
)

Definition at line 5 of file GeneralPropagation.cpp.

References CrossoverProb, and MutationProb.

gplib::GeneralPropagation::~GeneralPropagation ( )
virtual

Definition at line 20 of file GeneralPropagation.cpp.

gplib::GeneralPropagation::GeneralPropagation ( GeneralPropagation Old)

Definition at line 13 of file GeneralPropagation.cpp.

References CrossoverProb, and MutationProb.

Member Function Documentation

void gplib::GeneralPropagation::Crossover ( tpopmember father,
tpopmember mother 
)
protectedvirtual
void gplib::GeneralPropagation::Mutation ( tpopmember child)
protectedvirtual
virtual void gplib::GeneralPropagation::NextGeneration ( )
pure virtual
void gplib::GeneralPropagation::SetParams ( const double  mutation,
const double  crossover 
)
inline

Definition at line 29 of file GeneralPropagation.h.

References CrossoverProb, and MutationProb.

Referenced by main().

Member Data Documentation

double gplib::GeneralPropagation::CrossoverProb
protected

Definition at line 26 of file GeneralPropagation.h.

Referenced by Crossover(), GeneralPropagation(), and SetParams().

double gplib::GeneralPropagation::MutationProb
protected

Definition at line 25 of file GeneralPropagation.h.

Referenced by GeneralPropagation(), Mutation(), and SetParams().

GeneralPopulation* const gplib::GeneralPropagation::Population
protected

Definition at line 23 of file GeneralPropagation.h.

Referenced by gplib::StandardPropagation::NextGeneration().

GeneralRNG* const gplib::GeneralPropagation::Random
protected

Definition at line 24 of file GeneralPropagation.h.

Referenced by Crossover(), and Mutation().

GeneralSelect* const gplib::GeneralPropagation::Select
protected

Definition at line 22 of file GeneralPropagation.h.

Referenced by gplib::StandardPropagation::NextGeneration().


The documentation for this class was generated from the following files: