MinDuration model
Requirements.Examples.Elementary.ChecksInFixedWindow.MinDuration
ยท source
Example for MinDuration (in every true condition phase, check must be true for at least the defined duration)
Extends Modelica.Icons.Example
Using check block MinDuration as
results in
![]() | |
| simulation result |
The condition phases of the Boolean table condition are [1, 3), [5, 7), [9, 9.5) and [11, 13) s. The
signal check is true on [0.5, 2.5), [5.2, 5.4), [5.6, 5.8), [6, 8), [9.1, 10.5) and [11.5, 12) s, so the
true phases of check inside the condition phases have different lengths, some shorter and some longer than the
required durationMin = 1 s. The property output minDuration.y shows the verdict in every
condition phase; outside the condition phases it is Undefined.
Components and variables
| Name | Type | Description |
|---|---|---|
condition | Modelica.Blocks.Sources.BooleanTable | Condition phases [1,3), [5,7), [9,9.5) and [11,13) s |
check | Modelica.Blocks.Sources.BooleanTable | Signal whose true phases are checked against the minimum duration |
minDuration | Requirements.ChecksInFixedWindow.MinDuration | In every condition phase, check must be true for at least 1 s |

