Main Page   Class Hierarchy   Compound List   File List   Compound Members   File Members  

BinaryTestEAEnv Class Reference

Environment for making EA experiments with a binary-valued genomes. More...

#include <testenv.h>

Inheritance diagram for BinaryTestEAEnv:

EAEnvironment List of all members.

Public Methods

 BinaryTestEAEnv (int d, int nObjectives=1)
void changeObjective (int target)
virtual void addFeaturesTo (Genome &genome) const
virtual void init_cycle ()
virtual double evaluateg (const Individual &genome)
virtual void cycle_report (OStream &log, OStream &out)

Detailed Description

Environment for making EA experiments with a binary-valued genomes.

Definition at line 40 of file testenv.h.


Constructor & Destructor Documentation

BinaryTestEAEnv int    d,
int    nObjectives = 1
 

Creates a binary test environment.

Parameters:
d  Dimension, i.e. number of binary genes in the genome.
nObjectives  Number of alternative minima (objectives) in the search problem.

Definition at line 43 of file testenv.cc.

References changeObjective().


Member Function Documentation

void addFeaturesTo Genome   genome const [virtual]
 

Adds problem-specific features to a genome.

Reimplemented from EAEnvironment.

Definition at line 56 of file testenv.cc.

References Gentainer::add().

void changeObjective int    target
 

Changes objective to another target (usually 0 or 1).

Definition at line 48 of file testenv.cc.

Referenced by BinaryTestEAEnv().

void cycle_report OStream &    log,
OStream &    out
[virtual]
 

Prints some statistics or something at the end of the evaluation cycle.

Reimplemented from EAEnvironment.

Definition at line 79 of file testenv.cc.

double evaluateg const Individual   indiv [virtual]
 

Evaluates the fitness of the given individual in the environment.

MUST OVERLOAD!

Exceptions:
must_overload 

Reimplemented from EAEnvironment.

Definition at line 65 of file testenv.cc.

References Individual::getGene().

virtual void init_cycle   [inline, virtual]
 

Initializes a generation.

Not necessary in all models.

Reimplemented from EAEnvironment.

Definition at line 62 of file testenv.h.


The documentation for this class was generated from the following files:
Generated on Thu Feb 10 20:12:01 2005 for NeHeP by doxygen1.2.18