Rate of exchange is proportional to amount in stocks


This information is part of the Business Simulation Library (BSL).

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

stockA.y ⋅ u

u <= 0 flow from B to A

stockB.y ⋅ |u|


  • Depending on the structural parameter useAbsoluteLevels the 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 useAbsoluteLevels may 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 (1)


Value: true

Type: Boolean

Description: = 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 (6)


Type: FlowPort

Description: Flow from/to Stock A


Type: FlowPort

Description: Flow to/from Stock B


Type: RealOutput

Description: Rate information


Type: RealOutput

Description: Rate information


Type: RealOutput

Description: Rate information


Type: RealInput

Description: Fractional rate input