HEC-RAS has the ability to model lateral weirs, gated spillways, culverts, and user entered rating curves. The modeler can insert a lateral weir only, or a separate gated spillway structure, or any combination of the four types. An example diagram of a lateral structure is shown in the figure below.
Plan View of an Example Lateral Weir

At a minimum there must be a cross section upstream of and a cross section downstream of the lateral structure. The upstream cross section can either be right at the beginning of the structure, or it can be a short distance upstream. The downstream cross section can be right at the downstream end of the structure or it can be a short distance downstream. The user can have any number of additional cross sections in the middle of the structure.

If there are gated openings in the structure, the hydraulic computations for lateral gated spillways are exactly the same as those described previously for inline gated spillways. The only difference is that the headwater energy is computed separately for each gate, based on its centerline location along the stream. The headwater energy for each gate is interpolated linearly between computed points at each cross section. Culvert hydraulics are modeled the same way as described in "Modeling Culverts" of this document. The user has the additional option of defining a flap gate, which can be used to limit flow through a culvert to one direction only.

An example lateral structure is shown in the figure below as a profile view.
Example Lateral Weir and Gated Spillway

As shown in the first figure above, the water surface across the weir has a slope to it. Additionally, the weir itself could be on a slope. Because of this, an equation for weir flow with a sloping water surface and weir sill had to be derived. Shown in the figure above is a sloping weir segment with a sloping water surface. The equation for a sloping line representing the water surface and the weir segment are shown. The constants aws and aw represent the slope of the water surface and the weir segment, respectively, while the variable Cws and Cw are constants representing the initial elevations.

Figure 8-13 Sloping Weir Segment and Water Surface

The standard weir equation (Overflow Gates:1) assumes that the weir is parallel with the water surface (i.e. that the depth of water is constant from one end of the weir segment to the other). The following general equation is derived for a sloping weir and water surface by integrating the standard weir equation:

1) dQ=C(y_{ws} -y_w)^{3/2} dx
2) dQ=C(a_{ws}x + C_{ws} -a_w x - C_w)^{3/2} dx
3) dQ=C((a_{ws}-a_w)x + C_{ws} - C_w)^{3/2} dx

Assuming: a_1=a_{ws}-a_w and C_1 = C_{ws} - C_w

4) \displaystyle \int_{x_1}^{x_2} dQ=C \int_{x_1}^{x_2} (a_1 x + C_1)^{3/2} dx = \frac{2C}{5a_1} (a_1 x + C_1)^{5/2} \right| ^{x_2} _{x_1}
5) \displaystyle Q_{x_1 - x_2}= \frac{2C}{5a_1} \left( (a_1 x_2 + C_1)^{5/2} - (a_1 x_1 + C_1)^{5/2} \right)

The above equation is valid as long as a1 is not zero. When a1 is zero, this implies that the water surface and the weir segment are parallel. When this is true, the original weir equation (Overflow Gates:1) is used.

Within HEC-RAS, flow over a lateral weir can be computed from either the energy grade line or the water surface elevation. The standard weir equation is derived with the upstream energy head being based on the distance from the weir sill to the upstream energy grade line. The water surface elevation is the default for a lateral weir in HEC-RAS. However, the user has the option of instructing the program to use the energy elevation when computing the head term of the weir equation. The water surface is the most appropriate when the weir is located close to the main channel. In this situation the energy due to the velocity head is in the downstream direction, and not over the top of the lateral weir. Therefore, the computation of the energy head over the lateral weir is best depicted by using the water surface of the flow in the channel.

The predecessor to HEC-RAS (HEC-2 program) also used the water surface elevation as the default for lateral weir calculations. This is an important point to remember when comparing results between HEC-RAS and HEC-2. However, both programs allow the user to select either the energy grade line or the water surface elevation for this calculation.