crowdmodel.agents
Class Physiology

java.lang.Object
  extended by crowdmodel.agents.Physiology

public class Physiology
extends java.lang.Object

Physiology is one of the architecture main types. Architecture consists out of a sensor, motor, memory and physiology part. All there is to describe behaviour, influences factors, processes, characteristics etc. need to be described in either one of the (derived) main parts of the architecture Physiology: describes the bio-state of an individual. It represents the bodily state, characteristics of a human being. Here those elements are described that are important to represent all non-mental aspects apart from sensing (e.g. arousal, energy, etc). Physiology is affected by the external world as well as the mental state of an individual. On its turn it affects the internal state of an individual. In the current version physiology includes 3 factors:
- arousal : indicates the level of awareness/alertness (indicated by increased hartbeat + bloodpressure) *check this description + add refs* - bladder : related to subsistence, based on our festival context: physiological link to go to the toilet - stomach : related to subsistence, based on our festival context: physiological link to go to the bar

Author:
Nanda Wijermans

Field Summary
private  double d_arousal
           
private  double d_bladder
           
private  java.lang.String d_domPhysioString
           
private  double d_domPhysioValue
           
private  double d_energy
           
private  double d_stomach
           
private  CrowdAgent d_thisAgent
           
private  boolean d_thisAgentFlag
           
 
Constructor Summary
Physiology()
          Constructor sets the initial values of arousal, bladder and stomach
 
Method Summary
 double getArousal()
          Returns the arousal level of an individual
 double getBladderLevel()
          The level of the bladder. [0,1] Full bladder (1) leads to urge to go to the toilet via increase in subsistence dominance
 double getDomPhysioLevel()
          Returns the dominant influence value given (subsistence-related) physiology This is used to set the satisfaction level of the subsistence goal.
 java.lang.String getDomPhysiology()
          Returns the dominant influence given (subsistence-related) physiology
 double getEnergy()
          Returns the energy level of an individual Note: is not used right now!
 double getStomachLevel()
          The level of the stomach. [0,1] Empty stomach (0) leads to urge to eat/drink something at the bar via subsistence dominance
protected  void setArousal(double arousal)
          Sets the arousal level of an individual
protected  void setBladderLevel(double bladderLevel)
          Sets the bladderLevel
protected  void setDomPhysiology()
          Sets the dominant influence given (subsistence-related) physiology Here the bladder (urge to go to the toilet) and stomach (urge to have eat or drink) are the competitors.
protected  void setEnergy(double energy)
          Sets the energy level of an individual Note: is not used right now!
protected  void setStomachLevel(double stomachLevel)
          Sets the stomachLevel
protected  void setThisAgent(CrowdAgent thisAgent)
          Sets the Agent to whom this physiology belongs This allows for the 'direct' access of methods/vars concerning physiology by the functions in Physiology; As Inheritance works only in one direction, this works around it by being able to access the agent it self The function checks whether this has already been assigned, at this is only done once while initialising.
 void updateArousal(double density)
          Describes the level of density purely based upon the locally perceived density.
protected  void updateBladder()
          Updates the bladder level in case nothing is affecting the bladder externally.
protected  void updateStomach()
          Updates the stomach level in case nothing is affecting the stomach externally.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

d_thisAgent

private CrowdAgent d_thisAgent

d_thisAgentFlag

private boolean d_thisAgentFlag

d_energy

private double d_energy

d_arousal

private double d_arousal

d_bladder

private double d_bladder

d_stomach

private double d_stomach

d_domPhysioString

private java.lang.String d_domPhysioString

d_domPhysioValue

private double d_domPhysioValue
Constructor Detail

Physiology

public Physiology()
Constructor sets the initial values of arousal, bladder and stomach

Method Detail

setThisAgent

protected void setThisAgent(CrowdAgent thisAgent)
Sets the Agent to whom this physiology belongs This allows for the 'direct' access of methods/vars concerning physiology by the functions in Physiology; As Inheritance works only in one direction, this works around it by being able to access the agent it self The function checks whether this has already been assigned, at this is only done once while initialising. As this cannot be done in the constructor this is the 'ugly' solution.

Parameters:
thisAgent -

getBladderLevel

public double getBladderLevel()
The level of the bladder. [0,1] Full bladder (1) leads to urge to go to the toilet via increase in subsistence dominance

Returns:
d_bladder

setBladderLevel

protected void setBladderLevel(double bladderLevel)
Sets the bladderLevel

Parameters:
bladder -

updateBladder

protected void updateBladder()
Updates the bladder level in case nothing is affecting the bladder externally. This means that the bladder content is increasing during time.


getStomachLevel

public double getStomachLevel()
The level of the stomach. [0,1] Empty stomach (0) leads to urge to eat/drink something at the bar via subsistence dominance

Returns:

setStomachLevel

protected void setStomachLevel(double stomachLevel)
Sets the stomachLevel


updateStomach

protected void updateStomach()
Updates the stomach level in case nothing is affecting the stomach externally. This means that the stomach content is decreasing during time following: C = constant = 0.0013 d_stomach -= C


getEnergy

public double getEnergy()
Returns the energy level of an individual Note: is not used right now!

Returns:

setEnergy

protected void setEnergy(double energy)
Sets the energy level of an individual Note: is not used right now!


getArousal

public double getArousal()
Returns the arousal level of an individual

Returns:
arousal level

setArousal

protected void setArousal(double arousal)
Sets the arousal level of an individual

Parameters:
arousal -

setDomPhysiology

protected void setDomPhysiology()
Sets the dominant influence given (subsistence-related) physiology Here the bladder (urge to go to the toilet) and stomach (urge to have eat or drink) are the competitors.


getDomPhysiology

public java.lang.String getDomPhysiology()
Returns the dominant influence given (subsistence-related) physiology

Returns:
dominant physio factor: bladder or stomach

getDomPhysioLevel

public double getDomPhysioLevel()
Returns the dominant influence value given (subsistence-related) physiology This is used to set the satisfaction level of the subsistence goal. returns the values of the stomach and bladder, normalised by returning a value corresponding to the satisfaction value (meaning that 1-stomach represent the stomach satisfaction)

Returns:
dominant value

updateArousal

public void updateArousal(double density)
Describes the level of density purely based upon the locally perceived density. It is a very simple, linear, threshold rule, limited by a minimum as the arousal level will not be low in the simulations we are dealing with. We do not think that this link is a realistic one as more factors are involved in affecting the arousal level. To avoid problems we discard the part of low density that we assume that doesn't occur during the simulation. The main thing is that it represents that high density levels (>6) and medium (>3) density levels have a relative and continuous effect, which is done in this simple rule. TODO refer to thesis and sharpen argumentation

Parameters:
density -