modelComplexInteraction
Extends from Icons.Interaction (Icon for interactional flow classes), Interfaces.Basics.GenericFlow (Flow Template with two FlowPorts), Interfaces.Basics.Interaction4SO (Output connectors for interaction elements reporting rates).
Information
This information is part of the Business Simulation Library (BSL). Please support this work and ► donate.
The ComplexInteraction component combines linear and nonlinear interaction between two stocks A (portA) and B (portB):
Note: Capital letters were chosen to represent the stocks (state variables) connected at portA and portB in the formula above. Also dot notation is used for a stock's rate of flow—its first derivative with respect to time.
| Coefficient | Unit | Description |
|---|---|---|
a_0 |
base unit of flow to A ( |
Rate of growth for stock A |
|
|
base unit of flow to B ( |
Rate of growth for stock B |
|
|
1/s |
fractional rate of growth for stock A |
|
|
1/s |
fractional rate of growth for stock B |
|
|
base unit of flow to A ( |
Rate of growth for stock A per stock B |
|
|
base unit of flow to B ( |
Rate of growth for stock B per stock A |
a_AB |
1 per second per base unit of B ( TypeB) |
Factor used to determine the net flow to A |
b_AB |
1 per second per base unit of A TypeA) |
Factor used to determine the net flow to B |
The coefficients can be given as parameters or as variables via the expandable connector dataIn.
Examples
The classical Lotka-Volterra-Model of predator-prey-dynamics can be derived from this model using the following parameterization:
a_0 = 0, a_A = α, a_B = 0, a_AB = -β, b_0 = 0, b_B = -γ, b_A = 0, b_AB = δ
Notes
- Within the components
LinearInteractionandNonlinearInteractionthe rates passed fora_B, a_AB, b_A, b_ABcall for divison by a reference level of the connected stocks. In many cases, modelers can leave the type selectorsTypeA, TypeBat their default value ofUnspecifiedso that no conversion will take place. - Should unit conversion be needed, modeleres may wish to select appropriate type values and corresponding
displayUnitsettings to enter convenient reference levelsrefA, refB.
See also
Parameters
| Type | Name | Default | Description |
|---|---|---|---|
| TypeA | refA | 1 | Reference value, i.e., divisor, for the couplings b_A, b_AB |
| TypeB | refB | 1 | Refrence value, i.e., divisor, for the couplings a_B, a_AB |
Connectors
| Type | Name | Default | Description |
|---|---|---|---|
| Connectors.FlowPort | portA (from GenericFlow) | Flow from/to Stock A | |
| Connectors.FlowPort | portB (from GenericFlow) | Flow to/from Stock B | |
| RealOutput_B | y_B (from Interaction4SO) | Rate for flow to and from B (positive value indicates inflow) | |
| RealOutput_B | y1_B (from Interaction4SO) | Rate for flow to and from B (positive value indicates inflow) | |
| RealOutput_A | y1_A (from Interaction4SO) | Rate for flow to and from A (positive value indicates inflow) | |
| RealOutput_A | y_A (from Interaction4SO) | Rate for flow to and from A (positive value indicates inflow) | |
| InputConnector | dataIn | Expandable connector for continuous input |
Contents
| Name | Description |
|---|---|
| TypeA | Type selector for stock A |
| TypeB | Type selector for stock B |
| Data bus for inputs |
Revisions
InputConnectordefined asencapsulated expandable connectorin v2.1.0.TypeA, TypeBand corresponding reference levelsrefA, refBintroduced to support unit checking and unit conversions in v2.2.