This is an old revision of the document!
Parametric Modeling and Simulations with Modelica
Keywords
Constraints have certain reserved keywords. They are
diff - ? e.g. diff(x)
der - Derivative, e.g. der(x)
minimum - minimum(1,2,3,4) = 1
maximum - maximum(1,2,3,4) = 4
sum - sum(1,2) = 3
Common Built-in Variables can be modified in the 'Edit Constraint Block'. Click the 'Edit Built-in Variable' button. If you have more than one then separate them with a ','. Recommend to add:
time
Organizing Parametric Modeling
Create a package labelled 'model of x'
Create a block diagram for this package
Inside BDD insert <block> labelled 'modeling x'
Add relevant Constraint Blocks. Add aggregation relationships between constraint blocks (source) to the Modeling X block (target).
Add equations to your Constrain Blocks. If you will use an equation more than once add another aggregation relationship between the Constrain Block and the Modeling X block. In such case be sure to assign a name to the source of each relationship to avoid confusion later
You can't just have equations, you need inputs and outputs. Add to the BDD relevant Blocks that holds these inputs and outputs. Add a reference link between these blocks and the Modeling X block