bwer::Chromo Class Reference

List of all members.

Public Member Functions

double getFitness () const
double calcFitness ()
void setFitnessFunc (double(*fn)(void *, const Chromo &), void *arg)
Chromo anneal (code::Random &rnd, double fitnResol=0.001) const
 Chromo (const std::vector< Gene > &i_genes)
bool setGeneParms (const char *fileName)
void mutate (double sigma, code::Random &rnd)
void randomize (code::Random &rnd)
double getDiversity (const Chromo &otherChromo) const
void print (FILE *fp)
Chromo crossover (const Chromo &male, code::Random &rnd)
 Chromo ()

Public Attributes

std::vector< Genegenes

Protected Attributes

bool fitnessCalculated
double(* fitnessFunc )(void *, const Chromo &)
void * fitfuncArgs
double fitness

Friends

bool operator< (const Chromo &a, const Chromo &b)
bool operator> (const Chromo &a, const Chromo &b)

Constructor & Destructor Documentation

bwer::Chromo::Chromo ( const std::vector< Gene > &  i_genes  )  [inline]

bwer::Chromo::Chromo (  )  [inline]


Member Function Documentation

Chromo bwer::Chromo::anneal ( code::Random &  rnd,
double  fitnResol = 0.001 
) const

double bwer::Chromo::calcFitness (  )  [inline]

Chromo bwer::Chromo::crossover ( const Chromo male,
code::Random &  rnd 
)

double bwer::Chromo::getDiversity ( const Chromo otherChromo  )  const

double bwer::Chromo::getFitness (  )  const [inline]

void bwer::Chromo::mutate ( double  sigma,
code::Random &  rnd 
) [inline]

void bwer::Chromo::print ( FILE *  fp  ) 

void bwer::Chromo::randomize ( code::Random &  rnd  )  [inline]

void bwer::Chromo::setFitnessFunc ( double(*)(void *, const Chromo &)  fn,
void *  arg 
) [inline]

bool bwer::Chromo::setGeneParms ( const char *  fileName  ) 


Friends And Related Function Documentation

bool operator< ( const Chromo a,
const Chromo b 
) [friend]

bool operator> ( const Chromo a,
const Chromo b 
) [friend]


Member Data Documentation

void* bwer::Chromo::fitfuncArgs [protected]

double bwer::Chromo::fitness [protected]

bool bwer::Chromo::fitnessCalculated [protected]

double(* bwer::Chromo::fitnessFunc)(void *, const Chromo &) [protected]

std::vector<Gene> bwer::Chromo::genes


Generated on Fri May 4 13:40:21 2012 for WDSS-IIw2algs by  doxygen 1.4.7