Variable Height - Boundary Condition Description
Variable Height is a boundary condition designed for multiphase flows, which defines a phase fraction condition based on the local flow conditions. The values are constrained within low and upper bounds.
The boundary condition works according to the following piecewise function:
\(\alpha = \begin{cases} \text{Upper Bound} & \text{if } \alpha > \text{upper bound} \\ \text{Zero Gradient} & \text{if lower bound} \leq \alpha \leq \text{upper bound} \\ \text{Lower Bound} & \text{if } \alpha < \text{lower bound} \end{cases}\)
Where "Upper Bound" and "Lower Bound" refer to Fixed Value according to the respective bound, and #Zero Gradient refers to the boundary condition where the normal gradient is set to zero.
Variable Height - Boundary Condition Understanding Variable Height
Variable Height is useful in situations where on the inlet to the domain or outlet we do not want to define Fixed Value, but rather allow the flow to adjust to the current situation. For example, consider a tank with water inflow.
The boundary condition allows the water level in the tank to increase as more water enters the tank. The lower and upper bounds can be defined to limit the minimum and maximum water levels.
Variable Height - Boundary Condition Application & Physical Interpretation
Variable Height is most often used on free‑surface boundaries, where water must leave the domain naturally, but occasional back‑flow can occur. For flow out of the domain, it does nothing (zero‑gradient), so the wave or jet exits cleanly. If a vortex pulls fluid back in, the boundary condition clips the incoming mixture so the phase fraction stays between the user-defined minimum and maximum.
Variable Height in Weir Overflow applications
Example applications: weirs, spillways, open-channels
These types of simulations can be solved using the interFoam (solver) The Variable Height can be applied to the domain inlet to represent a volumetric flow, which will adjust according to water level.
| Physics | Modified Pressure p_rgh | Velocity | \(\alpha_{water}\) |
|---|---|---|---|
Inlet | Zero Gradient | Variable Height Inlet | Variable Height |
Variable Height - Boundary Condition Variable Height in SimFlow
The boundary condition can be applied for the phase fraction \(\alpha\). To define the boundary condition, the proper option must be selected from the drop-down menu - Figure 1.

The user needs to define the lower and upper bounds \([-]\).
Variable Height - Boundary Condition Variable Height - Alternatives
In this section, we propose boundary conditions that are alternative to Variable Height. While they may fulfill similar purposes, they might be better suited for a specific application and provide a better approximation of physical world conditions.
| Boundary Condition | Description |
|---|---|
switches between Zero Gradient when fluid flows out and Fixed Value when fluid flows in, allowing fluid to enter or exit based on local flow conditions | |
fixed value on a patch | |
the normal gradient is set to zero |