| SimEvents® | ![]() |
Timing
This block cancels a named timeout event that the Schedule Timeout block previously scheduled for the arriving entity. Timeout events enable you to limit the time that an entity spends on designated entity paths during the simulation. Topologically, this block designates an end of an entity path that is relevant to the time limit. The ability to cancel timeout events before they occur lets you apply the time limit to an entity path that does not end with a sink block.
The Timeout tag parameter of this block is the name of the timeout event and corresponds to the Timeout tag parameter of a Schedule Timeout block in the model. If the arriving entity is not associated with a timeout event of that name, then you can configure the block to produce an error or warning, or to ignore the absence of the timeout event.
Using the Residual time and Average residual time parameters, you can configure the block to report the following statistics via the rt and w signal output ports, respectively:
The residual time for the named timeout event associated with the arriving entity, which is the amount of time between the entity's arrival time at this block and the scheduled time of the named timeout event
The average among the rt values among all entities that have arrived at this block during the simulation and been associated with timeouts of the specified name
Entity Input Ports
| Label | Description |
|---|---|
| IN | Port for arriving entities. |
Entity Output Ports
| Label | Description |
|---|---|
| OUT | Port for entities whose timeout event the block has just canceled. |
Signal Output Ports
| Label | Description | Time of Update When Statistic is On | Order of Update |
|---|---|---|---|
| #d | Number of entities that have departed from this block since the start of the simulation. | After entity departure | 3 |
| #t | Number of entities that have departed from this block and been associated with a timeout of the specified name. | After entity departure | 2 |
| rt | Amount of time between arrival time at this block and the scheduled time of the named timeout event. | After entity departure | 2 |
| w | Average among the rt values among all entities that have arrived at this block and been associated with timeouts of the specified name. | After entity departure | 1 |
Output signals having the same number in the Order of Update column in the table above are updated in an arbitrary sequence relative to each other; you should not rely on a specific sequence for your simulation results.
The initial output value, which is in effect from the start of the simulation until the first update by the block, is 0 for all signals.

Name of the timeout event to cancel, corresponding to the Timeout tag parameter of a Schedule Timeout block in the model.
Behavior of the block if an arriving entity is not associated with a timeout event with the specified timeout tag.
These parameters determine whether certain ports produce data throughout the simulation, produce data only when you stop or pause the simulation, or are omitted from the block. For descriptions of the affected ports, see the "Signal Output Ports" table above.

Controls the presence and behavior of the signal output port labeled #d.
Controls the presence and behavior of the signal output port labeled #t.
Controls the presence of the signal output port labeled rt.
Controls the presence and behavior of the signal output port labeled w.
Forcing Departures Using Timeouts
![]() | Attribute Scope | Conn | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |