Main Page   Class Hierarchy   Compound List   File List   Compound Members  

pheromone Class Reference

A class implementing pheromones. More...

#include <pheromone.h>

List of all members.

Public Methods

 pheromone (portion *location, char hemisphere)
 Creates a pheromone object. More...

 ~pheromone ()
void update ()
 Makes the pheromones spread due to wind, air dynamics, and dispear under molecular unstability.

double modifyDeparture (double modifier)
 Changes the amount (better : density) of departure pheromones. More...

double modifyReturn (double modifier)
 Changes the amount (better : density) of return pheromones. More...

double getDeparture ()
 Returns the amount of departure pheromones (the type ants lay down when they are looking for food).

double getReturn ()
 Returns the amount of return pheromones (the kind ants lay down when they are making their way home.

double getPheromone (char type)
 Returns the amount of a given type of pheromone. More...

char getHemisphere ()
 Returns the pheromone species. More...

double getMax ()
 Returns the maximum pheromone intensity.


Detailed Description

A class implementing pheromones.


Constructor & Destructor Documentation

pheromone::pheromone portion   location,
char    hemisphere
 

Creates a pheromone object.

Parameters:
location  the portion the pheromone will be binded to
hemisphere  pheromone type, 0 for South, 1 for North


Member Function Documentation

char pheromone::getHemisphere  
 

Returns the pheromone species.

Returns:
1 for North, 0 for South

double pheromone::getPheromone char    type
 

Returns the amount of a given type of pheromone.

Parameters:
type  'r' for return, 'd' for departure

double pheromone::modifyDeparture double    modifier
 

Changes the amount (better : density) of departure pheromones.

Parameters:
modifier  will be added to the current density. Can be negative.

double pheromone::modifyReturn double    modifier
 

Changes the amount (better : density) of return pheromones.

Parameters:
modifier  will be added to the current density. Can be negative.


The documentation for this class was generated from the following files:
Generated on Mon Jun 14 09:29:38 2004 by doxygen1.2.15