Skip to content

Commit 5ff099a

Browse files
committed
document state priority
1 parent fa04946 commit 5ff099a

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

docs/src/basics/Variable_metadata.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,15 @@ it can be accessed in [callbacks](@ref events)
186186
isirreducible(important_value)
187187
```
188188

189+
## State Priority
190+
191+
When a model is structurally simplified, the algorithm will try to ensure that the variables with higher state priority become states of the system. A variable's state priority is a number set using the `state_priority` metadata.
192+
193+
```@example metadata
194+
@variable important_dof [state_priority = 10] unimportant_dof [state_priority = 2]
195+
state_priority(important_dof)
196+
```
197+
189198
## Units
190199

191200
Units for variables can be designated using symbolic metadata. For more information, please see the [model validation and units](@ref units) section of the docs. Note that `getunit` is equivalent to `get_unit`.

0 commit comments

Comments
 (0)