Data Elements

Data elements are intended to represent the constant inputs in your model.

A Data element An input element intended to represent constant inputs in a model. can represent both values and conditions (i.e., True/False), and can represent a single scalar An output consisting of a single value or condition. datum, or an array A collection of variables that share common output attributes and can be manipulated in GoldSim elements or input expressions. of data.

The properties dialog for a Data element looks like this:

As can be seen, the dialog is very simple. Other than the Element ID, Description and Display Units, the Data element property dialog has only a single input field (labeled Data Definition). Because Data elements are meant to represent constants in your model, typically you will enter a number into this field.

Note: Although you can enter expressions (with links) into the Data Definition field for a Data element, it is strongly recommended that you only enter numbers in this field (and use an Expression element when you need to define equations with links to other elements). Doing so helps to make your models more transparent, since the Data symbol will visually indicate to anyone viewing the model that the element represents a constant. There is one exception to this rule (defining arrays) that will be discussed below. If you have entered an expression into a Data element, you can easily convert the element to an Expression by right-clicking on it, and selecting Transform to Expression.

Data elements have a single output, which can be a value or a condition, and can be specified as a scalar, a vector A one-dimensional array. or a matrix A two-dimensional array.. You can specify these attributes by pressing the Type... button. By default, a new Data element is a scalar, dimensionless value.

If you specify that the output of the Data element is a vector or a matrix, the dialog will be slightly modified (in order to allow you to define the members of the array). Instead of displaying an input field, it displays a button for defining the array:

Note: Using a Data element to define a vector or a matrix is the one situation where it can be appropriate to define links to other elements.

Data elements also have a Data Source A source of data external to your GoldSim model that can be automatically imported into GoldSim elements. External data sources are either spreadsheets, text files, databases or DLLs. field that allows you to download data directly from an ODBC-compliant database.

If you are using GoldSim’s advanced scenario A specific set of input data (and corresponding outputs) for a model. Multiple scenarios can be defined for a model. Different scenarios within a model are specifically differentiated by having different values for one or more Data elements. feature, and have defined at least one scenario, Data elements include an additional field that allow you to define the element as Scenario Data:

You can save the results for a Data element by clicking Final Values and/or Time Histories.

As shown below, the browser An alternative view of a GoldSim model, in which elements are displayed in a tree, and organized either hierarchically, or by type. view of a Data element shows a single input (referred to as the Definition), and a single output:

Note: Element inputs and outputs are only shown in the browser if you choose to Show Element Subitems (accessed via the browser context menu by right-clicking in the browser).