Compute Blocking in HEC-ResSim

HEC-ResSim first performs its computations at the upstream end of the main stem of the river system and at the upstream end of the tributaries and works its way downstream.  If there is a rule that has dependence on a downstream condition that does not appear to be behaving correctly, there may be a compute blocking issue.  In this post, I will demonstrate a compute blocking issue and show how to solve it.

The river system in this example consists of a main stem with two reservoirs.  Both reservoirs have a top of conservation level of 75.0 feet.  For this simulation, I started both reservoirs in their flood pool.  The downstream reservoir has no rules so it releases it physical capacity of 1,500 cfs until the flood pool is empty.



The upstream reservoir has a scripted rule that sets the maximum release to 100 cfs if the downstream reservoir is at 77.0 feet or higher.  Once the downstream reservoir is below 77.0 feet, the maximum release increases to 1,200 cfs.  The script is shown below.





Below are the results of the simulation for the upstream reservoir.  At the first time step after the lookback period, the release is correct since the downstream pool elevation is available.  However, due to compute blocking, the downstream elevation is not available at the time the script is run so the the "else" condition is triggered allowing for 1,200 cfs.



The plot below shows the downstream pool elevation.  We can see that the pool elevation starts at 80.0 feet so the release at the upstream reservoir should be held at 100 cfs until the downstream pool elevation falls to 77.0 feet.



Below is a screenshot of the compute blocking found in the compute log.  Note that there are 9 blocks with CP1 (upstream end of model) being the first block.



To solve our issue, I want to create dependence of a downstream element for the upstream reservoir.  To do this, I simply create a "dummy" rule at the upstream reservoir setting a minimum release of zero for a very large range of values at the junction, "downstream point".  A minimum release rule of zero does not affect the operations, it simply creates the dependence we are seeking.



The addition of this rule now decreases the number of compute block and puts the computations of the upstream and downstream reservoir into the same compute block.



The results for the upstream reservoir are shown below.  The release is held to 100 cfs at the beginning of the simulation and then increases to 1,200 cfs once the downstream reservoir falls below 77.0 feet (note: the downstream reservoir results are not shown).





Comments