|
Run-time variables are created at run-time during pre-processing, processing or post-processing, through the run-time evaluation of expressions (like functions). Such variables can be used to handle dynamic cases that can not be predicted at parse time. Run-time variables begin with a dollar sign `$`. Their value can be set or retrieved in any expression, e.g. when a function is called in a `Formulation` term, or in the `Evaluate`, `While`, `Test`, etc., operations in a `Resolution`. They can be set in expressions either with a simple affectation (`=`) or with the `SetVariable` function; their value can be retrieved either directly or using the `GetVariable` function. Both `SetVariable` and `GetVariable` allow to construct dynamic variable names, by appending suffixes dynamically depending on their extra arguments. Contrary to parser variables, which can only store real numbers, run-time variables can hold any fundamental GetDP value type: real, complex or multi-harmonic scalars (1 component), vectors (3 components) and tensors (3, 6 or 9 components).
|
|
Run-time variables are created at run-time during pre-processing, processing or post-processing, through the run-time evaluation of expressions (e.g. in functions). Such variables can be used to handle dynamic cases that can not be predicted at parse time. Run-time variables begin with a dollar sign `$`. Their value can be set or retrieved in any expression, e.g. when a function is called in a `Formulation` term, or in the `Evaluate`, `While`, `Test`, etc., operations in a `Resolution`. They can be set in expressions either with a simple affectation (`=`) or with the `SetVariable` function; their value can be retrieved either directly or using the `GetVariable` function. Both `SetVariable` and `GetVariable` allow to construct dynamic variable names, by appending suffixes dynamically depending on their extra arguments. Contrary to parser variables, which can only store real numbers, run-time variables can hold any fundamental GetDP value type: real, complex or multi-harmonic scalars (1 component), vectors (3 components) and tensors (3, 6 or 9 components).
|