Main Page | Class Hierarchy | Class List | File List | Class Members | File Members

gal::MaxIntProblem Class Reference

Maximises an integer parameter (basic GA test) The chromosome with all 1's in its bitstring is the best. More...

#include <MaxIntProblem.h>

Inheritance diagram for gal::MaxIntProblem:

[legend]
List of all members.

Public Member Functions

Chromosome< int > *const constructChromosome (int chromoLength)
 Constructs a new Chromosome<int> suitable for representing integers.
Chromosome< int > *const copyChromosome (Chromosome< int > *chromo)
 Constructs a new IntChromosome, which is a copy of the specified chromosome.
void const deleteChromosome (Chromosome< int > *chromo)
 Deletes a Chromosome<T>* Usually this will be an instance of *a subclass of* Chromosome<T>.
double const evaluateObjective (Chromosome< int > *chromo)
 Evaluates the objective function for an input value.

Detailed Description

Maximises an integer parameter (basic GA test) The chromosome with all 1's in its bitstring is the best.


Member Function Documentation

Chromosome<int>* const gal::MaxIntProblem::constructChromosome int  chromoLength  )  [inline, virtual]
 

Constructs a new Chromosome<int> suitable for representing integers.

Implements gal::Problem< int >.

Chromosome<int>* const gal::MaxIntProblem::copyChromosome Chromosome< int > *  chromo  )  [inline, virtual]
 

Constructs a new IntChromosome, which is a copy of the specified chromosome.

(necessary, because static typing makes a copy constructor impossible)

Implements gal::Problem< int >.

void const gal::MaxIntProblem::deleteChromosome Chromosome< int > *  chromo  )  [inline, virtual]
 

Deletes a Chromosome<T>* Usually this will be an instance of *a subclass of* Chromosome<T>.

(necessary, because static typing would otherwise default to the superclass's destructor, and would then result in a memory leak.)

Implements gal::Problem< int >.

double const gal::MaxIntProblem::evaluateObjective Chromosome< int > *  chromo  )  [inline, virtual]
 

Evaluates the objective function for an input value.

Implements gal::Problem< int >.


The documentation for this class was generated from the following file:
Generated on Tue Oct 20 12:59:24 2009 for LabSci GALib optimisation by genetic algorithms, student version by  doxygen 1.3.9.1