Dynamically adaptive networks for integrating optimal pressure management and self-cleaning controls

This paper investigates the problem of integrating optimal pressure management and self-cleaning controls in dynamically adaptive water distribution networks. We review existing single-objective valve placement and control problems for minimizing average zone pressure (AZP) and maximizing self-cleaning capacity (SCC). Since AZP and SCC are conflicting objectives, we formulate a bi-objective design-for-control problem where locations and operational settings of pressure control and automatic flushing valves are jointly optimized. We approximate Pareto fronts using the weighted sum scalarization method, which uses a previously developed convex heuristic to solve the sequence of parametrized single-objective problems. The resulting Pareto fronts suggest that significant improvements in SCC can be achieved for minimal trade-offs in AZP performance. Moreover, we demonstrate that a hierarchical design strategy is capable of yielding good quality solutions to both objectives. This hierarchical design considers pressure control valves first placed for the primary AZP objective, followed by automatic flushing valves placed to augment SCC conditions. In addition, we investigate an adaptive control scheme for dynamically transitioning between AZP and SCC controls. We demonstrate these control challenges on case networks with both interconnected and branched topology.


Introduction
The optimal design and control of water distribution networks (WDNs) is critical to maintain performance under increasing environmental, regulatory, and financial constraints. Advanced control structures and methods aim to satisfy multiple operational criteria, many of which are conflicting objectives with regard to network hydraulics. In this paper, we investigate the biobjective problem of integrating optimal pressure management and self-cleaning controls. These are important operational objectives linked to the reduction of leakage and discolouration risk in WDNs, respectively. However, high complexity and insufficient control capabilities have precluded the integration of pressure and water quality operational control schemes. Water companies are therefore seeking insights to inform design and control interventions for optimally integrating water quality as part of an overall control scheme.
Pressure management is a well-researched and implemented operational practice to lessen both the extent of background leakage and burst frequency in WDNs (Lambert and Fantozzi, 2010;Schwaller and van Zyl, 2015). Typical pressure management schemes consist of pressure control valves (PCVs) installed at the inlets to hydraulically isolated areas of a WDN. This type of network configuration is called a pressure managed area (PMA), in which PCV actuators modulate downstream pressure and flow is continuously monitored. Note that a PMA coincides with the practice of district metered areas (DMAs), but with pressure control capabilities. Since leak flow is a function of hydraulic pressure, the implementation of PMAs is a costeffective measure for reducing background leakage (Piller and van Zyl, 2014;Schwaller and van Zyl, 2015). For example, PMAs have been successfully implemented by the UK water industry in the last 25 years, acting as a key strategy within leakage management programmes (Ofwat, 2022). The problem of optimal design and control of PMAs has therefore been the focus of numerous studies in recent literature. These have commonly been formulated as minimization problems with average zone pressure (AZP) used as a surrogate for pressure induced leak flow (Wright et al., 2015). We present a review of such literature in Section 2.2.1. In practice, however, pressure management schemes often employ a relatively simplistic fixed-outlet mode of pressure control. This, in conjunction with kept-shut boundary valves, permanently sectorizes the network. One of many potential consequences of this pressure management scheme is the deterioration of water quality, often observed as an increase in discolouration incidents (Machell and Boxall, 2014;Wright et al., 2014;Armand et al., 2018).
Discolouration incidents are the leading cause of customer complaints in WDNs (Armand et al., 2017). Although a growing body of research has focused on the physical mechanisms leading to their occurrence (e.g. Boxall and Saul, 2005;van Summeren and Blokker, 2017;Armand et al., 2018;Braga et al., 2020), little proactive maintenance is currently performed in operational networks. Existing methods for mitigating discolouration risk include manual flushing programmes, during which water is flushed from a network through hydrants. Such flushing activity is resource-intensive and often performed in response to customer complaints. In addition to flushing being a costly operational activity, increasingly strict water quality regulations are making compliance measures more challenging for water companies. This is especially the case in the UK water industry, where the Drinking Water Inspectorate (DWI) enforce financial penalties for failure to comply with water quality performance targets (Drinking Water Inspectorate, 2020). Water companies are therefore seeking cost-effective and automatic control strategies to reduce the severity and frequency of discolouration risk. A control strategy of growing interest in both practice and academic literature is the concept of self-cleaning networks. This leverages the intrinsic connection between discolouration processes and hydraulic conditions (see review in Armand et al., 2018) by controlling peak diurnal flow velocities. More specifically, the strategy seeks to increase the distribution of velocities above a self-cleaning threshold so as to periodically re-suspend and flush accumulated material through the network (Vreeburg et al., 2009;Blokker et al., 2012). Recent studies have formulated this as an optimization problem, with decision variables comprising the placement of isolation valves (Abraham et al., 2018), the operational settings of PCVs (Abraham et al., 2016), and the placement and operational settings of PCVs and automatic flushing valves (AFVs) (Jenks et al., 2023). Note that AFVs are mechanical actuators which facilitate a controlled operational demand for flushing the network at hydrants or dedicated installations. These are increasingly deployed devices in operational networks and represent a key control actuator for improving SCC performance. We review the literature on optimizing SCC conditions in Section 2.2.2.
To facilitate the inclusion of multiple control objectives, Wright et al. (2014Wright et al. ( , 2015 introduced the operational framework of dynamically adaptive WDNs. This framework enables the dynamic re-configuration of network connectivity and hydraulic control to modulate flow and pressure. In this paper, we investigate the problem of integrating optimal pressure management and selfcleaning controls through the design and operation of dynamically adaptive networks. To the best of the authors' knowledge, the AZP-SCC bi-objective problem has not been considered in previous literature. Following a review of existing single-objective control strategies in Section 2, we present the two main contributions of this work. First, we propose a bi-objective framework for simul-taneously considering AZP and SCC objectives. The bi-objective problem extends the work suggested in Abraham et al. (2019) by jointly optimizing the placement and operation for both PCV and AFV actuators. This includes an investigation of a hierarchical design strategy, which first considers the placement of PCVs for the AZP single-objective problem, followed by AFVs for the SCC single-objective problem. We use the weighted sum scalarization method to formulate a sequence of parameterized single-objective optimization problems for approximating the AZP-SCC Pareto front. The problem formulation and solution methodology are presented in Section 3. Numerical experiments using two case networks demonstrate single-objective AZP and SCC results in Section 4.1 and trade-offs between objectives through approximated Pareto fronts in Section 4.2. These results aim to inform decision making for the design of PCV and AFV actuators that optimally integrate AZP and SCC objectives. In the second contribution, we investigate an adaptive control problem to facilitate the dynamic transition between AZP and SCC operational modes. The adaptive control problem considers only the operational settings of PCV and AFV actuators, assuming their placement is selected on the basis of the bi-objective problem results. Numerical experiments in Section 4.3 demonstrate the challenges in handling large nodal pressure variations that arise during the transition between AZP and SCC controls. We conclude with suggestions for future work to constrain maximum pressure and diurnal pressure variation in the AZP-SCC adaptive control problem.

Preliminaries and literature review
In this section, we review existing control strategies for optimal pressure management and selfcleaning operations. The reviewed approaches focus on computing the optimal locations and operational settings of pressure control and automatic flushing valve actuators. First, Section 2.1 reviews the hydraulic variables and conservation equations used to define the feasible solution space. We then present the motivation and mathematical formulations for pressure management and self-cleaning objective functions in Section 2.2.1 and Section 2.2.2, respectively. Following this, Section 2.3 describes the general single-objective valve placement and control problem formulation. Thereafter, a brief review of previously implemented solution methods for single-objective problems is included in Section 2.4. On the basis of this review, we identify opportunities and challenges for the integration of pressure management and selfcleaning control strategies in Section 2.5.

Hydraulic variables and constraints
We model a water distribution network (WDN) as a directed graph G(V, E) with |V | vertices comprising n n demand nodes and n 0 source nodes (e.g. reservoirs), and |E| edges comprising n p links. Network connectivity is represented through link-node incidence matrices A 12 ∈ R np×nn and A 10 ∈ R np×n 0 for demand and source nodes, respectively. The following convention is used to define A 12 (Todini and Pilati, 1988): The same convention is used to define incidence matrix A 10 for source nodes. Since link directions are defined a priori, any flows computed in the opposite direction are simply assigned a negative value.
We consider a steady-state hydraulic analysis over n t discrete time steps in an extended period simulation (EPS). For each time step t ∈ {1, . . . , n t }, known hydraulic conditions are given by vectors of nodal demands d t ∈ R nn and source hydraulic heads h 0 t ∈ R n 0 . Moreover, we include vectors η t ∈ R np and α t ∈ R nn to model local losses introduced across pressure control valves (PCVs) and operational demands at automatic flushing valves (AFVs), respectively. Unique vectors of hydraulic states q t ∈ R np and h t ∈ R nn are computed by solving the following energy (2a)-(2b) and mass (2c) conservation equations: where the vector of auxiliary variables θ t ∈ R np is introduced to isolate the nonlinear head loss model φ(q t ). The vector φ(q t ) = [φ 1 (q 1,t ) . . . φ np (q np,t )] T is defined in general form as The resistance coefficient r j and exponent n j take different values depending on the link type (e.g. pipe or valve) and on the head loss model used. For valve links, n j = 2 and where K j and D j are the valve loss coefficient and diameter, respectively (Larock et al., 1999). For frictional head losses across pipe links, the Hazen-Williams (HW) or Darcy-Weisbach (DW) formulae are commonly applied. In the HW model, n j = 1.852 and where C j is the HW coefficient, a dimensionless number representing pipe frictional characteristics; L j is pipe length; and D j is pipe diameter (Larock et al., 1999). When the DW formula is used, there exists an implicit relationship between q jt and r j , resulting in a continuously differentiable function for φ(q jt ). The reader is referred to Waldron et al. (2020) for details on formulating the DW model. While these models are ubiquitous in pipeline hydraulics, they both comprise nonsmooth terms (e.g. unbounded second order derivatives) and thereby present challenges for the use of state-of-the-art nonlinear optimization solvers. A smooth quadratic approximation (QA) for either the HW or DW model has been adopted in many WDN optimization studies (e.g. Eck and Mevissen, 2013;Pecci et al., 2019;Ulusoy et al., 2020). These approximations follow the methodologies presented in Eck and Mevissen (2015) and Pecci et al. (2017a), where a pair of coefficients (a j , b j ) are generated for each link to form the QA head loss model, Although the QA model is convenient for application in nonlinear optimization problems, it introduces errors in the hydraulic variables q t and h t . In many cases, these errors are small in comparison to the degree of uncertainty inherent in hydraulic models and thus do not materially impact the feasibility of the optimal solutions (Ghaddar et al., 2017;Pecci et al., 2017a;Ulusoy et al., 2022a). However, for optimization problems which aim to increase flows, such as the self-cleaning capacity problem (Abraham et al., 2016(Abraham et al., , 2018Jenks et al., 2023), the large range of flow values over which the QA model is defined may result in errors (Pecci et al., 2017a, Equation 21). Such QA errors need to be quantified and assessed to ensure they are within an acceptable tolerance.
The placement of valve actuators is modelled as follows. Binary variables z ∈ {0, 1} np model the placement of PCVs at network links. For each time step t ∈ {1, . . . , n t }, v + t ∈ {0, 1} np and v − t ∈ {0, 1} np assign pressure control capabilities in the positive or negative flow direction, respectively. Control is limited to a single direction at each time step t by the following constraint: v Moreover, binary variables y ∈ {0, 1} nn model the placement of AFVs at network nodes. Binary variables z and y are subject to the following physical constraints, which enforce the number of installed pressure control n v and flushing n f valves: We introduce constant vectors to define lower and upper bounds on continuous variables q t , h t , η t , θ t , and α t , such that, for all t ∈ {1, . . . , n t },

Objective functions
This section outlines the objective functions used in optimal pressure management and selfcleaning control problems. These represent surrogate measures for the actual operational conditions sought to be optimized.

Pressure management
The problem of optimal valve control for pressure management has been a subject of growing interest in the WDN optimization research community. This control problem seeks to reduce and maintain network pressures as close as possible to the minimum regulatory requirements in order to lessen the extent of background leakage and pipe circumferential stress (Schwaller and van Zyl, 2015). The network's average zone pressure (AZP) is commonly used as a surrogate for pressure induced leak flow, which is defined as follows (Wright et al., 2015): where h it is the computed hydraulic head for node i at time step t; ζ i is the elevation of node i; and w i is a coefficient weighting node i by the length of its connected links. That is, where I i is the set of links incident to node i;L = np j=1 L j ; and L ∈ R np is the vector of pipe lengths.
In addition to reducing the mean operating pressure, recent studies have highlighted the influence of nodal pressure variation on the probability of pipe failure (Rezaei et al., 2015;Martínez-Codina et al., 2016;Jara-Arriagada and Stoianov, 2021). Accordingly, efforts have been made to introduce pressure variability (PV) as an objective within pressure management strategies. On the basis of PV indicators posed in Martínez-Codina et al. (2016), Pecci et al. (2017b) defined the PV objective function as the sum of squared differences between nodal heads h t and h t−1 , as follows: In demonstrating the impacts from optimal AZP valve control (i.e. flow modulation curves), Wright et al. (2014) reported an increase in nodal pressure variability when compared with a fixed-outlet pressure management strategy. This suggested that AZP and PV are conflicting objectives and therefore cannot be simultaneously optimized. To this end, Pecci et al. (2017b) investigated trade-offs between AZP and PV through a bi-objective problem formulation. The authors applied different scalarization methods to generate the set of Pareto optima. In this work, we introduce PV as a critical metric to consider a posteriori when implementing control schemes in operational WDNs. We discuss these challenges further in Section 4.3.

Self-cleaning capacity
Reducing discolouration risk is increasingly becoming a key priority in water quality management programmes. Since conventional discolouration risk reduction practices are infrequent and resource-intensive (e.g. manual flushing), there have been recent forays in the design and operation of self-cleaning networks (Blokker et al., 2012). Adapted from Vreeburg et al. (2009), the self-cleaning capacity (SCC) is defined as the percentage of the network (by pipe length) routinely experiencing flow velocities above a threshold adequate to mobilize accumulated particles. Previous optimization studies have used SCC as a surrogate for discolouration risk, which is defined as follows (Abraham et al., 2016(Abraham et al., , 2018Jenks et al., 2023): where q jt is the computed flow conveyed by link i at time step t; A j is the cross-sectional area of link j; and κ j (·) is an indicator function which models the state of pipe velocities with reference to a minimum threshold. The indicator function described for link j ∈ {1, . . . , n p } as where u min j represents the minimum threshold velocity at link j (see Jenks et al., 2023). Moreover, a weighting w j normalizes the length of link j to the entire network, Because (14) is nonsmooth at ±u min , Abraham et al. (2016) proposed an approximation of κ(·) using a smooth sum of sigmoids (or logistic) function. The sum of sigmoids function is defined by positive and negative components, ψ + j (u) := (1 + e −ρ(u−u min j ) ) −1 and ψ − j (u) := (1 + e −ρ(−u−u min j ) ) −1 , respectively, where parameter ρ sets the sigmoid function curvature. A smooth approximation of (14) is then defined as to which gradient-based optimization methods can be applied.
Although water quality has been the objective of numerous studies in the WDN optimization literature (see Mala-Jetmarova et al., 2017), little research has focused on maximizing SCC to reduce discolouration risk. In Abraham et al. (2016), a single-objective optimization problem was formulated to maximize SCC through optimal control valve settings. Similarly, Abraham et al. (2018) redistributed flow by optimizing isolation valve closures through a linear graph analysis tool. The developed algorithm was shown to outperform an empirical strategy where valve closures were based on engineering judgment. More recently, Jenks et al. (2023) formulated a novel design-for-control problem where locations and operational settings of PCV and AFV actuators were jointly optimized to maximize SCC. Section 2.3 presents the general valve placement and control problem formulation.

Valve placement and control problem formulation
The single-objective valve placement and control problem aims to minimize AZP (Section 2.2.1) or maximize SCC (Section 2.2.2), subject to hydraulic modelling constraints and economical valve placement constraints (Section 2.1). The corresponding mixed integer nonlinear programming (MINLP) problem is written as which is described as follows. First, f (x) in (17a) denotes the objective function, set to either AZP (11) or the additive inverse of SCC (16) in this study. Matrix A is defined so that the rows of (17b) correspond to the vector of auxiliary variables θ t ∈ R np . Moreover, φ(·) is a nonlinear function representing the frictional head loss model, as described in Section 2.1. The set V is defined by linear valve placement constraints (7) and (8a)-(8b).
..,nt . Finally, while the maximization of SCC can involve the installation of both PCVs and AFVs, flushing is not considered as an operational activity for pressure management. As a result, the formulation of valve placement and control problems for the minimization of AZP is generally restricted to the placement and control of PCVs (i.e. y = 0 nn ).
Following the notation in Eck and Mevissen (2013), we denote Problem (17) as VP-MINLP, which comprises both binary and continuous variables. Its solution represents the optimal placement and operational setting of PCV and AFV (if applicable) actuators. Moreover, we denote VC-NLP as the control-only subproblem of VP-MINLP. Here, decision variables include only optimal operational settings, while binary variables v, y and z are fixed to a given valve placement configuration, making Problem (17) a nonlinear programming (NLP) problem. VP-MINLP and VC-NLP are nonconvex optimization problems, where sources of nonconvexity include the frictional head loss model φ(·) in (2a) and, for the self-cleaning problem, the sigmoidal SCC objective function in (16).

Single-objective solution methods
Previous literature has solved VP-MINLP using both metaheuristic and mathematical optimization methods. Metaheuristic approaches have included genetic algorithms (e.g. Reis et al., 1997;Araujo et al., 2006;Creaco and Pezzinga, 2015;Covelli et al., 2016), harmony search (e.g. De Paola et al., 2017), and particle swarm optimization (e.g. Dini and Asadi, 2020). In order to comply with hydraulic constraints, these methods employ an external hydraulic solver (e.g. EPANET; Rossman et al., 2020) to evaluate the computed valve locations and settings. Mathematical optimization methods, on the other hand, embed the hydraulic equations as constraints within the optimization problem. These methods have included local optimization algorithms (Dai and Li, 2014;Pecci et al., 2021Pecci et al., , 2022aJenks et al., 2023) as well as global solvers (Eck and Mevissen, 2013;D'Ambrosio et al., 2015;Ghaddar et al., 2017;Pecci et al., 2019), where the latter provide certified optimality bounds for the computed feasible solutions. This review focuses on heuristic methods developed to compute feasible solutions to largescale MINLP problems. In particular, we consider the solution algorithm proposed in Jenks et al. (2023) for solving the SCC design-for-control problem. This algorithm comprised convex relaxations, a randomization heuristic, and a multi-start NLP solver to compute feasible solutions to VP-MINLP. Moreover, an optimization-based bound tightening (OBBT) scheme (Belotti et al., 2009) was implemented to strengthen the convex relaxations. The algorithm extended the convex heuristic implemented in Pecci et al. (2022a) to include the nonconvex SCC objective function (14) and AFVs as control actuators. Figure 1 provides an overview of the solution algorithm. The reader is referred to Jenks et al. (2023) for further details on the algorithm's implementation. Furthermore, we note that few studies have considered bi-directional (dynamic) boundary valves as control actuators in the optimization problem, which is essential for the design and operation of dynamically adaptive networks. Following Jenks et al. (2023), Problem (17) permits bi-directional operation of control valve actuators through the set of binary variables v t ∈ {0, 1} 2np . As defined in Section 2.1, v t can take either positive or negative control direction for each time step t ∈ {1, . . . , n t }, v t . An enumeration approach was implemented to test all control direction combinations for a given valve configuration in the VC-NLP subproblem. That is, v t was fixed and VC-NLP was solved for M = 2 nv control direction combinations. Alternatively, Ulusoy et al. (2022b) formulated VP-MINLP with binary variables v ∈ {0, 1} 2np fixed in time t.

Input
A bi-linear constraint was then required to constrain q t and η t to the same direction at control valve links. Moreover, Ulusoy et al. (2022b) relaxed the resulting complementarity conditions on q t and η t by introducing an auxiliary variable. VP-MINLP and VC-NLP were then reformulated with a parametrized penalty term in the objective function.
For a feasible valve placement configuration (v, y, z), the solution to VC-NLP provides a feasible (upper bound) solution of the aforementioned VP-MINLP. In addition, its solution is central to control scheduling problems where valve locations are known a priori and only operational settings are optimized. In recent literature, two local solvers have been implemented to compute feasible solutions to VC-NLP: the state-of-the-art nonlinear solver IPOPT (e.g. Eck and Mevissen, 2013;Dai and Li, 2014;Ghaddar et al., 2017;Pecci et al., 2019;Nerantzis et al., 2020;Ulusoy et al., 2020); and a sequential convex programming (SCP) algorithm (e.g. Wright et al., 2014Wright et al., , 2015Abraham et al., 2016;Jenks et al., 2023). Application of these NLP solution algorithms have varied by problem formulation. For example, second-order derivatives, which are required for IPOPT, may not be well defined for some decision variables (e.g. roughness coefficients for model calibration in Waldron et al., 2020). In these cases, a tailored SCP algorithm has been used. The SCP algorithm comprises gradient-based optimization and a trust-region or line search strategy to evaluate solution progress. Furthermore, IPOPT can readily handle additional problem constraints, whereas SCP requires a tailored approach for each problem formulation to move from the current point x k to a new iterate x k+1 in the solution process.

Opportunities and challenges
The problem of integrating pressure management and self-cleaning controls has not been extensively investigated in the literature. This problem is particularly relevant as AZP and SCC have been identified as conflicting operational objectives (Abraham et al., 2016Jenks et al., 2023). Consequently, we have identified the following research opportunities and challenges, which we study in this paper.
• Bi-objective valve placement and control problem. While AZP and SCC have been identified as conflicting objectives, an in-depth analysis of their trade-offs has not been performed for the valve placement and control problem. An investigation should assess the degree to which AZP and SCC are conflicting, especially when AFVs are considered as control actuators for the SCC problem. Moreover, the Pareto front should be approximated to evaluate the compromises between operational objectives.
• Integrated control scheduling problem. With valve actuators placed, the problem of integrating AZP and SCC controls within a control scheduling programme needs to be addressed. Since self-cleaning is a periodic mode of operation, optimal SCC controls may be implemented over a specific (and known) period. Otherwise, AZP can be considered the main (or continuous) operational objective.
The remainder of this paper is structured as follows. First, we formulate the bi-objective valve placement and control problem in Section 3. We apply the weighted sum scalarization method to approximate the Pareto optimal set (or Pareto front) between AZP and SCC objectives. In Section 4, we perform numerical experiments to demonstrate the AZP-SCC trade-offs for two case networks. Finally, we present a preliminary investigation of an adaptive control scheme for integrating AZP and SCC control modes.

Bi-objective valve placement and control
This section formulates a bi-objective optimization problem to investigate the trade-offs between AZP and SCC. In doing so, we aim to search for optimal compromises between operational objectives, thereby informing decision making for the design and control of dynamically adaptive WDNs. This bi-objective problem extends the problem initially suggested in Abraham et al. (2019) by introducing AFV actuator placement and control as decision variables. Note that AFVs are intended to replace (or complement) manual flushing practices. As a result, unlike pressure induced leakage, we do not consider the water discarded from the operation of AFVs as a form of undesirable water loss.
Using the same variable definitions in (17), we formulate the bi-objective problem as where f 1 and f 2 represent either AZP or −SCC. Following the notation in Section 2.3, we denote Problem (18) as VP-BOMINLP and the bi-objective problem for a fixed valve configuration as VC-BONLP.
In this work, we implement the weighted sum (WS) scalarization method to approximate the Pareto front (or non-dominated set) of VP-BOMINLP. This is one of the most widely used scalarization method in the multi-objective optimization literature (Miettinen, 1998;Ehrgott, 2006). However, a known limitation of the WS scalarization method is its inability to generate points in the nonconvex parts of the Pareto front (Das and Dennis, 1997). To this end, future work might investigate other scalarization methods to convert the bi-objective problem into a series of parametrized single-objective problems -e.g. Chebyshev or -constraint schemes (Ehrgott, 2006). We reformulate VP-BOMINLP as a sequence of parametrized single-objective problems. The solutions of these single-objective problems define the set of Pareto optima of VP-BOMINLP, with its image in the objective space representing the approximated Pareto front. Since VP-BOMINLP is nonconvex, the Pareto front is defined only by local optima to the single-objective VP-MINLP problems. Here, such local optima to the single-objective problems are computed using the convex heuristic described in Section 2.4. Let x * i be the set of continuous variables that minimizes objective f i . It follows that f (x * i ), i = 1, 2, denote the anchor points on the Pareto front. Moreover, f u := [f 1 (x * 1 ), f 2 (x * 2 )] T is the utopia point, which has values that simultaneously minimize both objective functions; by definition, f u is not a feasible solution to VP-BOMINLP. The objective functions are normalized using the utopia point and respective anchor points, as follows: For ω ∈ [0, 1], we then consider the WS problem formulation VP-MINLP WS (ω): The Pareto front is generated by solving a sequence of parametrized problems VP-MINLP WS (ω) for a given set of weights ω. In Section 4.2, we compute points on the Pareto front for n = 10 evenly distributed weights in the domain [0, 1].

Numerical experiments
Numerical experiments reported herein were performed in Julia 1.8.2 (Bezanson et al., 2017) with optimization solvers accessed via JuMP 1.4.0 (Dunning et al., 2017). All computations were performed within the Ubuntu 20.04.5 LTS Linux distribution on a 2.50-GHz Intel(R) Core(TM) i9-11900H CPU with 8 cores and 32.0 GB of RAM. Linear programs were solved using Gurobi 9.5.2 (Gurobi Optimization, 2022). Nonlinear programs were solved using IPOPT 3.14.4 (Wächter and Biegler, 2006) installed with the HSL MA57 linear solver (HSL, 2021). We consider two case networks in this study: Modena and BWFLnet. Modena is a reduced version of the hydraulic model for a medium-sized Italian city and is a well-established benchmarking network in the literature (Bragalli et al., 2012). Modena consists of n n = 268 demand or junction nodes, n p = 317 links, and n 0 = 4 source nodes. Moreover, it is modelled over n t = 24 hourly discrete time steps. It has a highly interconnected (looped) network topology and large demands, representative of flows typically conveyed at the transmission level. Its layout is shown in Figure 2a. In comparison, BWFLnet is a large-scale operational network in the UK, which is jointly operated by Imperial College London, Bristol Water Plc, and Cla-Val Ltd (Wright et al., 2014). BWFLnet is a unique smart water network demonstrator, enabling the dynamically adaptive control of network topology and hydraulic conditions. It has been used as a case network in numerous optimization and control studies (e.g. Wright et al., 2014Wright et al., , 2015Pecci et al., 2019;Nerantzis et al., 2020;Pecci et al., 2022a;Jenks et al., 2023). The BWFLnet network used in this study consists of n n = 2, 745 demand or junction nodes, n p = 2, 816 links, and n 0 = 2 source nodes. It is modelled over n t = 96 15-minute discrete time steps. In contrast to Modena, BWFLnet represents an operational network with branched topology (i.e. little redundancy in connectivity). Moreover, its demands represent water consumption in a typical UK urban area as opposed to the aggregated demands consistent with the magnitude of flows at the transmission level. The BWFLnet layout is shown in Figure 2b. Together, these case networks represent varied network conditions to demonstrate the investigated AZP-SCC control challenges.
The following assumptions are adopted for both single-and bi-objective optimization problems. Frictional head losses are modelled using the HW equation and the known roughness coefficients from each network model. The minimum pressure head is set to 15 m at demand nodes and 0 m otherwise. Moreover, the maximum flushing rate is set to 25 L/s at AFV nodes, which corresponds to the recommended fire flow capacity at hydrants in the UK (Local Government Association and Water UK, 2007). For the approximated SCC objective function in (16), we set the sigmoid curvature parameter ρ = 50 and the self-cleaning velocity threshold u min j = 0.2 m/s for all j ∈ {1, . . . , n p }. The selected velocity threshold u min j references experimental findings reported in the literature (Ryan et al., 2008;Blokker et al., 2010). No existing PCV or AFV actuators are considered for the single-and bi-objective design-for-control problems in Section 4.1 and Section 4.2, respectively. However, the adaptive control scheme investigated in Section 4.3 assumes a known valve configuration. Furthermore, we apply a modified version of the convex heuristic from Jenks et al. (2023) to compute feasible solutions to the single-objective VP-MINLP problem. Here, the state-of-the-art NLP solver IPOPT is used in place of the sequential convex programming algorithm. We note that, in contrast to that reported in Jenks et al. (2023), no infeasibility errors were observed when using IPOPT 3.14.4 (accessed via JuMP) for the current study. Moreover, only one starting point is tested when  solving VC-NLP, corresponding to the valve settings returned by the solution of the convex relaxation in VP-MINLP (see Figure 1). Finally, hydraulic equations (2a)-(2c) are solved using the null space solver developed by Abraham and Stoianov (2015).

Single-objective optimization
We first compute feasible solutions to VP-MINLP for individually optimizing AZP and SCC in Modena and BWFLnet. We consider the formulation of (17) for valve configurations comprising n v ∈ {1, 3, 5} PCV and n f ∈ {0, 2, 4} AFV actuators. These results seek to find the best number of n v and n f control actuators for consideration in the bi-objective problem formulation. Furthermore, the objective values of the solutions to the single-objective problems are used to normalize the objective functions in the weighted sum scalarization method. We note that, in practice, AFVs are not considered as part of a pressure management programme. However, they are included as valve actuators in the single-objective AZP problems to support the biobjective problem formulation. This is primarily because the AZP-SCC bi-objective problem formulation in Section 3 requires a pre-defined valve configuration, of which considers both PCV and AFV actuators. Figure 3 presents the optimal valve placement and control results individually obtained for AZP and SCC in case networks Modena and BWFLnet.
We observe a reduction in AZP of approximately 23% for Modena and 38% for BWFLnet between problem instances with n v = 1 and n v = 3 PCVs. However, in both networks, additional benefits appear to diminish for the case with n v = 5. These results are generally in accordance with previous studies concerning optimal valve placement and control for minimizing AZP . Accordingly, we assume the valve configuration corresponding to n v = 3 to represent the most economical design decision of the evaluated problem instances. The addition of AFV actuators had varying levels of influence on AZP performance. For cases with n v > 1, flushing demands showed little-to-no improvements in Modena. On the other hand, a noticeable reduction in AZP is discerned for problem instances with AFVs in BWFLnet. This observation can be attributed to the additional head losses materializing from flushing demands, particularly in areas of the network where elevation or hydraulic distance inhibits pressure modulation from PCVs. As noted previously, we include the AZP problem results   with AFV actuators to support the AZP-SCC bi-objective problem formulation. Results for the single-objective SCC problem indicate that the optimal placement and control of AFV actuators deliver the greatest benefits for improving self-cleaning performance. In the absence of flushing, SCC improvements are achieved via changes in network connectivity and pressure modulation at PCVs. Such dynamic changes in connectivity enable the redistribution of flow to maximize self-cleaning velocities. This is most evident in the highly interconnected (looped) topology of Modena, where problem instances of n v > 1 show a noticeable improvement (roughly 20%) in SCC performance. On the other hand, the branched topology of BWFLnet limits control on the distribution of flow, as demonstrated by the relatively small increase in SCC performance for the problem instance of n v = 5. Moreover, we generally observe an increasing relationship between SCC performance and the number of AFVs considered in the problem formulation (n f ). This is to be expected for highly branched networks as the influence of flushing demands is limited to the upstream flow path.
On the basis of these results, we consider the valve configuration of n v = 3 and n f = 4 for the bi-objective problems investigated in Section 4.2. Table 1 compares the AZP and SCC objective values resulting from their respective optimal valve configurations (i.e. anchor points for the bi-objective problem formulation). As expected, these objective values show significant differences between anchor points for both Modena and BWFLnet. This confirms the conclusions  Abraham et al. (2016Abraham et al. ( , 2019; Jenks et al. (2023) that AZP and SCC are indeed conflicting objectives. However, an analysis of their trade-offs is needed to determine if an acceptable compromise between objectives can be achieved. To gain a better understanding of these conflicts, we first review the corresponding optimal valve locations for the individual AZP and SCC problems, which are shown in Figure 4. We observe optimal PCV locations for both AZP and SCC problems to be near the source nodes (e.g. reservoirs) in the looped Modena network. In contrast, PCV locations are quite different in the more branched BWFLnet network, which show a cluster of PCVs for the SCC problem. This might suggest less marked trade-offs between AZP and SCC in Modena compared to BWFLnet. On the other hand, no clear pattern is discerned for optimal AFV locations. Future work is needed to further investigate the influence of network topology and valve placement.

Bi-objective optimization
In this section, we investigate the trade-offs between AZP and SCC objectives through the notion of Pareto optimality. This is intended to inform design decisions for the placement and operation of PCV and AFV actuators. In particular, we propose a hierarchical design strategy that leverages the locations of optimal valve actuators from the single-objective AZP and SCC problems presented in Section 4.1. For the AZP-SCC bi-objective problem formulated in Section 3, we implement the weighted sum (WS) scalarization method to compute the set of Pareto optima for n = 10 evenly distributed weights in the domain [0, 1]. Feasible solutions to the resulting sequence of single-objective optimization problems are computed using the convex heuristic described in Section 2.4. Since (18) is nonconvex, the WS scheme generates an approximation of the Pareto front to the bi-objective problem. We discuss the benefits and limitations of the solution method in the subsequent results, particularly in relation to the nonconvexity of the considered problems. We compute approximated Pareto fronts for two bi-objective problem cases. The main case considers a valve control bi-objective NLP (VC-BONLP) problem, which has a known valve configuration corresponding to a hierarchical design strategy. We formulate VC-BONLP by fixing valve actuator locations using the single-objective results presented in Section 4.1. More specifically, we set the locations of PCVs based on the solution of the single-objective problem minimizing AZP. Then, with PCVs already configured, we set the locations of AFVs based on the solution of the single-objective problem maximizing SCC. Since the single-objective results demonstrate that AZP and SCC depend strongly on PCV and AFV controls, respectively, we test the hypothesis that this hierarchical design strategy can yield sufficient performance for both objectives. Additionally, we consider the design-for-control bi-objective problem (VP-BOMINLP), where valve locations and operational settings are jointly optimized. The solution to VP-BOMINLP aims to qualify the results obtained for VC-BONLP and demonstrate the trade-offs between AZP and SCC for different valve configurations.
The following notation is used for presenting the bi-objective results. We denote the set of solutions computed by the WS method for VP-BOMINLP and VC-BONLP as P andP, respectively. Using the Pareto filter proposed in Messac et al. (2003), we then identify the nondominated subset of these solutions, which we denote as P N DS ⊆ P andP N DS ⊆P. These nondominated sets approximate the Pareto front of the respective AZP-SCC bi-objective problems. The resulting Pareto fronts approximated for VP-BOMINLP and VC-BONLP problems with n v = 3 and n f = 4 are shown in Figure 5. Observe that the Pareto fronts are fairly uniform and well-spread, suggesting that the WS scalarization method and selected weights are sufficient for evaluating trade-offs between objectives.  Figure 5 illustrates the trade-offs between AZP and SCC for the evaluated networks. For both Modena and BWFLnet, we observe that the sets P N DS andP N DS describe relatively flat Pareto fronts progressing from the AZP anchor point in the bottom left corner, before incurring a noticeable increase in AZP in order to achieve conditions near the SCC anchor point. The selection of solutionp * ∈P N DS , denoted by the red square in Figure 5b and Figure 5a, highlights that significant improvements in SCC can mostly be achieved for only moderate increases in AZP. Moreover, this behaviour is more more pronounced in BWFLnet, where the zone of influence of PCV actuators can be limited by the branched topology of the network (as shown in Figure 4b). The looped topology of Modena, on the other hand, results in a wider area of the network affected by pressure modulation. Therefore, the trade-off in AZP is less marked when achieving hydraulic conditions corresponding to the SCC anchor point. Furthermore, we observe that some solutions returned by WS for VP-BOMINLP and, to a lesser extent, VC-BONLP are largely dominated by others. This is especially prevalent for the solutions of scalarized problems corresponding to larger SCC weights, for which the likelihood of computing suboptimal local solutions is increased by the greater degree of nonconvexity of the SCC objective compared to AZP. This phenomenon is applicable to both VP-BOMINLP and VC-BONLP problems and could potentially be mitigated through a more robust solution methodology -e.g. multi-start approach proposed in Jenks et al. (2023).
Finally, we compare Pareto fronts of VC-BONLP and VP-BOMINLP. As expected, we observe an acceptable range in objective function values when PCV and AFV actuator locations are fixed according to the aforementioned hierarchical design. This highlights the strong dependence of each valve actuator on their respective operational objectives. Figure 5a shows a small optimality gap between VC-BONLP and VP-BOMINLP anchor points for Modena. In comparison, Figure 5b reveals slightly larger deviations between approximated Pareto sets P N DS andP N DS for BWFLnet. In particular, we observe an 8 m difference in AZP values between the anchor points in the bottom left corner. Although this signifies a noticeable optimality gap between VC-BONLP and VP-BOMINLP, we note that flushing is not considered as an operational activity for pressure management. Therefore, a more reasonable comparison of AZP performance is with the single-objective problem instance of n v = 3 and n f = 0 in Figure 3c, which yields similar performance to the setP N DS .
The generated Pareto fronts allow an operator to (i) visualize the conflicting nature of AZP and SCC objectives and (ii) quantify such trade-offs to inform decision making for designing WDNs for the simultaneous control of pressure and water quality. In particular, we observe that a hierarchical design strategy (Problem VC-BONLP) yields good trade-offs between AZP and SCC objectives by varying actuator settings for pre-defined valve locations. In this approach, PCVs are first optimally placed to minimize AZP. Then, using these PCV locations, AFVs are placed to augment SCC conditions in the network. Informed by the Pareto front of VC-BONLP, valve actuator settings can be selected to balance the trade-offs between objectives. This, however, considers a static operational point for integrating AZP and SCC controls. In contrast to this approach, previous literature has suggested the occurrence of a daily (or every other day) self-cleaning period to be sufficient for mitigating discolouration risk in WDNs (Vreeburg et al., 2009;Blokker et al., 2012). On this basis, we describe a control scheme that facilitates the dynamic transition between AZP and SCC controls in Section 4.3.

Adaptive control scheme
This section investigates the second research problem identified in Section 2.5: an integrated control problem for reducing AZP and increasing SCC in operational networks. We formulate an adaptive control scheme as a sequence of single-objective problems, whereby control modes are switched at pre-defined periods. This follows a similar approach to the model predictive control (MPC) scheme proposed in Nerantzis and Stoianov (2022), which sought to adapt network hydraulics for fire fighting activity. For integrating AZP-SCC controls, however, we assume known periods for switching between operational modes, thereby facilitating proactive network self-cleaning maintenance. Furthermore, since background leakage is a continuous phenomenon occurring throughout the network (see review in Section 2.2.1), we set AZP as the primary (or master) control mode and SCC as the secondary (or service level) control mode. We consider SCC as a special operational mode that is activated across a pre-defined 1-hour period for a 24-hour simulation.
We demonstrate an example of preliminary results via a time series plot in Figure 6 for BWFLnet. Here, SCC controls are optimized during the peak demand period (e.g. 09:30h to 10:30h), with AZP optimized across all other periods in the 24-hour simulation. As discussed in Section 4.2, we optimize PCV actuators for both AZP and SCC control modes and AFV actuators for only the SCC mode. This adaptive control scheme enables the integration of pressure management controls, whilst facilitating a self-cleaning mode to reduce discolouration risk. Note that each time step in Figure 6 represents a 15-minute period.
As expected, we observe a relatively large increase in AZP when activating optimal SCC controls. These conditions are commensurate with the SCC anchor point shown in Figure 5b. The transition between control modes therefore result in a wider range in pressures across the network. While the instantaneous pressure changes would be smoothed by the settings Figure 6: Time series of AZP-SCC adaptive control scheme during peak demand in BWFLnet.
of PID (Proportional-Integral-Derivative) controls at the device level, the network's physical infrastructure would still experience cyclic loading due to daily variations in pressure. Recalling the literature review in Section 2.2, the frequency and range of nodal pressure variation has been established as a potential influence on pipe failure rates. Consequently, maximum pressure and pressure variability needs to be constrained within acceptable bounds when implementing such adaptive control schemes. To get a better understanding of the potential range in nodal pressure, we evaluate conditions resulting from different SCC activation periods. Figure 7 compares three such control scenarios simulated in Modena and BWFLnet: (i) minimization of AZP only, (ii) adaptive AZP-SCC scheme with switch to SCC maximization during peak demand, and (iii) adaptive AZP-SCC scheme with switch to SCC maximization at the minimum demand period. These are conveyed through cumulative distribution plots of the range in nodal pressure variation. Note that the AZP-only control scenario represents a baseline condition for purposes of comparison.
For Modena, the activation of SCC controls at peak demand, relative to the AZP-only scenario, results in an increased pressure variation of 5 m to 10 m in approximately 60% of model nodes. In comparison, we observe most nodes to have similar conditions between the AZP-only and minimum hour control scenarios, indicating less overall stress on the network. While not shown here for the sake of brevity, there is a modest decrease in SCC performance when implementing optimal SCC controls over the minimum demand hour compared to peak demand. This suggests an additional trade-off exists between SCC performance and nodal pressure variation. For BWFLnet, implementing optimal SCC controls at peak demand results in less pressure variation over the entire set of model nodes, compared to maximizing SCC over the minimum demand hour. Reviewing the optimal controls more closely, we note that flushing demands are higher at the minimum demand hour than in the peak demand scenario. Moreover, there are larger pressures at source nodes under minimum demand conditions, which results in a wider allowable pressure range in relation to the minimum regulatory pressure head. The difference in pressure variation for BWFLnet is therefore influenced by many network and operational specific factors. In any case, we indeed observe an increase in pressure variation compared to the AZP-  only scenario, which is on the order of approximately 10 m to 15 m. We note that there is also a modest reduction in SCC performance in BWFLnet when optimal SCC controls are implemented over the minimum demand period.
These findings demonstrate that increased nodal pressure variation arises from integrating AZP and SCC control modes. Since this represents a cyclic load on the network's physical infrastructure, future work might consider formulating an adaptive control problem constraining maximum pressure and pressure variability. However, this can be difficult to solve for large problem instances since the pressure variation metric adopted in Section 2.2.1 links hydraulic conditions between time steps. To this end, decomposition methods might be well suited to separate the large-scale problem into smaller sub-problems that can be solved efficiently. Furthermore, quantifying the impact of pressure variation on pipe burst rates is not well understood. Accordingly, further research is needed to consider a maximum allowable pressure variation in the implementation of such control problems.

Conclusions
We have investigated the problem of integrating optimal pressure management and self-cleaning operations in dynamically adaptive water distribution networks. The considered objectives are the minimization of average zone pressure (AZP) for reducing leakage and maximization of network self-cleaning capacity (SCC) for reducing discolouration risk. We first presented a review of existing single-objective AZP and SCC control strategies. This concluded with two current challenges concerning the integration of AZP and SCC objectives, which comprised the contributions of this paper.
We first formulated and solved the AZP-SCC bi-objective problem using the weighted sums scalarization method. By leveraging a previously developed convex heuristic, we approximated the Pareto fronts for two specific problems: (i) the design-for-control problem, where both locations and operational settings of PCV and AFV actuators were jointly optimized; and (ii) a control-only problem, where valve actuator settings were optimized for a fixed valve configuration corresponding to a hierarchical design strategy. The hierarchical design considered PCV actuators placed for the individual AZP problem and, following this solution, AFV actuators placed to augment SCC conditions. The resulting Pareto fronts suggest that significant im-provements in SCC can be achieved for minimal trade-offs in AZP performance. Moreover, the hierarchical design approach yielded good quality solutions by varying actuator settings for the fixed valve locations. This is a valuable insight towards the integration of water quality for dynamically adaptive control in smart water networks. Future work should also consider minimizing the costs associated with valve installations.
We then demonstrated an adaptive control scheme to dynamically transition between AZP and SCC control modes. We formulated this control problem as a sequence of single-objective optimization problems, whereby AZP and SCC were considered the primary (master) and secondary (service level) control modes, respectively. Preliminary results highlighted the potential for adverse increases in nodal pressure variation arising from the transition between control modes. Although changes in network hydraulics are inevitable, future work might consider constraining pressure variation to limit the magnitude of the resulting cyclic load. Furthermore, the proposed adaptive control scheme could be implemented in a model predictive control (MPC) framework combined with higher resolution customer metering data. This could enable a shorter control horizon, reducing uncertainties associated with the self-cleaning period, which is assumed as a known 1-hour window in this work.
The presented design and control methods enhance the capabilities of water network operators to cost-effectively and optimally integrate pressure management and self-cleaning operations within dynamically adaptive water distribution networks.