While stock and flow diagrams may contain only stocks and flows, it is a good practice to define intermediate concepts with dynamic variables.
Commonly dynamic variables consist of functions of stocks (and constants or exogeneous inputs). In case you need to define a constant, use a parameter.To create a dynamic variable
Click this indicator to show the popup menu with items offering you to create missing links from the mentioned elements to this dynamic variable. Choosing an item from the list you create the corresponding missing link.
You can subsequently create all missing links in such an easy way:
Name – The name of the dynamic variable. The name is used to identify and access the dynamic variable in formulas.
Show name – If selected, the name of the dynamic variable is displayed on the presentation diagram.
Ignore – If selected, the dynamic variable is excluded from the model.
Visible on upper agent – If selected, the variable is also visible on the upper agent where this agent lives.
Show at runtime
– If selected, the
is visible on the presentation at runtime.
Color – The fill color of the variable icon.
Array – If selected, the variable is of array type. Properties for array variables look slightly different. Instead of one variable_name = field defining the formula for the dynamic variable, there can be several fields defining formulas for some particular elements or sub-arrays of the array variable. To add new section allowing to define one more formula, click the Add formula button. Defining formulas for array elements and sub-arrays is described here.
Dependent – If selected, the dynamic variable will get value of the connected variable constantly.
Constant – If selected, the dynamic variable is a constant, i.e. its value does not change according constantly reevaluated formula but is equal to the specified value (that can be changed by user during the simulation).
variable_name = – The formula defining the value of thedynamic variable. In the case this variable is an array,there can be several fields defining formulas for some particular elements or sub-arrays of the array variable. To add new section allowing to define one more formula, click the Add formula button. Defining formulas for array elements and sub-arrays is described here.
Available dimensions – The list of dimensions defined in this model.
Selected dimensions – The list of dimensions that will act as dimensions of this array variable.
These properties are used to define dimensions that make up the array variable.
Please refer to the Defining an array variable section for details.
System dynamics units – If selected, you will be able to specify units of measurements for this variable in the edit box to the right. Having specified units for all elements of your stock-and-flow diagram, you may perform unit checking to find out dimension inconsistencies in your model.
At model runtime you can view value and chart of the dynamic variable as well as copy the collected history of values to Clipboard, you can find more information here.
System Dynamics tutorial
System Dynamics modeling
Viewing variables at runtime
Modifying variables at runtime