Reservoir elements can be instantaneously impacted by a discrete change signal. Moreover, a Reservoir can also produce (emit) discrete change signals.
The Reservoir dialog has special input fields for accepting a discrete change signal:
Discrete changes to the Reservoir are entered in the Discrete Change fields (Additions or Withdrawal Requests).
If the checkbox to the left of Discrete Change under Additions in the Reservoir dialog is checked, then:
• the input field is activated; and
• if the Reservoir has an Upper Bound, a new output called Discrete_Overflow is created on the element.
The Discrete Change input under Additions accepts discrete change signals which have a positive value Add instruction. It also accepts discrete change signals which have a Replace instruction. The dimensions and order of the discrete change signal must be the same as those of the Reservoir.
When a Reservoir receives a Discrete Change Addition with an Add instruction, it instantaneously adds the value of the signal to the Value of the Reservoir. When a Reservoir receives a Discrete Change Addition with a Replace instruction, it instantaneously replaces the Value of the Reservoir with the value of the signal.
If the Reservoir has an Upper Bound and this is exceeded by the Discrete Change Addition, the Value is fixed at the Upper Bound, and the Reservoir produces (emits) a discrete change signal (Discrete_Overflow) which represents the amount of the Discrete Change Addition which "overflowed" the Reservoir.
Note: If you have specified an Upper or Lower Bound, and choose to Replace the current value of a Reservoir, the replacement value must be within the bounds (or GoldSim will display a fatal error message).
If the checkbox to the left of Discrete Change under Withdrawal Requests is checked, then
• the input field is activated; and
• a new output called Discrete_Withdrawals is created on the element.
The Discrete Change input under Withdrawal Requests only accepts discrete change signals which have a positive value and an Add instruction. The dimensions and order of the discrete change signal must be the same as those of the Reservoir.
When a Reservoir receives a Discrete Change Withdrawal Request, it instantaneously subtracts the value of the signal from Value of the Reservoir. In addition, a discrete change signal (Discrete_Withdrawals) which echoes the Discrete Change Withdrawal Request that was removed from the Reservoir is automatically emitted.
If the Reservoir has a Lower Bound and the Discrete Change Withdrawal Request forces the Reservoir to go below this value, the Value is fixed at the Lower Bound, and the Reservoir produces (emits) a discrete change signal (Discrete_Withdrawals) which represents the actual Discrete Change Withdrawal that was removed from the Reservoir (i.e., the difference between the Value prior to the withdrawal and the Lower Bound).
A Reservoir can accept multiple Discrete Changes (both Additions and Withdrawal Requests). This is indicated in the input field by separating the individual discrete change signals by semi-colons (e.g., Change1; Change2; Change3).
You can also specify the multiple discrete changes using the Multiple Discrete Signals button, which displays a table listing the multiple discrete change signals:
Learn more about: