0 votes
in AEM3D by [email protected] (210 points)
edited by [email protected]
Dear All,

I would like to simulate a dam overflow in a reservoir where, there is a bottom outflow and an overflow.

I have tried to use an open boundary cell and set a "HEIGHT boundary condition" for it to remove an excess of water in the model but the model ends simulations with a CFL error after the first step.

I have also tried to add an outflow boundary condition at a height, where the overflow should be. Such boundary condition needs to have an outflow rate exceeding the maximum inflow to the reservoir. Only then it will serve as an overflow. In such case, however, the CFL error occur in moments, when the outflow begins or ends (due to the highest flow velocity near to the boundary condition cell). The same result is when using “INFLOW MAXDEPTH” or “GATE_1_BOTTOM”. Whenever the water level reaches the bottom of the outflow cell, even relatively low outflow causes the CFL error.

The only successful way to remove an excess of water at certain elevation was using the "flow_bottom" boundary condition set to a large number of cells.

Is there any other option to simulate the overflow?

Rafal

1 Answer

+2 votes
by [email protected] (19.8k points)
selected by [email protected]
 
Best answer
Hi Rafal,

This is basically what the dynamic boundary conditions were originally designed for, you can use them to specify the outflow through a bc as a function of the simulated height.  An example xml for a weir overflow is

<?xml version="1.0" encoding="UTF-8"?>
<AEM3DDynamicBC>
  <Variable>
    <name>h</name>
    <i>6</i>
    <j>28</j>
    <key>HEIGHT</key>
  </Variable>
  <Variable>
    <name>w</name>
    <key>CONSTANT</key>
    <constant>20</constant>
  </Variable>
  <Range_Variable>
    <name>h</name>
    <i>6</i>
    <j>28</j>
    <key>HEIGHT</key>
  </Range_Variable>
  <Range>
    <maxValue>19</maxValue>
    <script>0</script>
  </Range>
  <Range>
    <minValue>15</minValue>
    <maxValue>40</maxValue>
    <script>0.5*SQRT(2*9.81)*w*((h-19)**1.5)</script>
  </Range>
  <Range>
    <minValue>40</minValue>
    <script>4000</script>
  </Range>
  <bc>301</bc>
  <bc_key>OUTFLOW</bc_key>
</AEM3DDynamicBC>

This uses the simulated height as i,j of 6,28 to set the outflow through bc ref 301.  The range variables set the outflow to 0 if the height is 19, uses the weir equation between h = 15 and 40 and sets a large value above 40.

Chris
by [email protected] (210 points)
Thank you, Chris.
It works perfectly.

In your XML file the 'h' is repeated as a "variable" and a "range_variable". It seems that the 'variable" section with the "h" can be deleted and the result will be the same. Is that correct?
by [email protected] (19.8k points)
Hi, "variables" are used in the script and you can have multiple variables.  "Range_Variable" is used in selecting which range element is used.

Chris
by [email protected] (210 points)
Now it is clear. The "h" has to be repeated ("variable" and "range_variable") because it is used for two purposes.

Thank you again.
by [email protected] (680 points)
This is very helpful
Welcome to Hydronumerics Q&A, where you can ask questions and receive answers about the software we develop and distribute

Categories

Hydronumerics

  • Suite 103 757 Bourke St Docklands Victoria 3008
  • Suite 103 757 Bourke St Docklands Victoria 3008
  • +61 3 9037 0892
  • [email protected]
  • Twitter
...