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

MutationRate Class Reference

A parameter-passing class for passing mutation rates to atomic genes BinaryGene, AnyIntGene, and AnyFloatGene. More...

#include <genetics.h>

List of all members.

Public Methods

 MutationRate (const MutationRate &o, const MutationRate &m)
 MutationRate (const Gentainer &g)
double binaryRate () const
double intRate () const
double doubleRate () const
double doubleVariance () const
void binaryRate (double x)
void intRate (double x)
void doubleRate (double x)
void doubleVariance (double x)
void oneBitMutation (bool mt)
bool oneBitMutation () const
void autoAdaptation (bool aa)
bool autoAdaptation () const

Static Public Methods

void addGenesTo (Gentainer &g, const StringMap &params)


Detailed Description

A parameter-passing class for passing mutation rates to atomic genes BinaryGene, AnyIntGene, and AnyFloatGene.

Definition at line 151 of file genetics.h.


Constructor & Destructor Documentation

MutationRate const MutationRate &    o,
const MutationRate &    m
[inline]
 

Constructs the object by multiplying two existing mutation rates.

Definition at line 174 of file genetics.h.

References mAutoAdaptation, mBinaryRate, mFloatRate, mFloatVariance, mIntRate, and mOneBitMutation.

MutationRate const Gentainer   g
 

Reads the mutation rates from the given gentainer.

Definition at line 51 of file genetics.cc.

References Gentainer::getGene().


Member Function Documentation

void addGenesTo Gentainer   g,
const StringMap &    params
[static]
 

Adds the genes controlling the mutation rates to the given gentainer.

Definition at line 61 of file genetics.cc.

References Gentainer::add(), and Genstruct::hide().

Referenced by Gentainer::addPrivateGenes().

bool autoAdaptation   const [inline]
 

Returns the state of autoadaptivity.

Definition at line 223 of file genetics.h.

void autoAdaptation bool    aa [inline]
 

Setting this to TRUE causes the message-passing to read the autoadaptation genes from the Gentainer objects.

Definition at line 220 of file genetics.h.

Referenced by FloatGene::pointMutate(), BinaryGene::pointMutate(), Population::Population(), and SimplePopulation::SimplePopulation().

void binaryRate double    x [inline]
 

Sets the mutation rate for BinaryGene.

Definition at line 200 of file genetics.h.

double binaryRate   const [inline]
 

Returns the mutation rate for BinaryGene.

Definition at line 191 of file genetics.h.

Referenced by Gentainer::pointMutate(), BinaryGene::pointMutate(), Population::Population(), and EAStrategy::print().

void doubleRate double    x [inline]
 

Sets the mutation rate for FloatGene.

Definition at line 204 of file genetics.h.

double doubleRate   const [inline]
 

Returns the mutation rate for FloatGene.

Definition at line 195 of file genetics.h.

Referenced by Gentainer::pointMutate(), FloatGene::pointMutate(), Population::Population(), and EAStrategy::print().

void doubleVariance double    x [inline]
 

Sets the mutation variance for FloatGene.

Definition at line 206 of file genetics.h.

double doubleVariance   const [inline]
 

Returns the mutation variance for FloatGene.

Definition at line 197 of file genetics.h.

Referenced by Gentainer::pointMutate(), IntGene::pointMutate(), FloatGene::pointMutate(), Population::Population(), and EAStrategy::print().

void intRate double    x [inline]
 

Sets the mutation rate for IntGene.

Definition at line 202 of file genetics.h.

double intRate   const [inline]
 

Returns the mutation rate for IntGene.

Definition at line 193 of file genetics.h.

Referenced by IntGene::pointMutate(), Population::Population(), and EAStrategy::print().

bool oneBitMutation   const [inline]
 

Returns:
The value of the oneBitMutation flag.

Definition at line 215 of file genetics.h.

void oneBitMutation bool    mt [inline]
 

Order that only a SINGLE leaf-level genstruct should be mutated.

Definition at line 210 of file genetics.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