blockRemoveFromStagingOrder
Remove flagged units from staging order
Information
This block takes a staging order – a list of units ranked by increasing runtime – together with a flag for each unit, and produces a revised staging order in which the flagged units have been removed.
The position of each removed unit is filled with the next unflagged unit found further down the order. As a result, the enable logic that reads any position of the revised order is directed to a unit that is allowed to be enabled, while the ranking by runtime is preserved.
If all units ranked at or after a given position are flagged, that position falls back to the last unit in the order. The last position therefore always returns its own unit, whether or not it is flagged.
Parameters
| Type | Name | Default | Description |
|---|---|---|---|
| Integer | nUni | Number of units |
Connectors
| Type | Name | Default | Description |
|---|---|---|---|
| Buildings.Controls.OBC.CDL.Interfaces.IntegerInput[nUni] | uIdxSor | Indices of polyvalent units sorted by increasing runtime | |
| Buildings.Controls.OBC.CDL.Interfaces.BooleanInput[nUni] | u1 | Flag of each unit to be removed from the staging order, indexed by unit number | |
| Buildings.Controls.OBC.CDL.Interfaces.IntegerOutput[nUni] | yIdxSor | Staging order with each flagged unit replaced by the next non-flagged unit |
Components
| Type | Name | Default | Description |
|---|---|---|---|
| Buildings.Controls.OBC.CDL.Routing.BooleanVectorReplicator | repFla | Replicate unit flags for each position of the staging order | |
| Buildings.Controls.OBC.CDL.Routing.BooleanExtractor[nUni] | extFla | Extract flag of unit at each position of the staging order | |
| Buildings.Controls.OBC.CDL.Integers.Sources.Constant[nUni] | conPos | Position index within staging order | |
| Buildings.Controls.OBC.CDL.Integers.Sources.Constant[nUni] | conNUni | Number of units | |
| Buildings.Controls.OBC.CDL.Integers.Switch[nUni] | swiVal | Penalized position: nUni if unit at position is flagged, position index otherwise | |
| Buildings.Controls.OBC.CDL.Routing.IntegerVectorReplicator | repPos | Position index matrix: element (i, j) is j | |
| Buildings.Controls.OBC.CDL.Routing.IntegerScalarReplicator[nUni] | repRow | Position index matrix: element (i, j) is i | |
| Buildings.Controls.OBC.CDL.Integers.GreaterEqual[nUni,nUni] | greEqu | True if j >= i: candidate positions for resolving position i | |
| Buildings.Controls.OBC.CDL.Routing.IntegerVectorReplicator | repVal | Replicate penalized positions for each position | |
| Buildings.Controls.OBC.CDL.Integers.Sources.Constant[nUni,nUni] | conNUniMat | Number of units | |
| Buildings.Controls.OBC.CDL.Integers.Switch[nUni,nUni] | swiMas | Mask out positions before position i with nUni | |
| Buildings.Controls.OBC.CDL.Conversions.IntegerToReal[nUni,nUni] | intToRea | Convert to real for row-wise minimum | |
| Buildings.Controls.OBC.CDL.Reals.MultiMin[nUni] | mulMin | First non-flagged position at or after position i, nUni if none | |
| Buildings.Controls.OBC.CDL.Conversions.RealToInteger[nUni] | reaToInt | Convert resolved position back to integer | |
| Buildings.Controls.OBC.CDL.Routing.IntegerVectorReplicator | repIdx | Replicate sorted unit indices for each position | |
| Buildings.Controls.OBC.CDL.Routing.IntegerExtractor[nUni] | extIdx | Extract unit index at resolved position: uIdxSor[k[i]] |
Revisions
-
July 10, 2026, by Antoine Gautier:
First implementation.