Controllers

A controller represents a regulatory mechanism in the physiological model. Each controller alters the value of one variable (the target variable), depending on the value of another (the controlling variable).

All variables have an initial value, which is the mean value of this variable in a normally functioning, physiological human. Mathematically, the error from normal of the controlling variable is calculated, and a gain value is used to calculate the desired value of the target variable, as a deviation from its normal value. The target variable's value is then gradually moved towards this desired value, at the given rate. The rate is measured as a fraction of the desired change per minute; i.e. 1.0 gives instantaneous correction, and 0.5 will decay towards the desired value with a half-life of 1 minute.

There are several types of curve that can be used to calculate desired values from errors - these correspond to different gain functions:

  1. Error gain: the desired value is a linear function of the error: desired = target_normal + (controlling_current - controlling_normal) * gain + constant . If 'limited' is selected, the desired value is confined to the normal range.
  2. Error power: the desired value is a polynomial function of the error: desired = target_normal + constant * (error ^ gain)
  3. Proportional: desired = target_normal * (controlling_value / controlling_normal)^gain + constant

Back