# Conservation laws

The calculation of flow in 3Di is based on two fundamental laws of physics: conservation of mass and conservation of momentum.

## Conservation of mass

To capture or predict flow under varying conditions, one is often forced to use the computational power of computers. Since the introduction of computers various methods have been introduced and improved. Some aspects are true for all types of methods. Here, we will limit ourselves to the methods used in the computational core of 3Di.

3Di is a two-layer, subgrid based hydrodynamical model, where a surface and a subsurface layer can be defined in combination with a 1D network. The computations of flow in each domain are based on two fundamental laws of physics; i) Conservation of mass and ii) Conservation of momentum. In this section we will describe how we deal with conservation of mass.

Conservation of mass states that mass cannot disappear or appear in a certain domain without clear source. For a defined domain, when all fluxes in and out of that domain are known, the change in mass can be computed. This can be described mathematically as:

The counters i, j, k count over all existing discharges, sink and source terms. In 3Di we do not account for density variations, so the density \(\rho\) is assumed uniform and constant. This simplifies the equation for conservation of mass to the following equation for conservation of volume:

It is important to define the domain for which this is true. In the finite volume approach, used in 3Di, a volume domain equals a computational cell, i.e. the water level domain. For such a domain, as shown in the Figure, all discharges (in blue) sources and sink terms (in yellow) entering and leaving the domain are to be defined or computed. The discharges are computed based on the momentum equations. The Section Flow elaborates on the computation of flow in the various domains, such as 2D surface water, ground water, 1D surface and sewerage flow. Sources and sink terms are generally terms for water that is added or extracted in a domain. The various source and sink options are described in Surface sources and sinks. Examples of source and sink terms are Simple Infiltration and Rain. In 3Di, the conservation of volume combines all flow phenomena. This is independent of the origin of the flow (1D, 2D surface or subsurface domain). This allows a fully integrated approach of a water system.

## Conservation of momentum

The way in which the law of conservation of momentum is applied depends on the domain (1D or 2D). This is explained in the sections 1D Flow and 2D Surface flow.