2.1 Constitutive Equations
The mass conservation equations for pipes, junctions and storage facilities may be summarised briefly as follows.
The mass conservation equation for pipes is (Rossman
2000)
$$ \frac{\partial {C}_i}{\partial t}=-{u}_i\frac{\partial {C}_i}{\partial x}+{r}_i;\kern1em \forall i $$
(1)
where
C
i
≡
C(
i,
x,
t) is the reactant concentration in pipe
i at location
x at time
t;
u
i
≡
u(
i,
t) is the mean flow velocity in pipe
i at time
t; and
r
i
≡
r(
C
i
) is the rate of reaction. The equation assumes that longitudinal dispersion in the pipes is negligible.
The mass balance equation for node
n is
$$ \left(\sum_{j\in {I}_n}{Qp}_j+{Q}_e\right)C{\left(i,x,t\right)}_{x=0}=\sum_{j\in {I}_n}\left({Qp}_jC{\left(j,x,t\right)}_{x={L}_j}\right)+{Q}_e{C}_e;\kern1em \forall i\in {O}_n,\kern1em \forall n $$
(2)
where
j and
i respectively denote pipes with flow entering and leaving node
n.
I
n
and O
n
respectively denote the sets of pipes with flow entering and leaving node
n;
L
j
is the length of pipe
j;
Qp
j
is the volume flow rate in pipe
j;
Q
e
and
C
e
are, respectively, the volume flow rate and reactant concentration for any external flow entering node
n.
The mass balance equation for the
s
th
storage facility (tank or service reservoir) is
$$ \frac{\partial \left({V}_s{C}_s\right)}{\partial t}=\sum_{i\in {I}_s}\left({Qp}_iC{\left(i,x,t\right)}_{x={L}_i}\right)-\sum_{j\in {O}_s}{Qp}_j{C}_s+{r}_s;\kern1em \forall s $$
(3)
where
V
s
≡ V(s,t) and
C
s
≡ C(s,t) are, respectively, the volume in storage and reactant concentration at time
t;
I
s
denotes the set of links supplying the storage facility with flow;
O
s
denotes the set of links receiving flow from the facility; and
r
s
≡
r(
C
s
) is the rate of reaction.
Besides the reactions in the bulk flow, there may be reactions with biofilm, corrosion and other materials at the pipe walls. The reaction rate coefficient employed in EPANET 2 for the reactions at the pipe wall is (Rossman et al.
1994; Powell et al.
2004: 11-12)
$$ {k}_{w\ast }=\frac{k_w{k}_f}{R\left({k}_w+{k}_f\right)} $$
(4)
where
k
w*
is the wall reaction rate coefficient (1/time);
k
w
is the wall reactivity coefficient (length/time);
k
f
is the radial mass transfer coefficient (length/time); and
R is the hydraulic radius. The value of
k
f
depends on the molecular diffusivity of the reactive species and the turbulence of the flow.
Several kinetic models that are included in this article to demonstrate the effectiveness of the proposed framework for low-pressure conditions and multiple concurrent reactions are described briefly here. Both the single-species (Eqs.
5 and
7) and two-species models with fast- and slow-reacting components (Eqs.
6,
8 and
9) (Helbling and Van Briesen
2009; Sohn et al.
2004; Amy et al.
1998) were considered for the disinfectant, chlorine, and predominant disinfection by-products, trihalomethanes and haloacetic acids (Nieuwenhuijsen et al.
2000).
An inadequate chlorine residual in a distribution system may lead to bacterial regrowth (Clark and Haught
2005) and, consequently, water-borne diseases. Disinfection by-products result from the reactions of chlorine with natural organic compounds in water (Rodriguez et al.
2004; Ghebremichael et al.
2008) and are associated with adverse health effects (Nieuwenhuijsen et al.
2000; Richardson et al.
2002; Nieuwenhuijsen
2005; Hebert et al.
2010).
The first-order (Rossman
2000) and parallel first-order (Helbling and Van Briesen
2009) kinetic models for chlorine decay are, respectively,
$$ r\left({C}_C\right)\equiv \frac{\partial {C}_C}{\partial t}=-{kC}_C $$
(5)
$$ {C}_C(t)={C}_{C0}\left[\rho \exp \left(-{k}_1t\right)+\left(1-\rho \right) \exp \left(-{k}_2t\right)\right] $$
(6)
Recalling that the reactant concentrations vary with space and time as in Eqs.
1 to
3,
C
C
≡
C
C
(t) is the time-varying chlorine concentration at a demand node or junction; and
C
C0
is the initial chlorine concentration at the node or junction in question. It is worth repeating that the water quality results relate to the fully developed operational cycle (typically 24 h).
C
C0
is thus the chlorine concentration at the node at time
t = 0.
k is the reaction rate constant,
k
1
and
k
2
are the fast and slow chlorine decay coefficients, respectively, and
ρ represents the fraction of chlorine that reacts rapidly.
The first-order (Rossman
2000) and parallel first-order (Sohn et al.
2004) models for trihalomethanes, and the parallel first-order model for haloacetic acids (Sohn et al.
2004) are, respectively,
$$ r\left({C}_{TTHM}\right)\equiv \frac{\partial {C}_{TTHM}}{\partial t}=k\left({C}_L-{C}_{TTHM}\right) $$
(7)
$$ {C}_{TTHM}={C}_{C0}\left[\alpha \left(1- \exp \left(-{k}_1t\right)\right)+\beta \left(1- \exp \left(-{k}_2t\right)\right)\right] $$
(8)
$$ {C}_{HAA6}={C}_{C0}\left[\gamma \left(1- \exp \left(-{k}_1t\right)\right)+\delta \left(1- \exp \left(-{k}_2t\right)\right)\right] $$
(9)
where
C
TTHM
refers to the time-varying total concentration of trihalomethanes (TTHM) while
C
L
is the ultimate concentration (Rossman
2000).
C
HAA6
refers to the time-varying concentration of haloacetic acids (HAA6) (i.e. six species),
k is the reaction rate constant and
C
C0
is the initial chlorine concentration (as in Eq.
6).
k
1
and
k
2
are the fast and slow chlorine decay coefficients, respectively, while
α, β, γ and
δ are empirical coefficients.
2.2 Brief Overview of the Computational Solution Methods
Eulerian and Lagrangian approaches are commonly used together with a hydraulic simulation model to solve the water quality equations computationally. The discrete volume method is an Eulerian approach that Grayman et al. (
1988) suggested. Each pipe is divided into equal segments with completely mixed volumes. At each successive water quality time step, the concentration within each segment is determined and transferred to the adjacent downstream segment. At nodes, the concentration is updated using a flow-weighted average of the inflows (Eq.
2). The resulting concentration is then transferred to all adjacent downstream segments. This process is repeated for each water quality time step until a different hydraulic condition occurs. When a new hydraulic condition occurs, the pipes are divided again and the process continues.
Liou and Kroon (
1987) suggested a Lagrangian method that divides the pipes into segments similarly. Unlike Eulerian methods, the water parcels in the pipes are tracked and, at each time step, the length of the farthest upstream parcel in each pipe increases as water enters the pipe while the farthest downstream parcel shortens as water leaves the pipe. The concentration at every node is updated by a flow-weighted average of the inflows (Eq.
2). If the resulting nodal concentration is significantly different from the concentration of an adjacent downstream parcel, a new parcel is created at the upstream end of each link that receives flow from the node. The process repeats for each water quality time step until a different hydraulic condition occurs and the procedure begins again.
Lagrangian methods can be either time- or event-driven. Time-driven methods update the conditions using a fixed time step whereas event-driven methods do so when the water quality at the source changes or the front end of a parcel reaches a node. A comparison by Rossman and Boulos (
1996) indicated that the time-driven Lagrangian method was the most efficient. EPANET 2 and EPANET-MSX employ a time-driven Lagrangian approach (Rossman
2000; Shang et al.
2008b).