Syntax
y = Ensure(u = condition, tl = time_period);
Description
Each instance of this block creates a requirement that evaluates whether the condition u is true all along the time period tl (which can be a continuous or discrete time period). The condition is a Boolean4 that takes its values in the { true, false, undecided, undefined } set. The value of y is always undecided within the time period tl, and is true or false at the end of tl.
The difference with the CheckAnyTime block is the following: Ensure is evaluated all along time period tl and the sole decision event is the end of tl. Therefore, the value of y can never be true inside tl, but only at the end of tl.
To create continuous time locators, refer to the ContinuousTimeLocator block. To create discrete time locators, refer to the DiscreteTimeLocator block.
The value of a requirement is a Boolean4 that can be used as input of another Ensure block. It is therefore possible to express requirements on requirements.
Requirements can be combined using Boolean4 operators, refer to the Logical4 package.
The condition u can be generated by converting Boolean signals to Boolean4 signals with the block BooleanToBoolean4, or by using the output y of another requirement block.
Example
This block is demonstrated with the following example: