Modeling Bacterial Regrowth and Trihalomethane Formation in Water Distribution Systems

The formation of bacterial regrowth and disinfection by-products is ubiquitous in chlorinated water distribution systems (WDSs) operated with organic loads. A generic, easy-to-use mechanistic model describing the fundamental processes governing the interrelationship between chlorine, total organic carbon (TOC), and bacteria to analyze the spatiotemporal water quality variations in WDSs was developed using EPANET-MSX. The representation of multispecies reactions was simplified to minimize the interdependent model parameters. The physicochemical/biological processes that cannot be experimentally determined were neglected. The effects of source water characteristics and water residence time on controlling bacterial regrowth and Trihalomethane (THM) formation in two well-tested systems under chlorinated and non-chlorinated conditions were analyzed by applying the model. The results established that a 100% increase in the free chlorine concentration and a 50% reduction in the TOC at the source effectuated a 5.87 log scale decrement in the bacteriological activity at the expense of a 60% increase in THM formation. The sensitivity study showed the impact of the operating conditions and the network characteristics in determining parameter sensitivities to model outputs. The maximum specific growth rate constant for bulk phase bacteria was found to be the most sensitive parameter to the predicted bacterial regrowth.


Introduction
The focus during the operation of water distribution systems (WDSs) is to maintain the risk of trade-off between protection against opportunistic pathogens and the disinfection by-products (DBPs) [1]. Water quality models, specifically multispecies reactivetransport (MSRT) models that simulate the interactions and transport of various abiotic and biotic factors in the WDSs, become significant in this regard. Most of the attempts to model the bacterial regrowth and DBP formation in WDSs utilized deterministic approaches applying theoretical knowledge about reactions of the numerous reactive water species [2].
The conceptual base for multispecies modeling in WDSs was set forth by the pioneering work of [3]. The deterministic model, named the SANCHO model, developed by [4], established itself as a convenient water quality modeling tool. However, the SANCHO model, not linked with a hydraulic analysis model, later became inadequate to investigate water quality under unsteady flow conditions. Nonetheless, the PICCOBIO model [5], effectively linked with a hydraulic analysis model (Piccolo), facilitated dynamic modeling of water quality variations within the distribution pipes.
Apparently, during the development of the PICCOBIO model, the researchers complicated the mathematical descriptions and increased the number of parameters used for describing the multispecies interactions. The model postulated that the biofilm layers would consist of chlorinated and non-chlorinated layers, and that the diffusion of chlorine would only take place up to the chlorinated layer. In addition, the reactions of hypochlorite ions and hypochlorous acid were separately addressed to explain the reaction kinetics of chlorine in WDSs. As the expected variation in pH is negligible during the conveyance of water in distribution pipes, significant changes might not happen to the relative proportions of the two forms of free chlorine. Therefore, a more general and simplified kinetic description with a smaller number of parameters, neglecting the effect of pH, could have provided a good explanation of the process of bacterial mortality induced by free chlorine. Equally, the use of different reaction rates for hypochlorous acid and hypochlorite ions in the mathematical description of chlorine disappearance reactions could have also been avoided and instead, a simpler kinetic relationship could have been advocated. The number of parameters employed in the kinetic descriptions for detachment could also be lower, and a much simpler mathematical description could have been adopted, reducing the computational efforts.
The later model proposed by [6] successfully overcame many of the aforementioned drawbacks of the PICCOBIO model. These researchers simplified the mathematical expressions to define the multispecies processes concerning bacterial regrowth inside distribution pipes. However, the bacterial detachment from the biofilm layers was assumed to follow first-order kinetics concerning bacterial counts in this attempt. Consequently, the model by [6] failed in explicitly accounting for the temperature effects and the turbulent shear effects on the biofilm dynamics [7]. The mechanistic model developed by [8], akin to [6], presumed first-order dependence of the detaching bacteria with both the flow velocity and the biofilm density. However, specific conceptual issues plagued the model by [8], and several assumptions made during its development stage have been proven to be inadequate by recent studies [9].
All the above-discussed mechanistic MSRT models dealt mainly with the microbiological interactions in the WDSs and the microbiological quality of the delivered water. None of the above models considered the formation and transport of DBPs in WDSs. An attempt in this regard, by developing the WU-MSRT model, was reported by [10]. A similar work, utilizing a Cellular Automata-based model (CA-MSRT model), was recently reported by [11]. Both the 1-D models (WU-MSRT and CA-MSRT) considered Trihalomethanes (THMs) as the surrogate for DBPs in WDSs and utilized the concepts of bacterial regrowth, biofilm formation, and the dynamics of chlorine decay and natural organic matter (NOM) degradation reported by earlier researchers [5,6,8]. Consequently, the multispecies interactions between chlorine, NOM, and microbial biomass were represented in both the bulk and wall phases of distribution pipes through complex equations constituting many interdependent parameters. The bulk phase represented the dynamic portion of the distribution pipe, while the wall phase represented the thin static biofilm layer [5].
It may be noted that the quality of any mechanistic model predictions depends on the certainty of understanding the processes [12]. Unfortunately, the state of knowledge about several multispecies interactions in WDSs, included in the models mentioned above, is inadequate for making deterministic water quality predictions. Additionally, technical infeasibilities plague the direct measurement of reactive species at the biofilm layers, specifically chlorine and NOM. Hence, the calibration and validation of the existing deterministic models using real-world data become challenging for practitioners.
Nevertheless, it has to be agreed that the conceptual base and the computational efficiency of MSRT modeling have evolved and improved, respectively, over time. However, after the development of the PICCOBIO model, the research remained more or less as an academic exercise. It failed to advance in terms of evolving practically applicable and easy-to-use simulation engines. This paper explicitly addresses this issue by developing a mechanistic model to aid the WDSs design and operation using EPANET-MSX [13]. EPANET-MSX is the multispecies extension of EPANET [14], the most widely used package for modeling WDSs. To date, a bacterial regrowth and THM formation model using EPANET-MSX has not been developed.
The proposed model considers the advective transport and physicochemical and biological reactions of chlorine, NOM, bacteria, and THMs in WDSs. However, unlike the earlier reported works, primary importance is given to the simplification of the representation of the multispecies reactions in WDSs and minimizing the number of interdependent parameters. Likewise, the physicochemical and biological interactions that cannot be experimentally investigated are omitted in the conceptual stage. A detailed sensitivity analysis of the proposed model is presented by applying the model to benchmark problems to benefit the practitioners in categorizing the model parameters for future applications. Given the recent drifts towards non-chlorinated operation [2], the prospect of the proposed model applicability on non-chlorinated WDSs is also ascertained.
The remainder of the paper is organized as follows: Section 2 explains the development of the MSRT model. The conceptual and numerical details of the model are elucidated in this section. Section 3 features the application of the developed model to demonstrate the effects of source water characteristics and water residence time in controlling bacterial regrowth and DBP formation in WDSs. Section 4 presents the deterministic sensitivity analysis of the proposed mechanistic model in detail. Limitations and conclusions of the present study are summarized in Sections 5 and 6, respectively.

Conceptual Model
The proposed mechanistic model combines the advective transport with the physicochemical and biological reactions of the following five species: chlorine, total organic carbon (TOC), biodegradable OC (BDOC), bacteria (both suspended and attached), and THMs. Due to the homogeneous configuration of the distribution pipes, a 1-D modeling approach was selected [15] to represent the spatiotemporal distributions of the aforementioned species in WDSs. Chlorine was the disinfectant chemical inhibiting bacterial activity, while BDOC was the organic fraction acting as the substrate for bacterial regrowth. TOC and BDOC were the surrogate parameters for NOM in water, and they represent the mass of the total and biodegradable organic matter present in the water, respectively. The BDOC is only a fraction of TOC that can be assimilated and/or mineralized by the heterotrophic flora residing in WDSs [16]. Its absence in the delivered water limits the bacterial activity in WDSs [17].
The Pseudomonas bacteria strains, with organic carbon contents in the cell varying between 1.04 × 10 −8 and 1.40 × 10 −9 mg-carbon(C)/CFU [18], were selected as surrogates for bacteria inside the bulk phase and biofilm layers. For simplification, the bacterial cells' organic carbon contents were approximated as 1 × 10 −9 mg-C/CFU [10,11]. The biofilm layers were represented as a uniform layer distributed evenly across the perimeter of distribution pipes [19]. The transformation between the bulk and biofilm layers was assumed to occur via attachment and detachment mechanisms. THMs account for more than fifty per cent of all the halogenated DBPs in WDSs, and they induce carcinogenic and reproductive risks [20,21]. Thus, in this study, THMs were selected as the surrogate for DBPs in distribution pipes, and it was presumed that they form in the bulk phase by the chlorination of both NOM and bacteria-derived DBP precursors [22]. The effects of pipe material and zero-valent iron in water in the formation of DBPs [23] were neglected to simplify the model formulation.

Multispecies Interactions
The physicochemical and biological interactions between the five species considered in the model formulation are schematically represented in Figure 1. The multispecies reactions considered in the model are as follows: (i) Chlorination of NOM and suspended bacteria. The reactions of chlorine with the NOM and the bulk phase bacteria, causing its decay in the bulk phase, were represented using second-order kinetics based on the concept of competing reactions in water [24].
(ii) Diffusion of chlorine and its reaction with the pipe wall. The diffusion of chlorine from the bulk to the wall phase was approximated to occur across an "unstirred" boundary layer [6]. For interpretation, the mass transfer and the subsequent chlorine reactions with the pipe material and the biofilm layers were described by first-order kinetics concerning bulk chlorine concentration [14].
(iii) Bacterial regrowth and substrate utilization in the bulk phase. The Monod formulation was applied to model the regrowth and substrate utilization of the suspended bacteria. Empirical expressions were incorporated to describe the chlorine inhibition and temperature influence on the growth reactions [8].
(iv) Biofilm formation against chlorine inhibition. A first-order approximation was selected to model the attached bacterial regrowth against chlorine inhibition to avoid representing the influence of the NOM in the biofilm layers on the biofilm dynamics. A resistance factor was incorporated into the empirical expression describing the chlorine inhibition to accommodate the greater resistance of the attached bacteria against the chlorine-induced inactivity [25].
(v) Mortality of bacteria and contribution to BDOC. The natural mortality of bacteria was modeled with first-order kinetics with an aim to simplify the complex processes associated with bacterial mortality by senescence and the grazing of bacteria by protozoa [5]. The chlorine-induced mortality was modeled with second-order kinetics based on the concept of competing reactions in water [11]. It was considered that 30% of the dead bacteria enriches the BDOC by releasing intracellular matter during cell lysis [5].
(vi) Attachment of bulk phase (suspended) bacteria on the pipe walls.
A first-order dependence on the suspended bacteria [26] and a zero-order reliance on the biofilm density were assumed to represent the deposition of the bulk phase bacteria on the biofilm to generalize the mass transfer of bacterial cells across the thin "unstirred" layer separating the bulk phase from the wall phase.
(vii) Detachment of attached bacteria due to the shear stress of water. The bacterial detachment from the biofilm layers was approximated to have firstorder dependence on the shear stress induced by the flow velocity [7] and the attached bacterial density [27].
(viii) THM formation due to the chlorination of TOC and suspended bacteria. The THM formation, caused by the chlorination of NOM, and bacteria-derived DBP precursors were modeled using the reaction yield coefficients [28].

Numerical Model
A set of advective-reactive (AR) equations (Equations (1)-(6)) were framed to describe the mass balance concerning the five species within the distribution pipes. The AR equation describes physical, chemical, and biological phenomena where concentrations of the five species under consideration were transformed inside water distribution pipes due to the combination of two processes: advection and reactions. Advective transport describes the movement of the five species in the fluid flow direction by virtue of the flow velocity inside the distribution pipes. The reactions include the equilibrium and kinetically controlled multispecies interactions explained before.
The base values of the parameters, selected based on a detailed review of the literature, are reported in Table 1. Equations (1)-(4) and Equation (6), corresponding to the bulk phase species, are partial differential equations, including the advection term and the multispecies interactions. Simultaneously, Equation (5), corresponding to the attached bacteria, is an ordinary differential equation representing the regrowth of biofilm within a reactor of zero mass flux. The diffusion to the biofilm layers from the bulk phase is neglected for TOC (Equation (2)), BDOC (Equation (3)), and THMs (Equation (6)) considering the associated uncertainty of the process and the practical difficulty to experimentally measure the NOM content and THM concentration in the biofilm layers.
At the nodes/junctions where two or more pipes meet, the mixing of the water parcels was assumed to be instantaneous and complete. After mixing, the water parcels leave these nodes with the flow-weighted average of concentrations coming from the incoming pipes. Thus, the concentration of the bulk phase species leaving the node at any time is shown in Equation (7), given below.
The notations used are: = concentration of any bulk phase species at node (mg/L); = number of incoming pipes at node ; = flow rate in pipe (L/s); = concentration of any bulk phase species inside pipe (mg/L); = length of pipe (m); = external source flow rate into node (L/s); = external source concentration of any bulk phase species at node (mg/L); = total number of nodes in the network. The complete mixing model [14] was selected at the storage tanks by assuming that all water parcels entering a tank are instantaneously and wholly mixed with the water parcels already present in the tank. This assumption makes modeling the temporal variations of the bulk phase species within the tanks quite simple as it requires no extra parameters to describe it. Additionally, it applies well to all the storage components that are operated in a fill-and-draw manner [35].

Model Implementation
Solving the set of mass-conservation equations (Equations (1)- (7)) will deliver the concentrations of the five model species at different values of and . In the present work, the EPANET-MATLAB toolkit [36], based on a MATLAB Class, "epanet", was utilized in this regard. The toolkit enables the operation of EPANET 2.0 and EPANET-MSX as shared object libraries for hydraulic and water quality modeling, respectively. Their dynamic link library (DLL) for Windows was used through the programming interface of MATLAB. Before using EPANET-MSX for water quality analysis, the EPANET 2.0 network (as. inp file format) was applied to simulate the hydraulic dynamics using the EPA-NET DLL and derive the flow/pressure values. The multispecies interactions in the form of model governing equations are described as .msx file formats. These were generated and implemented using the MATLAB interface. The dynamic multispecies water quality was then simulated by applying the EPANET-MSX DLL to derive the concentrations of the model species at pipes, demand nodes, and storage tanks. The default Lagrangian transport algorithm of EPANET 2.0 and EPANET-MSX was applied to solve the advective transport part of the model equations, and the fifth-order Runge-Kutta integrator with automatic time step control was utilized to solve the reaction part.

Test Problems
The applicability of the proposed MSRT model was demonstrated by applying it to two well-tested benchmark networks. The Balerma network [37] was selected as Test Problem 1. It is an adaptation of the irrigation network in the province of Almeria (Spain). The network has four reservoirs, 443 demand nodes, and 454 pipes. The Balerma network layout is given in Figure 2.
The second network (Test Problem 2) selected is the KLmod network [38], which is the modified version of the network proposed initially by [39]. KLmod is a single-sourced network consisting of 935 demand nodes and 1274 pipes, meeting the average demand of 29.1 million L/day. The schematic of the KLmod network is shown in Figure 3.

Test Conditions
The water quality analysis was performed at different operating conditions to elucidate the significance of the boundary conditions (source water characteristics) in determining the microbiological and chemical qualities of the delivered water at the demand nodes. Three scenarios (Scenarios 1a, 1b, and 1c) were selected for Test Problem 1 ( Table  2) by varying the chlorine concentration, NOM content, and the bacterial cell count of the treated water supplied from the four source nodes (Reservoir IDs 38, 43, 44, and 88). The free chlorine concentration was varied as 0.5, 1.0, and 2.0 mg-Cl/L and the TOC content was varied as 1.0, 2.0, and 3.0 mg-C/L. The source water with a TOC value of 1.0 mg-C/L corresponds to biologically treated water with minimum NOM content [40]. A TOC value of 3.0 mg-C/L represents water with possible organic pollution [11]. The bacterial cell count values in the source water are changed to 0.01, 0.1, 1.0, 10, and 100 CFU/mL to indicate different degrees of microbiological quality of the source water.  For Test Problem 2, four scenarios (Scenarios 2a, 2b, 2c, and 2d) were considered by varying the supplied water characteristics in the reservoir (Reservoir ID 1) ( Table 3). The free chlorine content was varied as 0.5 and 1.0 mg-Cl/L, and the TOC values were changed to 1.0 and 2.0 mg-C/L. The bacterial cell count was kept at 0.001 CFU/mL for all the scenarios. Such a very low value of bacterial cell count indicates the source water meeting the bacteriological quality requirements for direct human consumption. Water quality analysis was performed on Test Problems 1 and 2 under three and two scenarios, respectively, to test the proposed model's performance under non-chlorinated conditions. Scenarios 1d, 1e, and 1f (Table 2) are comparable to Scenarios 1a, 1b, and 1c, except that the chlorine concentration is zero at the four nodes. Similarly, Scenarios 2e and 2f (Table 3) for Test Problem 2 correspond to Scenarios 2a and 2b with chlorine concentration in Reservoir ID 1 as zero.
At zero chlorine concentration, the chlorine decay (Equation (1)) and THM formation (Equation (6)) modules of the MSRT model become inactive, and all the reaction terms in Equations (2)-(5) constituting chlorine except the term corresponding to bacterial regrowth and substrate utilization are converted to zero. Additionally, under non-chlorinated conditions, the term becomes 1, and the chlorine inhibition to the bacterial regrowth in the Monod formulation becomes nonexistent.
For the water quality analysis of both the problems, the BDOC content was assumed to be 30% of the TOC, and the THM concentration at the source nodes is deemed absent. The water temperature is considered as 25 °C. The analysis corresponding to all the scenarios mentioned above for Test Problems 1 and 2, using the proposed MSRT model, is performed with a time step of 300 s until 0.1% convergence in the values of all the reactive species (steady-state condition) is achieved in the nodes.

Results and Discussion
For Test Problem 1, with four source nodes, the average flow velocity inside the pipes and average water age at the demand nodes were 0.89 m/s and 1.02 h, respectively. For Test Problem 2, with a single source node, the average flow velocity inside the pipes was 0.19 m/s, and the average water age at the demand nodes was 7.2 h. Only <6% of the nodes of Test Problem 2 had water age value of less than 1 h, while at the same point in Test Problem 1 this was >47%. Four demand nodes of Test Problem 1 with Node IDs 1, 72, 265, and 403 with contributions from only one source node, i.e., Reservoir IDs 88, 38, 44, and 43, respectively, were selected to demonstrate the effects of the source water characteristics in determining the water quality. The water age in these four nodes was obtained as 1.33, 1.51, 1.13, and 1.67 h, respectively. To establish the impacts of water residence time in the water quality, five demand nodes (Node IDs 608, 387, 770, 1185, and 1319) of Test Problem 2 with water ages of 0.10, 2.76, 6.53, 14.60, and 25.71 h, respectively, were selected.

Effects of Source Water Characteristics
The steady-state values of bacterial cell count, chlorine concentrations, TOC concentrations, and THM concentrations in the four nodes of Test Problem 1 under Scenarios 1a, 1b, and 1c are shown in Figure 4.
The bacterial cell counts in the four nodes under the three scenarios varied between 5.3 and 1.4 × 10 4 CFU/mL. The results established the direct effects of free chlorine and organic substrate (BDOC) on the bacterial regrowth inside distribution pipes. Under Scenarios 1a and 1c, the increases in the bacterial counts in the delivered water at nodes 265 and 1 were found to be 2.75 log scale and 0.72 log scale, respectively (Figure 4a). This indicated the significance of the bacteriological quality of the source water in influencing the degree of bacterial regrowth under similar growth environments, which could be attributed to the first-order dependence of the bacterial concentration in the growth reaction term represented by Monod formulation in Equation (4). It was observed that the NOM degradation induced by bacteria (substrate utilization) was subservient when compared with its degradation caused by the reactions with available chlorine (Figure 4b,c). This could be related to the scales of the selected values of the parameters , , and . The observed results of THM concentrations in the four nodes (Figure 4d) indicated that the reactions between chlorine and NOM entirely influence the model predictions, and the role of bacterial-derived precursors in the dynamics of DBP formation is insignificant. The results specified the direct correlation between water age and bacterial regrowth inside distribution pipes. Under Scenario 2a, a continuous increase in the bacterial cell count from 0.001 to 183 CFU/mL was observed (Figure 5a). However, under Scenario 2b, the bacterial regrowth followed a downward trend after the water age value 14.60 h (Figure 5b). This could be attributed to the relative values of the reaction terms corresponding to regrowth and mortality in Equation (4). A 100% increase in the free chlorine concentration and 50% reduction in the TOC content under Scenario 2d, compared to Scenario 2c, effectuated a reversal of a 6.1 log scale increment in the bacterial activity to a 0.23 log scale decrement (Figure 5c,d). These results established the advantages of the effective regulation of the relative concentrations of chlorine and NOM in the supplied water to control the bacteriological quality in WDSs with relatively greater water age values. Nevertheless, a 60% increase in the THM concentration ( Figure 6) was observed between Scenarios 2c and 2d. This showed that the benefits of inhibiting the bacterial regrowth accomplished by increasing the chlorine concentration of source water are attained only at the expense of increased THM formation in the delivered water. Hence, it may be inferred that even under very low organic loading (TOC = 1 mg/L), an optimal selection of the chlorine dose may be essential to minimize the microbiological and chemical risks in the delivered water.

Water Quality Modeling in Non-chlorinated Systems
The proposed MSRT functioned well under non-chlorinated conditions for both Test Problems 1 and 2. As expected, the absence of free chlorine in water favored the bacterial regrowth in the delivered water (Figure 7). The maximum increment in the bacterial cell counts at the demand nodes of the Test Problem 1, under non-chlorinated conditions, was observed to be 0.73 log scale, 1.23 log scale, and 1.19 log scale, respectively, for Scenarios 1d, 1e, and 1f when compared with Scenarios 1a, 1b, and 1c (Figure 7a). Similarly, when compared with Scenarios 2a and 2b, the maximum increment in the bacterial cell counts in the demand nodes of test problems under Scenarios 2e and 2f was found to be 3 log scale and 3.47 log scale, respectively (Figure 7b). Nevertheless, the average comparative increments under the scenarios mentioned above for Test Problem 2 were obtained as 1.33 log scale and 1.20 log scale, respectively. This showed that in the absence of chlorine's inhibitory effects in water, the model predictions of bacterial regrowth under substrate loadings of 0.3 and 0.6 mg-C/L are comparable. This might be attributed to the magnitude of the value selected in the bacterial regrowth module. However, the NOM degradation in the water in the absence of free chlorine was subservient (Figure 8) compared to that in chlorinated water. This is partly attributed to the magnitude of the selected value of , and partly to the higher rates of the reactions between chlorine and organic matter in WDSs.

Deterministic Sensitivity Analysis Procedure
The proposed mechanistic MSRT model provides a framework to understand the interactions among chlorine, NOM, and bacteria in WDSs and predict the outcome of these interactions on the microbiological and chemical qualities of the delivered water. Even though all the model parameters can be derived through deterministic experimental investigations, the uncertainties in the state of knowledge about some of the mechanisms considered during the model formulation impede us from warranting deterministic predictions. Parameter sensitivity analysis becomes accordingly significant in this regard. This helps us to calculate the deviations in the model outputs in a localized region of the space of parameter inputs.
The simple deterministic sensitivity analysis procedure [41] was selected in this study for performing parameter analysis. The procedure is based on the idea of varying one uncertain model parameter at a time. The sensitivity is defined [12] as follows: where * is the normalized relative sensitivity coefficient or elasticity, is the state variable, is the model parameter of interest, and ∆ is the perturbation step. In the present work, ∆ value in Equation (8) was selected as 0.01, as suggested by [12]. The concentrations of suspended bacteria, chlorine, and THMs, which are the outputs of the bacterial regrowth module, chlorine decay module, and THM formation module, were selected as the state variables for conducting the parameter sensitivity analysis. In total, 17 parameters were selected, and the analysis was performed under all the scenarios mentioned in Tables 2 and 3 by increasing one parameter (out of 17 parameters) by 1% and keeping all other parameters at their base values. Using Equation (8), the normalized relative sensitivity coefficient values corresponding to the three state variables ( , , and ) mentioned above were determined at every demand node (and storage tanks, if any) for each time step under all the test conditions. The * values obtained at all the nodes for the entire simulation period were compared to select the maximum value of the sensitivity coefficient. The maximum values of * corresponding to the three modules, thus obtained, are reported as the sensitivity of a model parameter to the model outputs.

Sensitivity of Model Parameters
The parameter sensitivity analysis results for all the loading conditions (Tables 2 and  3) on Test Problems 1 and 2 are presented in Tables 4 and 5, respectively. The "+" and "−" signs associated with the * values indicate the increment and decrement, respectively. Interestingly, the * values were found to be highly dependent on the operating conditions. This shows the impact of the source water characteristics in determining the various multispecies reactions in WDSs and directing the sensitivity of the model outputs to the assumed parameter values. The reported results indicate that the network characteristics play a crucial part in controlling the scale of the * values. Out of the two problems considered, the * values were comparatively higher for Test Problem 2 than that for Test Problem 1. This could be attributed to the water residence time inside pipes in both the WDSs. The greater water residence times, caused by the low flow velocities, might have enhanced the interactions between the six reactive species within the system domain and influenced the bacterial regrowth in Test Problem 2 significantly more compared to that in Test Problem 1.

Parameter Sensitivity on Bacterial Regrowth Module Outputs
The * values corresponding to the bacterial regrowth module were relatively higher than the chlorine decay and the THM formation modules of the MSRT model. The average * values for , were obtained as 2.422 and 28.437 from the analyses conducted on Test Problems 1 and 2. The results confirm that the growth parameter , has the maximum * value out of the 17 parameters, hence it is most significant in determining the model predictions on microbiological quality. The , value +2.433 of the parameter , corresponding to Scenario 1a specified that the bacterial regrowth module output of the MSRT model would increase by 2.433% when the parameter , was increased by 1% from its base value while keeping all other parameters at their base values.
The analysis results revealed that the network characteristics significantly influence the order of sensitivity of model parameters on the bacterial regrowth module outputs. For Test Problem 1, and were the second most sensitive parameters, while for Test Problem 2, was the parameter most influencing the bacteriological activity after , . The parameters and defining the reactions between chlorine and bacteria were observed to have the same * values (Tables 4 and 5). Nevertheless, these two parameters were found to be insensitive ( * < 1) to the outputs of the chlorine decay module. This showed that the significance of these two parameters and their influence on the model outputs is governed by the second reaction term on the right-hand side (RHS) of Equation (4), describing the chlorine-induced mortality of the bulk phase bacteria. The growth parameter was observed to have a noticeable decrementing effect on the bacterial regrowth module predictions. This parameter controls the growth dynamics in the Monod kinetic formula.
The comparison of the * values corresponding to the reaction yield coefficients ( and ) and the reaction rate constants ( and ) concerning the outputs of the chlorine decay and bacterial regrowth modules helps present a clear image of the comparative importance of the chlorine reactions with NOM and bacteria in influencing the model predictions. The bacterial regrowth module outputs are more sensitive to and compared to the outputs of the chlorine decay module. This infers the significance of the second reaction term on the RHS of Equation (3) in governing the substrate utilization and bacterial activity, defined by the first reaction term in the RHS of Equation (4). The parameter , defining the effect of chlorine in inhibiting bacterial regrowth, was also found to have a prominent control over the bacterial regrowth module outputs and a decremental effect on the growth dynamics.
Interestingly, the parameter , describing the cell mass generation from unit substrate consumption, was insensitive ( * < 1) to the bacterial regrowth module outputs corresponding to Test Problem 1. However, it was found to have a noticeable influence (average * = 1.956) on the outputs from the analysis on Test problem 2. This could be attributed to the operating conditions and, more particularly, the substrate concentration and bacterial cell counts in the source water. The analysis of Test Problem 2 was carried out with comparatively lower bacterial cell counts ( 0 = 1 CFU/mL) in the source water. Consequently, the 1% increment in the value induced a more significant influence on the bacterial activity [42] in Test Problem 2 compared to that in Test Problem 1.
Another parameter that has shown marked influence on the bacterial regrowth module outputs is the parameter , defining the attachment (first-order kinetics) of the bulk phase bacteria on the biofilm layers. However, the detachment coefficient was found to be insignificant in influencing the bulk phase bacteriological activity predictions. Similarly, another parameter , , defining the biofilm growth dynamics, was also observed to be unimportant in regulating the model predictions on bulk phase bacterial concentrations. Altogether, the sensitivity analysis results give the impression that the model predictions of bacterial dynamics are most sensitive to the bulk phase growth reaction. The results also established that the biofilm parameters defining the bacterial interactions do not significantly control bulk phase microbiological quality predictions.

Parameter Sensitivity on Chlorine Decay Module Outputs
Overall, the * values corresponding to the chlorine decay module of the MSRT model were not significantly high. This indicated that the model predicted chlorine concentrations are not sensitive to most of the 17 parameters considered.
was the parameter most influencing the dynamics of chlorine decay. The parameter was observed to be the second most significant in determining the model predictions. It is interesting to note the slightly higher * values of the growth parameters ( , , , and ), particularly for Test Problem 2 (Table 5). This proves the importance of the first reaction term on the RHS of Equation (2) in controlling the dynamics of chlorine reactions defined by Equation (1).

Parameter Sensitivity on THM Formation Module Outputs
The * value corresponding to the parameter 1 was found to be 1, and for the parameter 2 , the same was obtained to be less than 0.001. It may be noted these two parameters only appear in the THM formation module (Equation (6)), and they have no impact on the outputs of the other five modules of the MSRT model (Equations (1)-(5)). Hence, it could be inferred that the share of the model predicted THM formation by the reactions between chlorine and bacteria-derived DBP precursors (second reaction term on the RHS of Equation (6)), in the total THM formation was less than 0.1% for all the scenarios tested. In other words, more than 99.9% of the model predicted THM formation corresponds to the reactions between chlorine and NOM. This explains the relatively trivial but obvious impact of the parameters linked with the NOM degradation on the outputs of the THM formation module. Nevertheless, other than for the parameters 1 , and , the * values of all other parameters were relatively small (Tables 4-5), and hence, their sensitivity on model predictions may be ignored.

Parameter Sensitivity under Non-chlorinated Conditions
The parameter sensitivity analysis revealed that the * values corresponding to the bacterial regrowth module for both Test Problems 1 and 2 under non-chlorinated conditions are comparable to those obtained under chlorinated conditions. Nonetheless, a noticeable increment in the * values corresponding to the parameter , was observed, specifically for Test Problem 1 (Table 6). This indicated that the sensitivity of the model predicted bacteriological quality on , increases in the absence of inhibitory effects of chlorine in the water. The parameters and were observed to be the second and third most significant parameters in influencing the outputs of the bacterial regrowth module. Interestingly, the variations in the * values of the model parameters under different operating conditions were relatively lower in the absence of free chlorine in water (Tables 4-6).
This could be attributed to the reduced influence caused by the lesser number of reaction terms in the model governing equations due to no chlorine being in the system domain. The higher BDOC concentrations observed under non-chlorinated conditions showed that the reactions of NOM with chlorine are more substantial in determining its degradation in water than its utilization as a substrate in the growth reactions of the bulk phase bacteria. The analysis results also established the insensitivity of the bacterial regrowth module outputs to the parameters defining the biofilm dynamics.

Limitations of the Study and Future Scope
The paper attempted to develop a generic, easy-to-use simulation engine to aid the WDSs design and operation. However, the proposed MSRT model utilizes the computing environment of EPANET-MSX, and hence, it is plagued with the numerical limitations of the Lagrangian transport algorithm. Further, the model is purely advective, and due to this reason, its pertinency in systems operated with low flow velocities may be re-examined. The model selects only one bacteria strain (Pseudomonas) to simplify the interpretations of microbiological interactions in the bulk and wall phases of the WDS. However, Pseudomonas cannot be recommended as the prototypical organism, representing the heterogeneous bacterial community in WDSs. Thus, incorporating more bacterial strains might be considered in the future to improve the applicability of the proposed model. The formation and transport of THMs are only considered in the present study. There may be other DBPs, inducing more severe carcinogenic and reproductive risks, which need to be included in the model formulation. A detailed experimental/field investigation may be required to understand and adjust the various model parameters. Future work aims to calibrate and validate the MSRT model for predicting the microbiological and chemical quality variations in real-world WDSs.

Conclusions
An EPANET-MSX based mechanistic MSRT model to predict the temporospatial variations of bacteriological and chemical qualities in WDSs was presented. The model applicability was demonstrated by applying it to two well-tested benchmark networks under both chlorinated and non-chlorinated conditions. The results established the model's suitability to be applied in WDSs operated with or without disinfectant chemical residuals. The direct effects of the effective regulation of chlorine and organic loading concentrations in the supplied water to control the bacterial regrowth and THM formation in WDSs were analyzed. In chlorinated WDSs, when operated with very low organic loading, the chlorine dose played an essential part in minimizing the chemical risks of the delivered water. The deterministic parameter sensitivity analysis revealed the impact of the operating conditions and the network characteristics in determining the extent of various multispecies reactions in WDSs and directing the sensitivity of the model outputs to the kinetic parameters. The analysis results established that the maximum specific growth rate constant for bulk phase bacteria ( , ) is most significant when defining the model predictions on bacterial dynamics in WDSs.

Data Availability Statement:
The data presented in this study are available on request from the corresponding author.

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