Evocosm - A C++ Framework for Evolutionary Computing

Main Index

Created by Scott Robert Ladd at Coyote Gulch Productions.


Public Member Functions | List of all members
libevocosm::random_pool_migrator< OrganismType > Class Template Reference

A pool-based migrator. More...

#include <migrator.h>

Inheritance diagram for libevocosm::random_pool_migrator< OrganismType >:
libevocosm::migrator< OrganismType > libevocosm::globals

Public Member Functions

 random_pool_migrator (size_t a_how_many)
 Constructor. More...
 
virtual void migrate (vector< vector< OrganismType > > &a_populations)
 Emigrate organisms to pool. More...
 
- Public Member Functions inherited from libevocosm::migrator< OrganismType >
virtual ~migrator ()
 Virtual destructor. More...
 

Additional Inherited Members

- Static Protected Member Functions inherited from libevocosm::globals
static size_t rand_index (size_t n)
 Static function to allow use of g_random function pointer in random_shuffle.
 
static void set_random_seed (uint32_t a_seed)
 Set the seed for the random number generator.
 
static uint32_t get_seed ()
 Set the seed for the random number generator.
 
static std::string version ()
 Get version number.
 
- Static Protected Attributes inherited from libevocosm::globals
static prng g_random
 A shared random number generator.
 
static std::string g_version
 Version number.
 

Detailed Description

template<class OrganismType>
class libevocosm::random_pool_migrator< OrganismType >

The pool_migrator maintains a pool of organisms taken from one or more populations, which are then available for immigration to other populations.

Constructor & Destructor Documentation

template<class OrganismType >
libevocosm::random_pool_migrator< OrganismType >::random_pool_migrator ( size_t  a_how_many)
inline

Creates a new pool_migrator.

Member Function Documentation

template<class OrganismType >
virtual void libevocosm::random_pool_migrator< OrganismType >::migrate ( vector< vector< OrganismType > > &  a_populations)
inlinevirtual

Copies organisms from the target population based on the constructor setting.

Parameters
a_populations- Set of organism populations between which members will "migrate"

Implements libevocosm::migrator< OrganismType >.

References libevocosm::globals::rand_index().


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

© 1996-2005 Scott Robert Ladd. All rights reserved.
HTML documentation generated by Dimitri van Heesch's excellent Doxygen tool.