Version 1.2 (June 2013)
 All Classes Namespaces Files Functions Variables Pages
Classes | Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | Static Protected Attributes | List of all members
simulator.agent.LocatedAgent Class Reference

Extends ActiveAgent by adding functionality to control agent grid location, agent shoving, agent death and division, and agent movement. More...

Inheritance diagram for simulator.agent.LocatedAgent:
simulator.agent.ActiveAgent simulator.agent.SpecialisedAgent simulator.agent.HasReaction simulator.agent.Agent simulator.agent.HasSpecies simulator.agent.zoo.Bacterium simulator.agent.zoo.ParticulateEPS simulator.agent.zoo.BactEPS simulator.agent.zoo.BactAdaptable

Classes

class  detPriorityComparator
 Comparator used by AgentContainer.erodeBorder()
 
class  totalMassComparator
 Comparator used by AgentContainer.erodeBorder()
 

Public Member Functions

 LocatedAgent ()
 Constructor used to generate progenitor and initialise an object to store relevant parameters. More...
 
Object clone () throws CloneNotSupportedException
 Creates a daughter Located Agent by cloning this agent and parameter objects. More...
 
void createNewAgent (ContinuousVector position)
 Create a new agent in a specified position. More...
 
void registerBirth ()
 Registers a created agent into a respective container. Each agent must be referenced by one such container. More...
 
void initFromProtocolFile (Simulator aSim, XMLParser xmlMarkUp)
 Creates an agent of the specified species and notes the grid in which this is assigned. More...
 
void initFromResultFile (Simulator aSim, String[] singleAgentData)
 Create an agent using information in a previous state or initialisation file. More...
 
void updateSize ()
 
void divide ()
 Captures cell division by making a clone of this agent using the makeKid method. More...
 
boolean willDivide ()
 Determines whether or not a cell has reached the radius where cell division can be triggered. More...
 
boolean willDie ()
 Determines whether or not a cell has reached the radius where cell death can be triggered. More...
 
void die (boolean isStarving)
 Kills an agent. Called by detachment and starving test. More...
 
void makeKid () throws CloneNotSupportedException
 With it determined that cell division will occur, create a new agent from the existing one. More...
 
void divideCompounds (LocatedAgent baby, double babyMassFrac)
 On agent division, divides the mass between the old and new agent, at a specified fraction. More...
 
void transferCompounds (LocatedAgent baby, double splitRatio)
 On agent division, transfers EPS between the old and new agent, at a specified ratio. More...
 
void mutatePop ()
 Mutate any inherited parameters for a population of agents. More...
 
void setDivisionDirection (double distance)
 Set the movement vector that states where to put a newly-created particle. More...
 
double interact (boolean MUTUAL, boolean shoveOnly, boolean seq, double gain)
 Models a mechanical interaction between two located agents. Implemented by extending classes (LocatedAgent) More...
 
boolean addPushMovement (LocatedAgent aNeighbour, boolean isMutual, double gain)
 Mutual shoving : The movement by shoving of an agent is calculated based on the cell overlap and added to the agents movement vector. More...
 
boolean addSpringMovement (LocatedAgent aNeighbor, boolean isMutual, double gain)
 Pulling : The movement of agents by a shrinking biofilm. Move calculated and added to the agents movement vector. More...
 
double computeDifferenceVector (ContinuousVector me, ContinuousVector him)
 Computes the shortest distance between this agent and another, stored as ContinuousVectors. This may be around the cyclic boundary. More...
 
void getPotentialShovers (double radius)
 Find neighbouring agents in a range around you. More...
 
LocatedAgent pickNeighbor ()
 Pick a random neighbour from the _myNeigbors collection. More...
 
void findCloseSiblings (int indexSpecies)
 Find a sibling of this agent. More...
 
double move ()
 With the agent move calculated, apply this movement, taking care to respect boundary conditions. More...
 
void checkBoundaries ()
 Used by the move method to determine if an agents move crosses any of the domain's boundaries. More...
 
void mutateAgent ()
 Mutate inherited agent parameters after agent division. More...
 
void fitMassOnGrid (SpatialGrid aSpG, int catalystIndex)
 Add the reacting concentration of an agent to the received grid. More...
 
void fitMassOnGrid (SpatialGrid aSpG)
 Add the total concentration of an agent on received grid. More...
 
void fitVolRateOnGrid (SpatialGrid aSpG)
 Add the total volume rate of an agent on received grid. More...
 
void fitReacRateOnGrid (SpatialGrid aRateGrid, int reactionIndex)
 Add the reaction/growth rate of an agent on received grid, for a specified reaction. More...
 
String sendHeader ()
 Used in creation of results files - specifies the header of the columns of output information for this agent. More...
 
String writeOutput ()
 Used in creation of results files - creates an output string of information generated on this particular agent. More...
 
void updateVolume ()
 Compute the volume on the basis of the mass and density of different compounds defined in the cell. More...
 
void updateRadius ()
 
AllBC updateAttachment ()
 Update the attachment, determining if an agent location crosses any boundaries. More...
 
void addMovement (ContinuousVector aMove)
 Add movement to the ContinuousVector storing the agents move. More...
 
LocatedParam getSpeciesParam ()
 Return the set of parameters associated with this agent (LocatedParam object) More...
 
double getVolume (boolean withCapsule)
 Return the volume of this agent, with or without the capsule. More...
 
double getRadius (boolean withCapsule)
 Return the radius of this agent, with or without the capsule. More...
 
double getMass (boolean withCapsule)
 Return the mass of this agent, with or without the capsule. More...
 
double getMaximumRadius ()
 
boolean hasEPS ()
 Determine whether this cell has any EPS. More...
 
boolean hasInert ()
 Determine whether this agent contains any inert particles. More...
 
double getShoveFactor ()
 Return the shove factor to be used in shoving for this species of agent. More...
 
double getShoveRadius ()
 Return the shove radius to be used in shoving for this species of agent. More...
 
double getInteractDistance ()
 Return the shoving interaction distance to be used in shoving for this species of agent. More...
 
double getInteractDistance (LocatedAgent baby)
 Return the shoving interaction distance to be used in shoving against a specified agent. More...
 
double getBabyMassFrac ()
 Return the fraction of mass that is transferred to the new agent on cell division. More...
 
double getDivRadius ()
 Return the agent radius at which cell division is triggered. More...
 
double getDeathRadius ()
 Return the agent radius at which cell death is triggered. More...
 
boolean isMoving ()
 Determine if an agent has a move to perform. More...
 
boolean isAttached ()
 Determine if an agent is attached to a surface. More...
 
double getActiveFrac ()
 Return the active fraction of this agent. More...
 
Color getColor ()
 Return the colour assigned to this agent in POV-Ray output. More...
 
Color getColorCapsule ()
 Return the colour assigned to any capsules contained in this agent in POV-Ray output. More...
 
ContinuousVector getLocation ()
 Return the location of this agent. More...
 
double getDistance (LocatedAgent aLoc)
 Return the distance between two agents. More...
 
void setLocation (ContinuousVector cc)
 Set the location of this agent to the supplied continuous vector. More...
 
ContinuousVector getMovement ()
 Return the continuous vector that states this agents move. More...
 
int getGridIndex ()
 Return the index of the grid on which this agent is placed. More...
 
LocatedGroup getGridElement ()
 Return the LocatedGroup of agents that are present in the location where this agent is placed. More...
 
void setGridIndex (int aGridIndex)
 Move this agent to another grid index. More...
 
Domain getDomain ()
 Return the domain where this agent is contained. More...
 
- Public Member Functions inherited from simulator.agent.ActiveAgent
 ActiveAgent ()
 Creates an ActiveAgent object and initialises the object in which associated parameters are stored. More...
 
void initFromProtocolFile (Simulator aSim, XMLParser xmlMarkUp)
 Creates an agent of the specified species and notes the grid in which this is assigned. More...
 
void initFromResultFile (Simulator aSim, String[] singleAgentData)
 Create an agent using information in a previous state or initialisation file. More...
 
void mutatePop ()
 Mutate any inherited parameters for a population of agents. More...
 
void createNewAgent ()
 Create a new agent with mutated parameters based on species default values. Agent is not located. More...
 
Object clone () throws CloneNotSupportedException
 Clones this agent object, creating a new progeny of this agent. Ensures new clone inherits same parameters as parents. More...
 
void mutateAgent ()
 Mutate any inherited parameters for this particular agent. More...
 
void die (boolean isStarving)
 Notifies the simulation that this agent has become too small and is then counted as dead. More...
 
void updateSize ()
 Update size of agent to take growth into account. More...
 
void updateMass ()
 Update mass of agent, summing the particle mass. More...
 
void addReaction (Reaction aReaction, boolean useDefaultParam)
 Add the reaction to the list of known reactions. More...
 
void addActiveReaction (Reaction aReaction, boolean useDefaultParam)
 Adds an active reaction to the list of known reactions and switches the reaction on. More...
 
void removeReaction (Reaction aPathway)
 Remove a reaction from the list of known reactions. More...
 
void switchOffreaction (Reaction aPathway)
 Switches off a reaction by removing it from the active reaction array. More...
 
void switchOnReaction (Reaction aReaction)
 Switches on a reaction by adding it to the active reaction array. More...
 
void registerOnAllActiveReaction ()
 Register the agent on each guild of its activated pathways. Called by makeKid. More...
 
void unregisterFromAllActiveReactions ()
 Called by the die method, to unregister the agent from all active reactions. More...
 
void fitMassOnGrid (SpatialGrid aSpG, int catalystIndex)
 Add the reacting concentration of an agent to the received grid. More...
 
void fitReacRateOnGrid (SpatialGrid aRateGrid, int reactionIndex)
 Add the reaction/growth rate of an agent on received grid, for a specified reaction. More...
 
void fitMassOnGrid (SpatialGrid aSpG)
 Add the total concentration of an agent on received grid. More...
 
String sendHeader ()
 Used in creation of results files - specifies the header of the columns of output information for this agent. More...
 
String writeOutput ()
 Used in creation of results files - creates an output string of information generated on this particular agent. More...
 
double getTotalMass ()
 Return total mass of this agent. More...
 
double getParticleMass (int particleIndex)
 Return particle mass of this agent. More...
 
double getNetGrowth ()
 Return net growth rate of this agent. More...
 
double getVolGrowth ()
 Return volume growth rate of this agent. More...
 
void setNetGrowth (double value)
 Set net growth rate of this agent. More...
 
double[] getSoluteYield (int indexReaction)
 Return solute yield for a particular reaction. More...
 
double[] getReactionKinetic (int indexReaction)
 Return the reaction kinetic parameters for a particular reaction. More...
 
ActiveParam getSpeciesParam ()
 Return the parameters associated with this agent (speciesParam) More...
 
- Public Member Functions inherited from simulator.agent.SpecialisedAgent
 SpecialisedAgent ()
 Creates a SpecialisedAgent object and initialises the object in which associated parameters are stored. More...
 
void initFromProtocolFile (Simulator aSim, XMLParser aSpeciesRoot)
 Creates an agent of the specified species and notes the grid in which this is assigned. More...
 
Object clone () throws CloneNotSupportedException
 Clones this agent object, creating a new progeny of this agent. Ensures new clone inherits same parameters as parents. More...
 
abstract SpecialisedAgent sendNewAgent () throws CloneNotSupportedException
 
void mutateAgent ()
 Mutate any inherited parameters for this particular agent. More...
 
void mutatePop ()
 Mutate any inherited parameters for a population of agents. More...
 
void registerBirth ()
 Registers a created agent into a respective container. Each agent must be referenced by one such container. More...
 
void die (boolean isStarving)
 Notifies the simulation that this agent has become too small and is then counted as dead. More...
 
double move ()
 Used in the calculation of delta move in Agent Container class. Will investigate further why this class returns 0. More...
 
void setSpeciesParam (SpeciesParam aSpeciesParam)
 Set the species parameters to a specified Species Parameter object. More...
 
SpeciesParam getSpeciesParam ()
 
Species getSpecies ()
 Returns the species object that is represented by this agent. More...
 
void setSpecies (Species aSpecies)
 Set the progenitor Specialised agent to a specified species. More...
 
String getName ()
 Return the name of the species represented by this agent. More...
 
boolean willDetach ()
 Returns a boolean noting whether this agent is detached and may be removed in sloughing. Implemented by extending classes. More...
 
int getGridIndex ()
 Returns the integer grid index where this agent resides. Implemented by extending classes. More...
 
double interact (boolean MUTUAL, boolean pull, boolean seq, double gain)
 Models a mechanical interaction between two located agents. Implemented by extending classes (LocatedAgent) More...
 
boolean isMoving ()
 Returns a boolean noting whether this agent is moving due to growth and sloughing. Implemented by extending classes. More...
 
void writePOVColorDefinition (FileWriter fr) throws IOException
 Used in POV-Ray output to display this species - writes a colour definition to the passed-in file. More...
 
- Public Member Functions inherited from simulator.agent.Agent
 Agent ()
 Initialise an agent object, setting its time of creation and thus the time it was last stepped. More...
 
void initFromProtocolFile (Simulator aSimulator, XMLParser aSpeciesRoot)
 Initialise the agent from the protocol file. Implemented by classes that extend this class. More...
 
void initFromResultFile (Simulator aSim, String[] singleAgentData)
 Create an agent using information in a previous state or initialisation file. More...
 
void mutateAgent ()
 Mutates agent parameters. Implemented by classes that extend this class. More...
 
void makeKid () throws CloneNotSupportedException
 Creates a new agent from an existing one, and registers this new agent in the simulation. More...
 
Object clone () throws CloneNotSupportedException
 Clones this agent object, creating a new progeny of this agent. More...
 
void step ()
 Perform the next timestep of the simulation for this agent. More...
 
String sendHeader ()
 Used in creation of results files - specifies the header of the columns of output information for this agent. More...
 
String writeOutput ()
 Used in creation of results files - creates an output string of information generated on this particular agent. More...
 
String sendName ()
 Returns a string containing the family name and genealogy of this agent. More...
 
void giveName ()
 Set the family for this agent, based on the next family. More...
 

Public Attributes

double detPriority = 0
 
double _timeSinceLastDivisionCheck = Double.MAX_VALUE
 
double _distProb = 0
 
double _distCumProb = 0
 
- Public Attributes inherited from simulator.agent.ActiveAgent
Reaction[] allReactions
 
double[][] soluteYield
 
double[][] reactionKinetic
 
double[][] particleYield
 
double[] particleMass
 
- Public Attributes inherited from simulator.agent.SpecialisedAgent
int speciesIndex
 
boolean isDead = false
 
String death
 

Protected Member Functions

void internalStep ()
 Called at each time step of the simulation to compute cell growth, update size, and monitor cell death and division. More...
 
- Protected Member Functions inherited from simulator.agent.ActiveAgent
void grow ()
 

Protected Attributes

double _radius
 
double _totalRadius
 
double _myDivRadius
 
double _myDeathRadius
 
double _volume
 
double _totalVolume
 
ContinuousVector _location = new ContinuousVector()
 
ContinuousVector _movement = new ContinuousVector()
 
ContinuousVector _divisionDirection = new ContinuousVector()
 
LinkedList< LocatedAgent_myNeighbors = new LinkedList<LocatedAgent>()
 
int _agentGridIndex
 
boolean _isAttached = false
 
- Protected Attributes inherited from simulator.agent.ActiveAgent
ArrayList< Integer > reactionActive
 
ArrayList< Integer > reactionKnown
 
double _netGrowthRate = 0
 
double _netVolumeRate = 0
 
double[] growthRate
 
double _totalMass
 
- Protected Attributes inherited from simulator.agent.SpecialisedAgent
Species _species
 
SpeciesParam _speciesParam
 
AgentContainer _agentGrid
 
- Protected Attributes inherited from simulator.agent.Agent
int _lastStep
 
int _generation = 0
 
long _genealogy = 0
 
int _family = 0
 
double _birthday
 

Static Protected Attributes

static ContinuousVector _diff = new ContinuousVector()
 
static ContinuousVector _newLoc = new ContinuousVector()
 

Detailed Description

Extends ActiveAgent by adding functionality to control agent grid location, agent shoving, agent death and division, and agent movement.

Extends ActiveAgent by adding functionality to control agent grid location, agent shoving, agent death and division, and agent movement. During each global timestep, agent divisions and agent growth lead to many cases where neighbouring agents will overlap. A relaxation algorithm is used to find iteratively the new overlap-minimising steady state configuration of agent locations at the end of each timestep.

Author
Andreas Dötsch (andre.nosp@m.as.d.nosp@m.oetsc.nosp@m.h@he.nosp@m.lmhol.nosp@m.tz-h.nosp@m.zi.de), Helmholtz Centre for Infection Research (Germany)
Laurent Lardon (lardo.nosp@m.nl@s.nosp@m.upagr.nosp@m.o.in.nosp@m.ra.fr), INRA, France
Sónia Martins (SCM80.nosp@m.8@bh.nosp@m.am.ac.nosp@m..uk), Centre for Systems Biology, University of Birmingham (UK)
Rob Clegg (rjc09.nosp@m.6@bh.nosp@m.am.ac.nosp@m..uk), Centre for Systems Biology, University of Birmingham (UK)

Constructor & Destructor Documentation

simulator.agent.LocatedAgent.LocatedAgent ( )

Constructor used to generate progenitor and initialise an object to store relevant parameters.

Constructor used to generate progenitor and initialise an object to store relevant parameters

Member Function Documentation

void simulator.agent.LocatedAgent.addMovement ( ContinuousVector  aMove)

Add movement to the ContinuousVector storing the agents move.

Add movement to the ContinuousVector storing the agents move

Parameters
aMoveContinuousVector to add to the movement vector
boolean simulator.agent.LocatedAgent.addPushMovement ( LocatedAgent  aNeighbour,
boolean  isMutual,
double  gain 
)

Mutual shoving : The movement by shoving of an agent is calculated based on the cell overlap and added to the agents movement vector.

Mutual shoving : The movement by shoving of an agent is calculated based on the cell overlap and added to the agents movement vector. Both agents are moved of half the overlapping distance in opposite directions.

Parameters
aNeighbourReference to the potentially shoving neighbour
isMutualWhether movement is shared between two agents or applied only to this one
gainDouble noting change in position
Returns
Boolean stating whether shoving is detected (true) or not (false)
boolean simulator.agent.LocatedAgent.addSpringMovement ( LocatedAgent  aNeighbor,
boolean  isMutual,
double  gain 
)

Pulling : The movement of agents by a shrinking biofilm. Move calculated and added to the agents movement vector.

The movement of agents by a shrinking biofilm. Move calculated and added to the agents movement vector.

Parameters
aNeighborReference to the potentially shoving neighbour
isMutualWhether movement is shared between two agents or applied only to this one
gainDouble noting change in position
Returns
Boolean stating whether pulling is detected (true) or not (false)
void simulator.agent.LocatedAgent.checkBoundaries ( )

Used by the move method to determine if an agents move crosses any of the domain's boundaries.

Used by the move method to determine if an agents move crosses any of the domain's boundaries

Object simulator.agent.LocatedAgent.clone ( ) throws CloneNotSupportedException

Creates a daughter Located Agent by cloning this agent and parameter objects.

Creates a daughter Located Agent by cloning this agent and parameter objects

Exceptions
CloneNotSupportedExceptionThrown if the agent cannot be cloned
double simulator.agent.LocatedAgent.computeDifferenceVector ( ContinuousVector  me,
ContinuousVector  him 
)

Computes the shortest distance between this agent and another, stored as ContinuousVectors. This may be around the cyclic boundary.

Computes the distance between this agent and another, stored as ContinuousVectors. This may be around the cyclic boundary

Parameters
meContinuousVector stating first agent location
himContinuousVector stating other agent location
Returns
the shortest movement vector to go from a to b, take into account the cyclic boundary
See Also
addOverlapMovement
addPullMovement works in 2 and 3D
void simulator.agent.LocatedAgent.createNewAgent ( ContinuousVector  position)

Create a new agent in a specified position.

Create a new agent in a specified position

Parameters
positionVector stating where this agent should be located
void simulator.agent.LocatedAgent.die ( boolean  isStarving)

Kills an agent. Called by detachment and starving test.

Kills an agent. Called by detachment and starving test

void simulator.agent.LocatedAgent.divide ( )

Captures cell division by making a clone of this agent using the makeKid method.

Captures cell division by making a clone of this agent using the makeKid method

void simulator.agent.LocatedAgent.divideCompounds ( LocatedAgent  baby,
double  babyMassFrac 
)

On agent division, divides the mass between the old and new agent, at a specified fraction.

On agent division, divides the mass between the old and new agent, at a specified fraction

Parameters
babyThe new agent, which is inheriting mass
babyMassFracThe fraction of this agents mass that should be transferred to the new agent
void simulator.agent.LocatedAgent.findCloseSiblings ( int  indexSpecies)

Find a sibling of this agent.

Find a sibling of this agent

Parameters
indexSpeciesThe index used to reference this species in the simulation dictionary
void simulator.agent.LocatedAgent.fitMassOnGrid ( SpatialGrid  aSpG,
int  catalystIndex 
)

Add the reacting concentration of an agent to the received grid.

Add the reacting concentration of an agent to the received grid

Parameters
aSpGSpatial grid used to sum catalysing mass
catalystIndexIndex of the compartment of the cell supporting the reaction
void simulator.agent.LocatedAgent.fitMassOnGrid ( SpatialGrid  aSpG)

Add the total concentration of an agent on received grid.

Add the total concentration of an agent on received grid

Parameters
aSpGSpatial grid used to sum total mass
void simulator.agent.LocatedAgent.fitReacRateOnGrid ( SpatialGrid  aRateGrid,
int  reactionIndex 
)

Add the reaction/growth rate of an agent on received grid, for a specified reaction.

Add the total reaction/growth rate of an agent on received grid, for a specified reaction

Parameters
aRateGridSpatial grid used to store total reaction rate
reactionIndexIndex of this declared reaction in the simulation dictionary
void simulator.agent.LocatedAgent.fitVolRateOnGrid ( SpatialGrid  aSpG)

Add the total volume rate of an agent on received grid.

Add the total volume rate of an agent on received grid

Parameters
aSpGSpatial grid used to sum volume
double simulator.agent.LocatedAgent.getActiveFrac ( )

Return the active fraction of this agent.

Return the active fraction of this agent

Returns
Double value stating the active fraction of this agent
double simulator.agent.LocatedAgent.getBabyMassFrac ( )

Return the fraction of mass that is transferred to the new agent on cell division.

Return the fraction of mass that is transferred to the new agent on cell division

Returns
Double stating the fraction of mass that is transferred to the new agent on cell division
Color simulator.agent.LocatedAgent.getColor ( )

Return the colour assigned to this agent in POV-Ray output.

Return the colour assigned to this agent in POV-Ray output

Returns
Colour assigned to this agent as specified in the protocol file
Color simulator.agent.LocatedAgent.getColorCapsule ( )

Return the colour assigned to any capsules contained in this agent in POV-Ray output.

Return the colour assigned to any capsules contained in this agent in POV-Ray output

Returns
Colour assigned to this agent capsules as specified in the protocol file
double simulator.agent.LocatedAgent.getDeathRadius ( )

Return the agent radius at which cell death is triggered.

Return the agent radius at which cell death is triggered

Returns
Double stating the agent radius at which cell death is triggered
double simulator.agent.LocatedAgent.getDistance ( LocatedAgent  aLoc)

Return the distance between two agents.

Return the distance between two agents

Parameters
aLocLocatedAgent to find distance to
Returns
distance between two agents (assuming cyclic boundaries)
double simulator.agent.LocatedAgent.getDivRadius ( )

Return the agent radius at which cell division is triggered.

Return the agent radius at which cell division is triggered

Returns
Double stating the agent radius at which cell division is triggered
Domain simulator.agent.LocatedAgent.getDomain ( )

Return the domain where this agent is contained.

Return the domain where this agent is contained

Returns
The domain where this agent is contained (Domain object)
LocatedGroup simulator.agent.LocatedAgent.getGridElement ( )

Return the LocatedGroup of agents that are present in the location where this agent is placed.

Return the LocatedGroup of agents that are present in the location where this agent is placed

Returns
LocatedGroup containing all agents present in the same grid space as this agent
int simulator.agent.LocatedAgent.getGridIndex ( )

Return the index of the grid on which this agent is placed.

Return the index of the grid on which this agent is placed

Returns
Integer grid index of where this agent is placed
double simulator.agent.LocatedAgent.getInteractDistance ( )

Return the shoving interaction distance to be used in shoving for this species of agent.

Return the shoving interaction distance to be used in shoving for this species of agent

Returns
Double specifying the shoving interaction distance that will be applied
double simulator.agent.LocatedAgent.getInteractDistance ( LocatedAgent  baby)

Return the shoving interaction distance to be used in shoving against a specified agent.

Return the shoving interaction distance to be used in shoving against a specified agent

Returns
Double specifying the shoving interaction distance that will be applied
ContinuousVector simulator.agent.LocatedAgent.getLocation ( )

Return the location of this agent.

Return the location of this agent

Returns
ContinuousVector stating the location of this agent
double simulator.agent.LocatedAgent.getMass ( boolean  withCapsule)

Return the mass of this agent, with or without the capsule.

Return the mass of this agent, with or without the capsule

Parameters
withCapsuleBoolean noting whether any capsule should be included in this calculation
Returns
Double specifying the mass of this agent
double simulator.agent.LocatedAgent.getMaximumRadius ( )
ContinuousVector simulator.agent.LocatedAgent.getMovement ( )

Return the continuous vector that states this agents move.

Return the continuous vector that states this agents move

Returns
continuous vector that states this agents move
void simulator.agent.LocatedAgent.getPotentialShovers ( double  radius)

Find neighbouring agents in a range around you.

Find neighbouring agents in a range around you

Parameters
radiusThe distance to search around the agent location
double simulator.agent.LocatedAgent.getRadius ( boolean  withCapsule)

Return the radius of this agent, with or without the capsule.

Return the radius of this agent, with or without the capsule

Parameters
withCapsuleBoolean noting whether any capsule should be included in this calculation
Returns
Double specifying the radius of this agent
double simulator.agent.LocatedAgent.getShoveFactor ( )

Return the shove factor to be used in shoving for this species of agent.

Return the shove factor to be used in shoving for this species of agent

Returns
Double specifying the shove factor that will be applied
double simulator.agent.LocatedAgent.getShoveRadius ( )

Return the shove radius to be used in shoving for this species of agent.

Return the shove radius to be used in shoving for this species of agent

Returns
Double specifying the shove radius that will be applied
LocatedParam simulator.agent.LocatedAgent.getSpeciesParam ( )

Return the set of parameters associated with this agent (LocatedParam object)

Return the set of parameters associated with this agent (LocatedParam object)

Returns
LocatedParam object of parameters associated with this agent

Implements simulator.agent.HasSpecies.

double simulator.agent.LocatedAgent.getVolume ( boolean  withCapsule)

Return the volume of this agent, with or without the capsule.

Return the volume of this agent, with or without the capsule

Parameters
withCapsuleBoolean noting whether any capsule should be included in this calculation
Returns
Double specifying the volume of this agent
boolean simulator.agent.LocatedAgent.hasEPS ( )

Determine whether this cell has any EPS.

Determine whether this cell has any EPS

Returns
Boolean noting whether this cell has any EPS
boolean simulator.agent.LocatedAgent.hasInert ( )

Determine whether this agent contains any inert particles.

Determine whether this agent contains any inert particles

Returns
Boolean noting whether this agent contains any inert particles
void simulator.agent.LocatedAgent.initFromProtocolFile ( Simulator  aSim,
XMLParser  xmlMarkUp 
)

Creates an agent of the specified species and notes the grid in which this is assigned.

Creates an agent of the specified species and notes the grid in which this is assigned

Parameters
aSimThe simulation object used to simulate the conditions specified in the protocol file
xmlMarkUpA species mark-up within the specified protocol file
void simulator.agent.LocatedAgent.initFromResultFile ( Simulator  aSim,
String[]  singleAgentData 
)

Create an agent using information in a previous state or initialisation file.

Create an agent using information in a previous state or initialisation file

Parameters
aSimThe simulation object used to simulate the conditions specified in the protocol file
singleAgentDataData from the result or initialisation file that is used to recreate this agent
double simulator.agent.LocatedAgent.interact ( boolean  MUTUAL,
boolean  shoveOnly,
boolean  seq,
double  gain 
)

Models a mechanical interaction between two located agents. Implemented by extending classes (LocatedAgent)

Models a mechanical interaction between two located agents. Implemented by extending classes (LocatedAgent)

Parameters
MUTUALWhether movement is shared between two agents or applied only to this one
shoveOnlyBoolean noting whether this action is shoving (false) or pulling (shrinking biofilm) (true)
seqWhether the move should be applied immediately or wait until the end of the step
gainDouble noting change in position
Returns
The move to be applied once the shoving or pull calculations have been performed
void simulator.agent.LocatedAgent.internalStep ( )
protectedvirtual

Called at each time step of the simulation to compute cell growth, update size, and monitor cell death and division.

Called at each time step of the simulation to compute cell growth, update size, and monitor cell death. Also determines whether the agent has reached the size at which it must divide

Reimplemented from simulator.agent.ActiveAgent.

Reimplemented in simulator.agent.zoo.Bacterium, simulator.agent.zoo.ParticulateEPS, simulator.agent.zoo.BactAdaptable, and simulator.agent.zoo.BactEPS.

boolean simulator.agent.LocatedAgent.isAttached ( )

Determine if an agent is attached to a surface.

Determine if an agent is attached to a surface

Returns
Boolean noting whether the agent is attached to a surface
boolean simulator.agent.LocatedAgent.isMoving ( )

Determine if an agent has a move to perform.

Determine if an agent has a move to perform

Returns
Boolean noting whether the agent has a move to perform
void simulator.agent.LocatedAgent.makeKid ( ) throws CloneNotSupportedException

With it determined that cell division will occur, create a new agent from the existing one.

With it determined that cell division will occur, create a new agent from the existing one

Exceptions
CloneNotSupportedExceptionThrown if the agent cannot be cloned
double simulator.agent.LocatedAgent.move ( )

With the agent move calculated, apply this movement, taking care to respect boundary conditions.

With the agent move calculated, apply this movement, taking care to respect boundary conditions

void simulator.agent.LocatedAgent.mutateAgent ( )

Mutate inherited agent parameters after agent division.

Mutation Function. If you don't want apply a mutation in a specified class, do not redefine this method. If you want, you are free to choose which fields to mutate for each different class by a simple redefinition

void simulator.agent.LocatedAgent.mutatePop ( )

Mutate any inherited parameters for a population of agents.

Mutate any inherited parameters for a population of agents. KA June 2013 - not sure this action is implemented

Implements simulator.agent.HasSpecies.

LocatedAgent simulator.agent.LocatedAgent.pickNeighbor ( )

Pick a random neighbour from the _myNeigbors collection.

Pick a random neighbour from the _myNeigbors collection

Returns
A randomly picked neighbour (LocatedAgent object) from the list of neighbours
void simulator.agent.LocatedAgent.registerBirth ( )
virtual

Registers a created agent into a respective container. Each agent must be referenced by one such container.

Registers a created agent into a respective container. Each agent must be referenced by one such container. In this case, the species is registered into the agent grid

Reimplemented from simulator.agent.ActiveAgent.

String simulator.agent.LocatedAgent.sendHeader ( )

Used in creation of results files - specifies the header of the columns of output information for this agent.

Used in creation of results files - specifies the header of the columns of output information for this agent

Returns
String specifying the header of each column of results associated with this agent

Implements simulator.agent.HasSpecies.

void simulator.agent.LocatedAgent.setDivisionDirection ( double  distance)

Set the movement vector that states where to put a newly-created particle.

Set the movement vector that states where to put a newly-created particle

Parameters
distanceDistance between the this agent and the new agent
void simulator.agent.LocatedAgent.setGridIndex ( int  aGridIndex)

Move this agent to another grid index.

Move this agent to another grid index

Parameters
aGridIndexGrid index in which this agent should now be placed
void simulator.agent.LocatedAgent.setLocation ( ContinuousVector  cc)

Set the location of this agent to the supplied continuous vector.

Set the location of this agent to the supplied continuous vector

Parameters
ccLocation which this agent should be assigned to
void simulator.agent.LocatedAgent.transferCompounds ( LocatedAgent  baby,
double  splitRatio 
)

On agent division, transfers EPS between the old and new agent, at a specified ratio.

On agent division, transfers EPS between the old and new agent, at a specified ratio

Parameters
babyThe new agent, which is inheriting mass
splitRatioThe ratio of the EPS that should be transferred to the new agent
AllBC simulator.agent.LocatedAgent.updateAttachment ( )

Update the attachment, determining if an agent location crosses any boundaries.

Update the attachment, determining if an agent location crosses any boundaries

Returns
Boundary that has been crossed
void simulator.agent.LocatedAgent.updateRadius ( )

Compute the radius on the basis of the volume The radius evolution is stored in deltaRadius (used for shrinking)

void simulator.agent.LocatedAgent.updateSize ( )

Update the radius of the agent from the current mass (and then the volume) of the agent (EPS included)

void simulator.agent.LocatedAgent.updateVolume ( )

Compute the volume on the basis of the mass and density of different compounds defined in the cell.

Compute the volume on the basis of the mass and density of different compounds defined in the cell

boolean simulator.agent.LocatedAgent.willDie ( )

Determines whether or not a cell has reached the radius where cell death can be triggered.

Determines whether or not a cell has reached the radius where cell death can be triggered

Returns
Boolean stating whether cell death should be triggered (true) or not (false)
boolean simulator.agent.LocatedAgent.willDivide ( )

Determines whether or not a cell has reached the radius where cell division can be triggered.

Determines whether or not a cell has reached the radius where cell division can be triggered

Returns
Boolean stating whether cell division should be triggered (true) or not (false)
String simulator.agent.LocatedAgent.writeOutput ( )

Used in creation of results files - creates an output string of information generated on this particular agent.

Used in creation of results files - creates an output string of information generated on this particular agent

Returns
String containing results associated with this agent

Member Data Documentation

int simulator.agent.LocatedAgent._agentGridIndex
protected

Index of the agent position on the vectorized grid

ContinuousVector simulator.agent.LocatedAgent._diff = new ContinuousVector()
staticprotected

Temporary variable storing the distance between two agents

double simulator.agent.LocatedAgent._distCumProb = 0

Cumulative probability as to whether the plasmid will be transferred

double simulator.agent.LocatedAgent._distProb = 0

Distance based probability from a given neighbour (used in HGT). Sonia 8-12-2010

ContinuousVector simulator.agent.LocatedAgent._divisionDirection = new ContinuousVector()
protected

Direction in which this cell divides

boolean simulator.agent.LocatedAgent._isAttached = false
protected

Boolean noting whether this agent is interacting with a surface (true) or not (false)

ContinuousVector simulator.agent.LocatedAgent._location = new ContinuousVector()
protected

Agent position - continuous coordinates

ContinuousVector simulator.agent.LocatedAgent._movement = new ContinuousVector()
protected

ContinuousVector noting the move that will be applied to the agents position

double simulator.agent.LocatedAgent._myDeathRadius
protected

Radius at which agent death is triggered

double simulator.agent.LocatedAgent._myDivRadius
protected

Radius at which this agent will divide

LinkedList<LocatedAgent> simulator.agent.LocatedAgent._myNeighbors = new LinkedList<LocatedAgent>()
protected

List of neighbouring agents in this agents vicinity

ContinuousVector simulator.agent.LocatedAgent._newLoc = new ContinuousVector()
staticprotected

Temporary store of the new location this cell will move to

double simulator.agent.LocatedAgent._radius
protected

Radius of this agent

double simulator.agent.LocatedAgent._timeSinceLastDivisionCheck = Double.MAX_VALUE

Stores the simulation time since the last division check

double simulator.agent.LocatedAgent._totalRadius
protected

Cell radius including any capsules

double simulator.agent.LocatedAgent._totalVolume
protected

Cell volume including any capsules

double simulator.agent.LocatedAgent._volume
protected

Volume of this agent

double simulator.agent.LocatedAgent.detPriority = 0

Detachment priority


The documentation for this class was generated from the following file: