modelProportionalSwitching
Rate of exchange is proportional to amount in stocks
Extends from Interfaces.PartialFlows.BidirectionalFlow (Generic bi-directional flow between two stocks).
Information
This information is part of the Business Simulation Library (BSL). Please support this work and ► donate.
ProportionalSwitching models the exchange of "mass" (conserved matter or information) between two stocks as a bi-directional flow. The rate of flow will be proportional to the amount in the connected levels times the fractional rate of flow given by the input u:
| input u | direction of flow (for positive levels) |
rate of flow |
| u ≥ 0 | flow from A to B |
|
| u <= 0 | flow from B to A |
|
Notes
- Depending on the structural parameter
useAbsoluteLevelsthe direction of flow may be reversed by negative amounts in the connected stocks, which is possible, if the stocks are information levels (material stocks by definition cannot become negative). - If material stocks are connected to the ProportionalSwitching element, then
useAbsoluteLevelsmay be set to false as the amount in the stocks cannot become negative. - If information levels are connected via the ProportionalSwitching component, then the intended behavior has to be carefully chosen.
See also
Parameters
| Type | Name | Default | Description |
|---|---|---|---|
| Structural Parameters | |||
| Boolean | useAbsoluteLevels | true | = true, if the stock levels are to be taken als absolute values otherweise a negative amount in a stock may reverse the direction of flow |
Connectors
| Type | Name | Default | Description |
|---|---|---|---|
| Connectors.FlowPort | portA (from GenericFlow) | Flow from/to Stock A | |
| Connectors.FlowPort | portB (from GenericFlow) | Flow to/from Stock B | |
| Interfaces.Connectors.RealInput | u | Fractional rate input |
Components
| Type | Name | Default | Description |
|---|---|---|---|
| RealOutput | y (from ThreeSO_rate) | Rate information | |
| RealOutput | y1 (from ThreeSO_rate) | Rate information | |
| RealOutput | y2 (from ThreeSO_rate) | Rate information |