**1. Introduction**

The quality of water is representative of its suitability for domestic and institutional use. Water quality analysis and modelling is an important aspect of the water distribution system (WDS) design, along with the efficient hydraulic performance of the network [1,2]. A water quality model has to be an optimal solution, like that of the hydraulic model, to achieve the maximum efficiency of the performance of a WDS [3]. Important water quality parameters like concentration of chlorine, decay of chlorine in the system [4,5] and water age [6] have to be modelled, so as to ascertain that the quality of the water is as per the standards [7]. Standard values of these parameters are vital for the optimality of the water quality model, indicating that these parameters are the decision variables for the optimal model, with the standard ranges of these variables as constraints. Leakage modelling is another important requisite of an optimal WDS model. Estimation of the amount of leakage discharge is vital for the efficient performance, with respect to hydraulics, as well as water quality of a WDS [8]. EPANET extension—WaterNetGen is an effective tool for modelling the leakage with a fair degree of accuracy and ease of use [9].

An optimal solution of the hydraulic design of WDS for the University of Kashmir (UOK) was proposed by using EPANET 2.0 in the earlier study. The WDS consists of two separate networks for two different divisions of the study area. Current work is an extension

**Citation:** Ajaz, M.; Ahmad, D. Optimal Water Quality Simulation of the Proposed Water Distribution System for the University of Kashmir Using EPANET 2.2 and Leakage Modelling of the Network Using EPANET Extension—WaterNetGen. *Environ. Sci. Proc.* **2023**, *25*, 27. https://doi.org/10.3390/ ECWS-7-14251

 Academic Editor: Athanasios Loukas

Published: 16 March 2023

**Copyright:** © 2023 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https:// creativecommons.org/licenses/by/ 4.0/).

of the work done earlier, such that an optimal water quality model for the proposed WDS is formulated using the pressure driven analysis (PDA) approach of EPANET 2.2. The leakage modelling of the proposed network has been done by WaterNetGen.

### **2. Methodological Approach and Analysis**

A quantitative pressure driven analysis approach (PDA) was used to produce an optimal water quality model of the proposed water distribution system (WDS) for the University of Kashmir (UOK) by using EPANET 2.2. Study of the literature was conducted and the most important water quality parameters, like chlorine concentration, decay of chlorine and water age, were taken as the decision variables for optimal modelling. Standard codes and books were consulted to set out the constraints for the decision variables. Finally, the leakage modelling of the network was carried out by using EPANET extension—WaterNetGen—to access the amount of leakage discharge at the nodes.

#### *2.1. PDA of Water Quality of the Network Using EPANET 2.2*

A more realistic PDA approach was used to carry out the water quality modelling, such that the variables were a function of the available pressure head at the nodes. Water quality parameters like chlorine concentration, decay of chlorine and water age were modelled using a PDA approach of the EPANET 2.2 [10]. Various input parameters, like reaction order, reaction coefficient for the bulk and wall reactions of chlorine and limiting concentration of chlorine equal to 0.2 mg/L [7], were provided to run the software successfully. The initial concentration of chlorine added to the supply tank was equal to 2 mg/L (optimum dosage of chlorine, as per the ground water quality test data provided by UOK).

### *2.2. Leakage Modeling by EPANET Extension—WaterNetGen*

The background leakage discharge Qk leak in any pipe (k) of length (Lk) was estimated after entering the values of background leakage coefficient per unit pipe length (βk) and background leakage exponent ( αk) for each pipe, as per the following equation [11,12]: Qk leak = βk Lk (Pk) αk; βk = <sup>10</sup>−7, αk = 1.18. The nodal leakage flow at any node 'i' due to the background leakage of the pipes connected at the node was estimated after running the software, as per the following equation [11]: Qi leak = 1 2 Σ Qk leak, where 'k' iterates over all the pipes connected at 'i'

Finally, the emitter discharge at the nodes was obtained after providing the value of emitter coefficient 'βi' to each node, which was calculated from the following equation [11–13]: Qi leak = βi (Pi)0.5, where (Pi) is the node pressure.

#### *2.3. Optimization of the Water Quality Model*

An optimal solution of the water quality model was obtained by selecting the following objective function subject to the decision variables and constraints, as given below:

Objective function: maximization of efficiency of performance, with respect to the water quality of the proposed WDS, without affecting the hydraulic performance.

Decision variables: the following water quality parameters were taken as the decision variables; chlorine concentration, water age.

Constraints: chlorine concentration ≥ 0.2 mg/L [7], average water age ≤ 1.3 days and maximum water age ≤ 3 days [6].

### **3. Results and Discussion**

#### *3.1. Chlorine Concentration at the Nodes*

The minimum required concentration of residual chlorine at any point in a WDS is 0.2 mg/L. Figure 1a,b indicates that the chlorine concentration at all the nodes of WDS, part I and part II, at the hour of peak demand is above 0.2 mg/L. From the analysis, 0% of the nodes have a chlorine concentration below 0.58 mg/L at the hour of peak demand in WDS part I, 0% nodes have a chlorine concentration below 0.735 mg/L in WDS part II. Figure 2a,b indicates that there is a drop in the concentration of chlorine, below 0.2mg/L,

at the peak demand nodes and the storage tank at 12 pm and onwards. Thus, there is a need to re-add the chlorine at the source node (storage tank) at 12 pm.

**Figure 1.** (**a**) Contour plot of chlorine concentration at nodes at 9:00 am for WDS part I; (**b**) contour plot of chlorine concentration at nodes at 9:00 am for WDS part II.

#### *3.2. Decay of Chlorine in the System*

As indicated in Figure 3a,b, the maximum percentage decay of chlorine is taking place in the storage reservoir in both parts of the WDS, due to the reaction within the bulk of the fluid in the storage tank. The decay, due to wall reactions, is lower due to the assumption of the use of lined G.I pipes. The decay percentage is due to the reaction of chlorine in the bulk of the water in pipes.

#### *3.3. Time Series Graph for Age of Water in the Storage Tank*

The increased age of water in a WDS is related to the growth of disinfection by products like trihalomethanes, microbial growth, etc. The maximum age of water in a WDS is limited to about 3 days [6]. In both the WDS, part I and part II, the maximum age of water in the storage tank is 12.5 h (Figure 4a,b).

(**a**) 

**Figure 2.** (**a**) Time series plot of chlorine (mg/L) at the storage tank and peak demand nodes for WDS I; (**b**) time series plot of chlorine (mg/L) at the storage tank and peak demand nodes for WDS II.

**Figure 3.** (**a**) Pie chart for chlorine decay, WDS part I; (**b**) pie chart for chlorine decay, WDS part II.

#### *3.4. Leakage Modelling of the Network by EPANET Extension—WaterNetGen*

The emitter discharge at the nodes, which is contributed to the background leakage of the pipes connected at a node, was modelled. The emitter coefficient for each node was evaluated, as explained in Section 2.3. The emitter coefficient corresponding to the time of occurrence of the maximum background leakage and pressure head at the node was taken as the design value. For WDS part I, the emitter coefficient corresponding to 4 h, and for WDS part II, that corresponding to 3 h, was entered for each node. The values of emitter discharge at the nodes at the hour of peak demand were obtained, as in Tables 1 and 2, indicating negligible leakage discharge in the WDS—0.1% for WDS part I and 0.15% for WDS part II.

(**b**) 

**Figure 4.** (**a**) Age of water in the storage tank, WDS part I; (**b**) age of water in the storage tank, WDS part II.



**Table 2.** Emitter flow at nodes for WDS part II.

### **4. Conclusions and Future Scope**

In this work, an optimal solution of water quality modelling of the proposed WDS for the University of Kashmir has been provided. Chlorine concentration and water age were taken as the decision variables for optimal design. Water quality modelling was carried out by the PDA approach of the EPANET 2.2, and the leakage modelling of the network was done by EPANET extension—WaterNetGen. The objective function of maximum efficiency of water quality performance was achieved, subject to the standard values of the decision variables and minimum percentage of leakage discharge, which was verified without affecting the optimality of the hydraulic design of the network. The main highlights of the work include the following:

The standard minimum chlorine concentration of 0.2 mg/L was maintained at each node up to 11 h of the simulation. However, a re-addition of chlorine to the water in the storage reservoir at 12 h was required to maintain the standard residual chlorine at every point in the WDS. The maximum percentage decay of chlorine took place in the storage reservoir in both parts of the WDS, and a negligible decay was observed in the bulk and at the boundary of the pipes, indicating negligible reaction between pipe material and the water and hence, longer life of the pipes of the network. The age of the water in the storage tank was limited to 12.5 h, indicating prevention of the growth of disinfection by-products and microbial growth. From the hydraulic analysis of the network, it was seen that the water age in the storage tank is inversely related to the pressure head of the tank. The leakage modelling for the network has been completed using WaterNetGen and leakage discharge obtained at the peak demand hour. The total leakage discharge obtained for WDS part I is 0.013 L/s and is 0.029 L/s for WDS part II, respectively, which is 0.1% and 0.15% of the design discharge, respectively, and thus negligible. The very small magnitude of leakage discharge indicates the optimality of the overall design of the network.

The extensions available to the EPANET can be used for water security modelling, real time modelling and fire flow analysis of the designed WDS. EPANET-MSX (multispecies extension), the interaction of multiple chemical agents between each other, with the material of walls of the pipes and the bulk of the fluid, can be modelled. Additionally, the auto decomposition of chloramines to ammonia, formation of disinfection by products and biological regrowth can be modelled. EPANET-RTX (real-time extension) allows for the connection of the operational data with a network model, and the resultant model can be calibrated, verified and tested for precision using the operational data. WaterNetGen can be used for the fire flow analysis of the network model.

**Author Contributions:** Both authors contributed equally to this work. All authors have read and agreed to the published version of the manuscript.

**Funding:** This research received no external funding.

**Institutional Review Board Statement:** Not applicable.

**Informed Consent Statement:** The study did not involve any humans.

**Data Availability Statement:** All the data required was obtained from the Engineering wing of the University of Kashmir.

**Conflicts of Interest:** The authors declare no conflict of interest.
