14 The Open Applied Mathematics Journal, 2009, 3, 14-28 Open Access Nonlinear Programming Techniques for Operative Planning in Large Drinking Water Networks Jens Burgschweiger1, Bernd Gnädig2 and Marc . Steinbach3,*

1Berliner Wasserbetriebe, Abt. NA-G/W, 10864 , Germany 2Düsseldorf, Germany 3Leibniz Universität Hannover, IfAM, Welfengarten 1, 30167 Hannover, Germany

Abstract: Mathematical decision support for operative planning in water supply systems is highly desirable; it leads, however, to very difficult optimization problems. We propose a nonlinear programming approach that yields practically satisfactory operating schedules in acceptable computing time even for large networks. Based on a carefully designed model supporting gradient-based optimization algorithms, this approach employs a special initialization strategy for convergence acceleration, special minimum up and down time constraints together with pump aggregation to handle switching decisions, and several network reduction techniques for further speed-up. Results for selected application scenarios at Berliner Wasserbetriebe demonstrate the success of the approach. Keywords: Water supply, large-scale nonlinear programming, convergence acceleration, discrete decisions, network reduction.

INTRODUCTION • experiments with various optimization models and methods [36, 37], Stringent requirements on cost effectiveness and environmental compatibility generate an increased demand • a first nonlinear programming (NLP) model for model-based decision support tools for designing and developed under GAMS [38], operating municipal water supply systems. This paper deals • numerical results for a substantially reduced with the minimum cost operation of drinking water network graph using (under GAMS) the SQP codes networks. Operative planning in water networks is difficult: CONOPT, SNOPT, and the augmented Lagrangian a sound mathematical model leads to nonlinear mixed- code MINOS. integer optimization, which is currently impractical for large water supply networks as in Berlin. Because of the enormous The main goal of the joint work reported here is the complexity of the task, early mathematical approaches development of a decision support tool suitable for routine typically rely on substantially simplified network hydraulics application, to be implemented as an optimization module (by dropping all nonlinearities or addressing the static case, within the new operational control system of Berliner for instance) [1-8], which is often unacceptable in practice. Wasserbetriebe. The approach is restricted to the framework Other authors employ discrete dynamic programming [9-14], sketched above: a pure NLP model (no integer variables), the which is mathematically sound but only applicable to small GAMS modeling environment, and the listed NLP solvers. networks unless specific properties can be exploited to Criteria for applicability are speed (response time), increase efficiency. Optimization methods based on reliability, and practicability. Our mathematical nonlinear models (mostly for the pumps only) are reported in developments toward these goals are based on two internal [15-19]. These approaches employ computationally studies [39, 40] and can be coarsely categorized into expensive meta-heuristics or suffer from inefficient coupling modeling techniques (reported in [41]) and nonlinear of gradient-based optimization with non-smooth simulation programming techniques (reported here). Basic modeling by existing network hydraulics software, such as EPANET techniques include, in particular, a globally smooth and [20]. Other topics in water management include network asymptotically correct approximation of the hydraulic design [21-24], online control [25, 26], state estimation [27], pressure loss in pipes, and suitably aggregated models for and contamination detection [28]. More loosely related collections of pumps that operate in parallel. The NLP recent work addresses modeling and optimization for techniques include, among others, a sequential linear networks of irrigation and sewage canals or for gas programming type initialization procedure for the nonlinear networks, see, e.g., [29-35]. Previous efforts toward mini- iteration, special constraints that ensure minimum up and mum cost operation at Berliner Wasserbetriebe include: down times in pump operation, and various network reduction techniques. Together with pump aggregation, the

*Address correspondence to this author at the Leibniz Universität Hannover, up and down time constraints permit the handling of discrete IfAM, Welfengarten 1, 30167 Hannover, Germany; E-mail: decisions (pump switching) without introducing binary [email protected]; http://www.ifam.uni-hannover.de/steinbach variables. Following the NLP-based network-wide

2000 Mathematics Subject Classification. 65K10, 90C06, 90C11, 90C30, optimization, nonlinear mixed-integer models are solved 90C35, 90C90. locally at each waterworks.

1874-1142/09 2009 Bentham Open Operative Planning in Large Drinking Water Networks The Open Applied Mathematics Journal, 2009, Volume 3 15

Table 1. Notation

Symbol Explanation Value Unit

Q Volumetric flow rate in arcs m3/s D Demand flow rate at junctions m3/s H Pressure potential at nodes (head) m H Pressure increase at pumps, decrease at valves m L Pipe length m d Pipe diameter (bore) m k Pipe roughness m A Pipe cross-sectional area m2  Pipe friction coefficient – r Pipe hydraulic loss coefficient s2/m5  Water density 1000 kg/m3

2 g Gravity constant 9. 81 m/s

We start by summarizing the component models of all 1.2. Optimization Horizon and Dynamic Variables the network elements in Section 1, followed by the overall We consider a planning period of length T in discrete NLP model. In Section 2, the smoothing and SLP time, t = 1, 2, ,T, with initial conditions at t = 0. The initialization are discussed along with further convergence … enhancement techniques. Section 3 is devoted to subinterval (t  1, t) will be referred to as period t and has the physical length t. At Berliner Wasserbetriebe, the combinatorial issues, particularly the prevention of undesired planning period represents the following day in 24 hourly pump switching. Several network reduction strategies are intervals. then developed in Section 4 with special emphasis on suitable smoothing of the hydraulic friction loss. Finally, We measure the pressure by the head H: the sum of the Section 5 presents selected application scenarios at Berliner geodetic elevation and of the elevation gain corresponding to Wasserbetriebe in order to demonstrate the success of our the hydraulic pressure. Pressure variables Hjt are associated approach. with every node j N and time period t. Volumetric flow rates Qat are associated with every arc a A. Control 1. OPTIMIZATION MODEL variables are the pressure increase across pumps and decrease across valves, Hat, a Apu Avl. All variables We will first summarize the nonlinear programming have simple bounds. model developed in [41] in order to keep the paper self- contained. This model covers the physical and technical 1.3. Network Dynamics and Model Constraints network behavior. Later on we will add further constraints and develop graph reduction techniques to achieve a desired The network hydraulics include over-all flow balances solution behavior and to enable efficient treatment by the and pressure relations, with one equation per network selected standard NLP solvers. The basic notation used in element: our model is given in Table 1. 0 cflow : Q Q D ,j, (1) = jt =  ijt   jkt  jt N jc i:ijA k:jkA 1.1. Network Topology 0 = cflow := Q  Q  E (H ,H ), j N , The network model is based on a directed graph G = (N, jt  ijt  jkt jt j,t1 jt tk (2) i:ij k:jk A) whose node set represents junctions, reservoirs, and A A tanks, and whose arc set represents pipes, pumps, and gate 0 = chead := H  H ,jN , valves, jt jt j rs

loss N = Njc  Nrs Ntk, 0 = c := H  H + H (Q ), a = ij A , (3) a t jt it a at pi A = Api  Apu  Avl. 0 cdiff : H H H , ij , = a t = jt  it  at a = Apu The set of pumps consists of raw water pumps and pure water pumps, Apu = Apr App. We denote arcs as a A or, 0 = cdiff := H  H + H , a = ij A , (4) with tail and head i, j  N, as ijA. A flow from i to j is a t jt it at vl positive, from j to i negative. 0  csign := H Q , a = ij A , (5) Fig. (1) illustrates the main network of Berliner a t at at vl Wasserbetriebe, with 1481 nodes and 1935 arcs. Earlier Externally given data include the predicted junction investigations were based on a small test configuration with demands Djt, constant reservoir heads H j, tank inflow 144 nodes and 192 arcs; cf. [41]. 16 The Open Applied Mathematics Journal, 2009, Volume 3 Burgschweiger et al.

Fig. (1). Main distribution network of Berliner Wasserbetriebe. characteristics Ejt(Hj,t1, Hjt), and pipe pressure loss Nontrivial inequalities include bounds on: the flow characteristics Ha(Qat). The sign condition (5) ensures gradients at the raw water pumps, the daily discharge of the consistency of the valve pressure decrease with the unknown waterworks outlets, a Apo, and the total power consumption direction of flow. of raw water and pure water pumps a Apr(w) App(w) at each waterworks or pumping station, w : The hydraulic pressure loss in pipes is usually expressed W in terms of a loss coefficient ra(Qat) depending on the pipe cgrad := Q  Q [Q ,Q+ ], a A , (8) length and diameter, at at a,t-1 at at pr T 8L day  + a c := tQ[Q ,Q ], A , Ha(Qat) = ra(Qat)Qat|Qat|, ra(Qat) = 2 5 a(Qat), (6) a  at at at a po  gda t=1 where the friction coefficient a(Qat) depends on the flow g Q pow raw  Hat at + rate and the pipe roughness k . A highly accurate model for c := w t Q t +  pw, w W. (9) a at  a a   (Q ) aApr (w) aApp (w) a at a is based on the laws of Hagen–Poiseuille (laminar flow) and Prandtl–Colebrook (turbulent flow); we call this the HP- Table 2. Notation for the Cost Function PC model. A much simpler and flow-independent formula is the law of Prandtl–Kármán for rough pipes (PKr model), Symbol Explanation Unit 2  k /d  8L PKr = 2log a a ,rPKr = a PKr , (7) K Total daily operating cost  a  3.71  a 2gd5 a   a el Price for electric energy at pump a during period t /J k which provides a valid approximation for highly turbulent at 3 flow, that is, large Qat. An important element of our approach raw Specific price for raw water and treatment materials k /m is a globally smooth, asymptotically correct approximation a at pump a PKr PKr 3 H that shares the leading coefficient with the r model. raw Specific work for raw water pumping and treatment J/m a a w We call it the smoothed PKr model (PKrs model); for more at at pump a details see [41] and Section 2. 1. Operative Planning in Large Drinking Water Networks The Open Applied Mathematics Journal, 2009, Volume 3 17

Fig. (2). Efficiency of aggregated pure water pumps under optimal configuration.

flow Here a(Qat) is a smooth approximation of the efficiency   {c jt (xt )}j of pure water pumps (actually small groups of them), see  N jc   head  [41, §2.8] and Fig. (2). {c jt (xt )}j  N rs  Relevant initial values are Hj0, jNtk, and Qa0, a Apr, E  flow  |N |+|A| c (x , x ) = {c jt (xt 1, xt )}j R , entering into constraints (2) and (8), respectively. The t t1 t   N tk   loss  remaining initial pump flows Qa0, a App, will be required {c t (xt )} A for the minimum up and down time constraints of Section  a a pi   diff  {c (x )} 3.2. Undesired finite horizon effects are prevented by  at t aA A    pu vl tightened lower bounds H j  Ntk (“terminal constranints”). jT yielding 1.4. Objective Function  cE (x , x )  The overall goal is to minimize the variable operating  1 0 1  costs, cE (x) =    = 0 T  cE (x , x )  K t(Kraw K pure ). (10)  T T1 T  =   t + t t=1 The number of variables and constraints per time step can If we use the cost coefficients in Table 2 and let be reduced by |Nrs| if the constant reservoir pressures are raw raw el raw treated as parameters. In any case, there are | | k = w k + k , the per-period cost of raw and pure Apu  Avl a at a a degrees of freedom per time step corresponding to the water production can be written number of controlled network elements. gH Q The inequality constraints are comprised of upper and kraw kpure kraw Q kel at at . (11) t = t = at at + at lower range constraints and simple bounds on all variables,    (Q ) aApr aApp a at R  +  + c (x)[c ,c ], x  [x ,x ], 1.5. NLP Formulation with range constraints

The decision vector of time step t consists of node  R  c1 (x0 ,x1 ) pressures Hjt, arc flows Qat, and pressure differences Hat      across pumps and valves, cR (x) =  cR (x ,x )   T T1 T   {cday (x)}   {H }   a aA  jt jN  po    n x  {Q }  R , | | | | | |, R t = at aA  n = N + A + Apu  Avl The components of c in each time step include the   nontrivial inequalities from the pumps and valves,  {H t }a A A   a  pu  v1

 grad  {c at (xt 1,xt )}a A yielding the NLP decision vector    pr  |A | |W | |A |. cR (x ,x )  pow  R pr + + vl N t t1 t = {c wt (xt )}wW  x = (x1, . . . , xT) R , N = nT.    sign  {c at (xt )}a A   vl  We do not make a distinction between state and control variables here, and fixed initial values x0 are not included in Note that the daily discharge limit in waterworks outlets x. depends on all decision vectors xt and that the tank flow The equality constraints in each time step comprise one balances and the gradient constraints in the raw water pumps equation per network element (node or arc), depend on the current and previous decision vectors xt, xt1; 18 The Open Applied Mathematics Journal, 2009, Volume 3 Burgschweiger et al. all other constraints only depend on the current decision  c  vector xt. H PKrs (Q) = r PKr  Q2 + a 2 + b + a  Q. a a a a 2 2 Finally, the separable objective can be written as  Q + d  a T T The parameters a > 0 and d > 0 can be selected to f(x) = f(x ) = [f raw (x ) + f pure (x )], a a  t  t t t t match a desired slope at Q = 0 and to balance the relative t=1 t=1 contributions of the two square root terms, whereas ba > 0 raw pure where f and f are given according to (10) and (11) as and ca < 0 depend on the pipe dimensions. They are t t determined in such a way that, asymptotically for |Q|  , f raw (x ) = f raw (Q ) = (w k + k )Q t, the law of Prandtl–Colebrook is approximated up to second t t  at at  raw ,a el,at raw ,at at order [41], aApc aApr

gH Q a 2 f pure (x ) = f pure (Q ,H ) = k at at t. b 2 ,c (ln 1) 2 a , t t  at at at  el,at a = a a = a + a  A A  (Q ) 2 a pc a pp a at Thus we obtain a highly structured NLP model in where standard form: k /d 2 2.51 a a a E J  = ,  = ,  = . Minimize f(x) subject to c (x) = 0, c (x)  0, a 4/(d ) a 3.71 a  ln10 x a a where If accuracy requirements are moderate, the PKrs model can be simplified by setting c = 0 or even b = c = 0. This  cR (x)  c  a a a   may be appropriate, for instance, for saving computational + R J c c (x) effort during early NLP iterations. c (x) =    .     x  x  The numerical effect of the smoothing heavily depends + on other circumstances.  x  x  Computational experiments show that, on the test configuration, the smoothing yields significant convergence improvements for CONOPT and 2. CONVERGENCE ACCELERATION SNOPT (the SQP methods) with default initialization One of the primary goals in developing the optimization heuristics, whereas MINOS (the augmented Lagrangian approach presented here is to achieve acceptable response method) is hardly affected at all. Moreover, SNOPT is slightly faster than MINOS on average. Interestingly, the times for daily planning. Since we are restricted to work with 2 1 general purpose NLP solvers available under GAMS, advantage of the C PKrs model over the C PKr model exploiting the characteristic NLP structure by developing disappears when we introduce the SLP-based initialization special algorithms is not an option. We have to rely on scheme of Section 2.2; now MINOS performs equally well on convergence enhancement and other techniques. A suitable both formulations, and always better than SNOPT. Another model formulation and a special initialization strategy for the change in the picture occurs when we switch to the much iterative solution have turned out to be the most effective larger main network model. Here the smoothing is beneficial measures for convergence acceleration. for both solvers, with MINOS still outperforming SNOPT on average. (Apparently, due to rapid convergence within about 2.1. Model Smoothness 20 major iterations, the BFGS updates in SNOPT cannot build up sufficient curvature information to give an 2 The objective and constraints in our model are all twice advantage). In practice, we therefore use MINOS on the C continuously differentiable (C2), except for the pipe friction model. loss H(Q) = r(Q)Q|Q|. In the piecewise quadratic PKr PKr model H , the second order derivative has respective 2.2. Initial Estimates constant values 2rPKr and +2rPKr for Q < 0and Q > 0, producing a jump discontinuity at Q = 0. Thus HPKr is C1 Computational experiments with artificially perturbed only. The more accurate HP-PC model HHP-PC is not even optimal solutions (we added 10% white noise) confirm the continuous at the transition from laminar to turbulent flow [41]. expectation that rapid convergence can be achieved when the initial iterate is close to a solution. We have devised an The available solvers use derivatives up to first order automatic initialization scheme based on LP approximations (MINOS) or second order (CONOPT and SNOPT); numerical 1 of the NLP model in order to exploit this fact. Such difficulties must therefore be expected on a C (or even less approximations are rather crude but quickly solvable with smooth) model whenever the flow variables traverse standard LP software (we use CPLEX), so that physically discontinuities between subsequent NLP iterations. This will meaningful initial estimates are generated with little effort. If typically happen during the initial phase of the iterative solution the LP approximation is repeated several times, it yields an (i. e., far from the optimum, where large steps are taken), whereas initialization scheme of SLP type (sequential linear it is less likely during the final phase of local convergence. programming). In order to avoid such numerical difficulties, we The basic idea of SLP approaches in the literature (cf. recommend the following smoothed PKr model as a global [42-44]) is to replace the expensive QP in SQP methods approximation of the pipe friction loss, (sequential quadratic programming) by a simpler LP Operative Planning in Large Drinking Water Networks The Open Applied Mathematics Journal, 2009, Volume 3 19 subproblem, which results in an estimate of the active set at 2.2.1. Linearization little cost even for very large problems: Observe first that nonlinearities only arise in the pressure * Minimize g s (12) loss equations closs , in the valve constraints csign , and in the s k at at objective. These nonlinearities are handled as follows. subject to JE s + cE = 0, (13) k k (1) The PKr friction model is used, and the absolute JJ s + cJ  0, (14) volumetric flow rates |Qat| are replaced by constant k k parameters Q > 0. The pressure loss (6) then reads at ||s||  . (15) H  H  r PKrQ Q = 0. The trust region constraint is introduced here to ensure jt it a at at global convergence and to prevent unboundedness, and the For the parameter Q we use a heuristic initial at LP data are generated as a standard linearization of the estimate defined as a constant multiple of the pipe problem functions. Thus gk is the gradient of the objective, diameter, Q0 = cd . (In practice, a reasonable value cE ,cJ are the respective residuals of equality and inequality at a k k may be available from optimal solutions of the past). E J constraints, and J ,J are the associated Jacobians: k k k In iteration k, the flow components Q of the LP at k E E E E k * solution are then used to update the parameter values, gk = f(x ), ck = c (xk ), J k = c (x ) , k+1 k k J J J J k * Q Q (1 )|Q |, c = c (x ), J = c (x ) . at =  at +  at k k k The LP solution sk serves to determine a working set of where we choose  = 0.6 as weighting factor in the currently active constraints, based on which a better second convex combination. order step is usually calculated. Only if this fails, sk is taken as (2) If we temporarily assume that the direction of flow is the step direction for the SLP. known in all valves, the sign condition is replaced by two simple bounds, The LP (12)–(15) may be infeasible even if the NLP is feasible; it is therefore appropriate to minimize the 1 penalty Qat  0, Hat  0 or Qat  0, Hat  0. function instead, subject only to the trust region constraint, The dual LP solution then yields directional information for the next LP iteration: if any of the Minimize 1(s,) subject to || s || , (16) s  simplified constraints are binding, the sign of both where constraints can be switched on the assumption that the chosen direction of flow was not optimal. (s, ): g*s || JE s cE || || min(JJ s cJ ,0)|| 1  = k +  k + k 1 +  k + k 1 (3) The nonlinear term H Q /(Q ) in the pump at at at g*s |Ji s ci | | min(J i s ci ,0)|. efficiency model entering the cost function is handled = k +  k + k +  k + k iE iJ as follows: the pressure difference Hat is replaced by a constant parameter that is iteratively updated like For the numerical solution, the nonsmooth 1 problem is finally converted to the LP form by standard techniques (see, Q . The quotient Qat/(Qat) is approximated by a at e.g., [45]), yielding the problem strictly increasing convex piecewise linear function of * * * Q that consists of three segments and starts at the E E J (17) at Minimize gks + e (s+ + s ) + e s s,sE ,sE ,sJ origin. +   E E E E E E Our LP is a local approximation of the NLP yielding subject to J s + c  s + s = 0, s ,s  0, (18) k k k +  +  the iterate x , rather than a local linearization yielding a step direction sk at the given iterate. Moreover, we do JJ s + cJ + sJ  0, sJ  0, (19) k k   not use any second order information. 2.2.2. Trust Region ||s||  . (20) We do not impose a trust region constraint in addition to The nonnegative slack variables sE ,sE ,sJ represent +   the bounds on all variables, since we are not interested in positive and negative violations of equality and inequality global or local convergence properties of the SLP method; constraints, respectively, and e denotes the vector of ones in we only want to get a cheap initial estimate for the NLP appropriate dimensions. We can easily see that the modified iteration instead. In practical computations we usually LP (17)–(20) is always feasible. Moreover, if the penalty perform three SLP-type steps before switching to the fully parameter  is sufficiently large, the slacks of an optimal nonlinear model. According to our experience (based on a solution vanish if and only if the original LP is feasible, in large number of numerical experiments), this yields the best which case both problems yield the same optimal value for performance for the network of Berliner Wasserbetriebe. the step s. 2.2.3. Penalty Our problem-specific scheme differs from the general The 1 penalty approach ensuring feasibility is only approach in several respects: applied to selected constraints, namely to the pressure limits 20 The Open Applied Mathematics Journal, 2009, Volume 3 Burgschweiger et al. at pressure measurement points and at the outlets of • alternating discharge: a certain flow rate is waterworks and pumping stations. These constraints are produced by two or more waterworks outlets relaxed in the LP as well as in the NLP model. alternating in time. A relaxation of all inequality constraints is applied in a Operating schedules like these reduce the pump lifetime second version of our operative planning model. This and require increased activity of the operators. version is used after physical modifications of the network, The specification of minimum up and down times is in order to detect potential infeasibilities caused by errors in straightforward in a mixed-integer model. Let Yat {0, 1} the mathematical formulation or input data. designate the activity status of pump a App; cf. [41]. Then 2.2.4. Remarks the following linear inequality constraints, specified at t = 0,…,TK, freeze the status for at least K periods after a A pure SLP approach has also been tested. The switch: performance was generally inferior to the combined LP/NLP approach; often the iteration did not even converge. K(Ya, t+1  Yat)  Ya, t+1 + ··· + Ya, t+K  2K(Ya, t+1  Yat) + K. Finally, we tried to catch the combinatorial aspects of the In a pure NLP setting it is unclear how to obtain a similar problem explicitly during the SLP initialization procedure by effect. Several mathematical and heuristic techniques have replacing the LP approximations by similar mixed-integer therefore been devised and tested in order to avoid linear programs (MIP). Even with SOS Type 2 formulations unnecessary pump switching. These can be categorized into of the piecewise linear approximation of the pressure loss three major groups: equations (cf. [46-48]), the solution of the MIP subproblems (1) penalty approach; took so long that no benefit could be achieved. (2) linear, piecewise linear, and nonlinear constraints (C0 2 3. COMBINATORIAL ISSUES or C ); Combinatorial aspects addressed here include the (3) heuristics. direction of the flow across valves and the switching of In summary, most of the techniques either proved little speed-controlled pumps. Further aspects that may occur in successful or rather slow. However, we did find water networks include the switching of fixed-speed pumps computationally cheap smooth constraints (group 2) that [41] and the choice among alternative waterworks outlets. suppressed the undesired behavior, either with certainty The latter involve purely integral decisions that cannot be (pump activation) or with high reliability (deactivation). treated satisfactorily in an NLP setting to date, although 3.2.1. Avoiding Short-Term Pump Activation nonlinear programs with certain combinatorial structures (complementarity constraints and equilibrium constraints) As it turns out, activation of pumps for one or two have recently been studied and successfully solved by periods can be prevented with certainty by suitable linear suitably extended NLP methods [49-53]. inter-temporal constraints. Formally, we wish to inhibit flow sequences of the types 3.1. Flow Direction across Valves (1) (Qt, Qt+1, Qt+2) = (0, Qt+1, 0) with Qt+1 > 0, or The valve sign condition (5) has some undesirable (2) (Q , Q , Q , Q ) = (0, Q , Q , 0) with Q , Q > 0. properties at the origin, where the gradient vanishes and no t t+1 t+2 t+3 t+1 t+2 t+1 t+2 constraint qualification holds. This reflects the geometry of The basic idea is to prevent excessive concavity of the the feasible set: consisting of two opposite closed quadrants, piecewise constant flow rate profiles (1) and (2) by placing it has a disconnected interior and becomes itself appropriate lower bounds on their discrete curvatures. In disconnected if the origin is removed. One might think that case (1), such a condition may be formulated as the direction of the flow should therefore be introduced as a Qt  2Qt+1 + Qt+2   c1(Qt + Qt+1 + Qt+2), t = 0,…, T  2, (21) binary decision variable; however, a detailed analysis reveals that no numerical difficulties are to be expected as long as where c1 > 0 is a constant parameter. The flow-dependent the gradient of the Lagrangian (projected into the relevant right-hand side allows for larger values of the concavity with subspace) does not vanish at the origin. The latter condition increasing total flow. A suitable range for the value of the is satisfied generically; there is therefore no need to parameter c1 is determined as follows. In the case of interest, reformulate the model. Qt = Qt+2 = 0, condition (21) yields

2Qt+1   c1Qt+1, 3.2. Pump Switching so that one must choose c1 < 2 to force Qt+1 to zero, as Computational experience shows that optimal solutions desired. On the other hand, we do not wish to rule out frequently exhibit undesirable pump switching at the otherwise feasible pump operation: if c1 is chosen waterworks outlets: unreasonably small, then condition (21) will become too restrictive. This can immediately be seen in the equivalent • short-term activation of a pump for just one or two form periods; 1+ c • short-term deactivation of a pump for just one or Q  1 (Q + Q ), (22) t+1 2  c t t+2 two periods; 1 Operative Planning in Large Drinking Water Networks The Open Applied Mathematics Journal, 2009, Volume 3 21

1 assume that (Qt, 0, 0) and (0, 0, Qt+2) are feasible and all which implies, for instance, Qt+1  (Qt + Qt+2) if c1 = 0, and 2 feasible sequences satisfy the constraint

Qt+1 = 0 for all t if c1  1. In order to find a lower bound on aQt + bQt+1 + cQt+2 + d  0. c1, we rewrite (21) as Although the sequence (Qt, 0, Qt+2) is forbidden, it (1 + c1)(Qt + Qt+2)  (2  c1)Qt+1  0 satisfies the same constraint. The asymmetry arises from the and determine the minimum of the left-hand expression over fact that during activation the initial and final flow rates are the nontrivial feasible flow sequences, both exactly known and identical, Qt = Qt+2 = 0, whereas  + only Qt+1 = 0 is known during deactivation. In general, Qt {Qt, Qt+1, Qt+2 {0} [Q , Q ]: Qt  0 or Qt+2  0}. and Qt+2 are neither known nor identical in the latter case. This yields In order to inhibit short-term deactivation, we suggest to  + (1 + c1)Q (2  c1)Q  0, specify a certain fraction of the minimum of the enclosing values as lower bound on the intermediate flow rate; we which is realized by the extremal flow sequences arrive at the piecewise linear constraint (0, Q+, Q) and (Q, Q+, 0). Qt+1  c min(Qt, Qt+2), t = 0,…, T  2, Letting with an appropriate parameter range of c (0, 1]. Although Q+ 21  1   = > 1and =  ,2 , doing the job, this formulation slows down convergence Q 1  +1  2 dramatically, which is not surprising since the minimum 0 the minimal left-hand expression above is finally seen to be function is not differentiable but only continuous (C ). Using nonnegative if and only if the standard reformulation in terms of the absolute value function, c1 [1, 2) where [1, 2)  0 . c Similar reasoning for the two-period case (2) yields the Qt+1  (Qt + Qt+2  |Qt  Qt+2 |), restriction 2 Q  Q  Q + Q  c (Q + Q + Q + Q ), 2 2 2 t t+1 t+2 t+3 2 t t+1 t+2 t+3 one can now apply the smoothing |x|= x  x +  to t = 0,…, T3. obtain the C2 formulation

One must require c2 < 1 here in order to prevent c 2 2 undesired pump activation, and a lower bound 2 is obtained Qt+1  Qt + Qt+2  (Qt  Qt+2 ) +  . by the reformulation 2 ()

(1+ c2)(Qt + Qt+3)  (1 c2)(Qt+1 + Qt+2)  0. We finally redefine c in order to arrive at the nonlinear inequality Minimizing the left-hand expression yields extremal flow sequences  1  Q  cQ+ Q  (Q  Q )2 + 2  0, c  0, . (23) + +   + + t+1 ()t t+2 1 t+2  2 (0, Q , Q , Q ) and (Q , Q , Q , 0),  and the condition The two-period version consists of two similar  + inequalities with identical parameters, (1+ c2)Q  (1 c2)(2Q )  0. Thus we finally get Qt+i  c min(Qt, Qt+3), i = 1,2, t = 0,…, T3, yielding the smooth reformulation 21  1 c [ ,1) where ,1 , and [ ,1) 0. 2  2 2 =  2  2 +1  3 2 2  1  Q  cQ+ Q  (Q  Q ) +   0, c  0, ,i= 1, 2. (24) t+i ()t t+3 1 t+3  2 In summary, the following linear inequalities prevent  undesired pump activation for one or two periods with Note that the constraints (23), (24) are always compatible certainty without being too restrictive: with the flow bounds and flow gradient bounds.  1  (c1 + 1)Qt + (c1  2)Qt+1 + (c1 + 1)Qt+2  0, c1   ,2 , 4. MODEL REDUCTION  2  Due to excessive computation times with the main (c2 + 1)Qt + (c2  1)Qt+1 + (c2  1)Qt+2 + (c2 + 1)Qt+3  0, network (even in the case of rapid convergence), the need for  1  a systematic size reduction of the network graph arose. Such c2   ,2 .  3  a reduction is performed by preprocessing before the optimization; it is based solely on static network data, so that These restrictions are specified for each pump in almost a single reduced graph is used over the entire horizon. all time steps, yielding the large number of O(|Apu|T) extra conditions. Despite this, no adverse effect on the The reduction leads to simplified models for the pipe computation time was observed on our problem instances. friction loss, where we calculate the leading coefficient from the PKr model to ensure asymptotically correct friction loss 3.2.2. Avoiding Short-Term Deactivation of Pumps for large flow values |Q|. Appropriate smoothing is then Linear restrictions in the spirit of (21) are unfortunately introduced for small flow values. not useful if we want to avoid short-term deactivation: 22 The Open Applied Mathematics Journal, 2009, Volume 3 Burgschweiger et al.

From these values we readily obtain the required parameters b, c for the PKrs model.

4.2. Pipe Sequences Fig. (3). Collapsing parallel pipes. A sequence of n pipes traversing junction nodes 0,…, n 4.1. Parallel Pipes can be collapsed if no other arcs are connected to the interior nodes 1,…, n  1. In this case the interior nodes are It is not uncommon for municipal water networks to eliminated, their demands D are distributed over the two contain pairs of nodes that are connected by several boundary nodes, and the n pipes are replaced by a fictitious “parallel” pipes. In the network model, such pipe ensembles single pipe; (see Fig. (4)). can be replaced by a single pipe (see Fig. 3), which is hydraulically equivalent if the loss coefficients r are flow- independent (PKr model). Consider a collection of n parallel pipes with total flow rate Fig. (4). Collapsing pipe sequences.

Q= Q1 + ··· + Qn. (25) 4.2.1. Zero Interior Demands

All the flows Q and Q have the same direction and a In the case of vanishing demands, pipes 1,…, n have common pressure difference, identical flow rates, Q = Q, and a hydraulically equivalent model is obtained if and only if the loss coefficient r of the H = rQ|Q| = r Q |Q |,  = 1, ,n. (26)    … fictitious pipe is defined as the sum of the individual loss The fictitious loss coefficient r of the hydraulically coefficients, equivalent pipe is readily calculated from (25) and (26). n n n Assuming positive flows with no loss of generality, one H H H H r Q |Q | r Q|Q| rQ|Q|. 0  n =  v1  v =  v v v = v = obtains v=1 v=1 v=1 H n n H This is similar to serial resistors in an electric circuit, and = Q = Q = , it does not matter whether the coefficients r are assumed to r  v  r v=1 v=1 v be flow-independent or not. and hence 4.2.2. Nonzero Interior Demands 2 For arbitrary consumption demands it is impossible to 1 n 1  n H  =   r =   . construct a hydraulically equivalent reduced model. There r v=1 r  v=1 rv are three reasons: v (1) the symmetry with respect to the direction of the flow Conversely, with (26) the individual flows Q are  is broken in general: inflows of identical magnitudes recovered from the total flow as at nodes 0 and n yield different absolute pressure differences; r Q = Q. v r (2) the inflow may enter from both sides, adding up to v the total interior demand; This is similar to parallel resistors in an electric circuit, (3) the pressure difference does not depend quadratically except that the flow dependence here is quadratic rather than on any linear combination of the flow rates Q , even linear.  with quadratic segment losses rQ|Q| (PKr model). For a derivation of the parameters of the smooth As it turns out, the best fictitious replacement pipe in this approximation (2.1), the replacement pipe also needs l fictitious geometric dimensions. We define the length as the case is obtained as follows. With the notation rk:l := r ,  v=k v average length of the original pipes, and the diameter such let r = r1:n (as above), let L = L1:n, and split each interior that the total pipe volumes agree, demand D into fictitious demands (r+1:n/r)D at node 0 and

n n (r1:/r)D at node n, according to the relation of friction losses 1 l 2 L L ,d L d . to each endpoint: =  v =  v v n v=1 L v=1 n1 r n1 r Dint := v+1:n D ,Dint := 1:v D . (27) The roughness is finally chosen in such a way that r is 0  r v n  r v consistent with all dimensions according to (6) and (7), v=1 v=1 The actual inflow from node 0 and outflow to node n, Q1 2 8L  k/d and Qn, are thus replaced with a common fictitious flow r 2log = 2 5   int int gd  3.71 value, Q1  D = Qn + D .  0 n yielding As with parallel pipes (see Section 4.1), the diameter d and roughness k of the fictitious pipe are determined such p 2 5 k = 3.71d 10 ,p= 2L / ( gd r) that its loss coefficient r is consistent with the PKr model. Operative Planning in Large Drinking Water Networks The Open Applied Mathematics Journal, 2009, Volume 3 23

We will now see that one can do better than with such a By symmetry, the relevant quantities above can also be single pipe replacement model. Consider the exact pressure expressed in terms of Qn rather than Q1. If we define loss in the pipe sequence according to the quadratic PKr D = D:n1,  = 1,…, n, model. Since the flow rates in successive pipes are related by

so that Q = Qn + D with Dn = 0 and D1 = Dn , this yields Q+1 = Q  D,  = 1,…, n  1, alternative representations for the actual in-and outflow, we inductively get

Q1 = Q1  D1 = Qn + D1, Q = Q1  D , = 1,…, n, v Q1  D = Qn + Dn = Qn, where Q is the inflow from node 0 and D denotes the n 1 v cumulative interior demand up to and including node   1, and for the (identical) fictitious in-and outflow, int int D = D1:1, = 1,…, n. Q1  D0 = Q1  E (D) = E(Q) = Qn + E(D) = Qn + Dn . v (Note that D = 0, giving total interior demand D = D + ··· + D ). Two-Sided Inflow 1 n 1 n1 Thus we obtain A second, more serious qualitative defect arises when Q1 n n  (0, D ), or E(D) < E(Q) < E (D) : in this case, we have H  H = r Q |Q | = r (Q  D ) |Q  D |. n 0 n  v v v  v 1 v 1 v inflows from both sides, and the total pressure difference H v=1 v=1 0 Left-Sided Inflow  Hn depends on the location where the inflows meet in the pipe sequence. This location has minimal pressure within the Consider first the case where Q1  D (that is, all flow sequence and occurs either at a unique node whose inflows n directions in the pipe sequence are positive) and observe that are both smaller than the local demand, or possibly at a unique pair of nodes whose (one-sided) inflows equal the the coefficients r/r formally satisfy the properties of a probability distribution. Defining the spatial flow respective demands, yielding stagnant flow in between. Clearly, this situation cannot be modeled by a single distribution vectors Q = (Q1,…,Qn) and similarly D = replacement pipe with just one flow direction (reason 2). ( D ,…, D ) etc., one obtains 1 n Without simplifications, the PKr friction model yields a n r piecewise quadratic dependence where the curvature has H  H = r v Q2 = rE(Q2 ) 0 n  v jump discontinuities at Q1 = D (or Qn = D),  = 1,…, n. v=1 r (28) v = r[E(Q)2 + (E(Q2 )  E(Q)2 )] = rE(Q)2 + rVar(Q). Denoting the fictitious flow E(Q) as Q and the values  + The first term can be interpreted as the pressure loss of a E (D), + E(D) as D , D , respectively, we suggest to use a global weighted average flow rate with respect to the smoothing for the entire sequence by approximating the pressure difference for Q(D, D+) with the unique “probabilities” r/r, polynomial of degree five, which has C2 junctions with the outer n r pieces at Q = D and Q = D+: v Q = E(Q) = E(Q  D) = Q  E(D).  v 1 1 5 v 1 r = (Q) = c Qk , The second term can be interpreted as an additional  k k=0 pressure loss due to the variance of the individual flow rates, which equals the flow-independent variance of the where the coefficients ck are obtained from a linear equation accumulated demands, system representing the matching conditions. The resulting replacement model (“generalized pipe”) has three benefits: 2) 2 Var D E(Q  E(Q) = (Q) = Var(Q1  ) = Var (D) . the constant variance term is included, inflows from both Since D = 0, this variance vanishes if and only if all sides are suitably modeled, and all discontinuities disappear. 1 Letting V = Var (D) = Var(D), one thus gets a global C2 interior demands vanish. representation consisting of three pieces; (see Fig. (5)): Right-Sided Inflow

Consider next the situation for Q1  0, which is similar to Q  D except that the flow now has the opposite direction, 1 n and we have a pressure loss from node n to node 0, 2 2 H0  Hn = rE(Q)  rVar(Q) = rE(Q)  rVar (D) . With the demand redistribution defined in (27), the fictitious pipe’s flow rate is E(Q), Fig. (5). Three-piece C2 model of pressure loss in a pipe sequence. r Q  Dint = Q  μ D = Q  E(D) = E(Q), 1 0 1  r v 1 rQ2  rV, Q  D , 0

4.3. Short Pipes For the network of Berliner Wasserbetriebe, the maximal length of a “short” pipe has empirically been set to 500m The pressure loss along a short pipe is often negligible so after several experiments; this value represents the best that the pipe can be collapsed into a single node; see Fig. (6). compromise of model accuracy and computation time. The Such collapsing may even be possible for entire subnetworks reduced main network then has 413 nodes and 608 links. (consisting of junctions and sufficiently short pipes only), The threshold length may be gradually decreased in the which is typical for residential or industrial areas. future with increasing computing power.

5. RESULTS Fig. (6). Collapsing short pipes and subnetworks. We consider the municipal drinking water network of Berliner Wasserbetriebe, which has nine waterworks and The following algorithm is used for collapsing eight additional pumping stations, five of which are subnetworks. equipped with tanks. The total length of all pipes is 7800 km. (1) Input: a subset of pipes that must not be removed There are 256000 household connections, serving a yearly 3 from the graph, A0 Api, and the maximal length of a consumption demand of over 200 million m with daily “short” pipe, Lmax. demands ranging between roughly half a million and one million m3. (2) Determine the set of short pipes eligible for removal, In the waterworks, raw water is extracted via A = {a A \ A0: La  L }. short  pi max groundwater wells from reservoirs. After treatment, the pure (3) Determine the network subgraph induced by Ashort, water is stored in tanks and then pumped into the pressurized with connected components Gl =(, Al). distribution network. Control actions to be planned include (4) Collapse each connected component G to a single raw water pumping, pure water pumping, filling and l emptying of the tanks, and setting of the control valves. junction l having demand Dl: In order to investigate how optimal solutions change with D D . 1 =  j the operating conditions, we consider four scenarios with j N t different combinations of

Fig. (7). Optimal raw water production at BEE and TIE, and tank inflows at COL and MAR (m3/h). Scenarios 1 (top left), 2 (top right), 3 (bottom left), and 4 (bottom right). Operative Planning in Large Drinking Water Networks The Open Applied Mathematics Journal, 2009, Volume 3 25

• the demand: normal and high; (3) fixed electricity price, previous GEG, normal demand (bottom left); • electricity prices: constant and variable; (4) variable electricity price, current GEG, high demand • groundwater extraction fees: current and previous. (bottom right). The normal daily demand is 585000 m3, the fictitious high 3 The behavior of the entire network is much too complex demand is one million m . to visualize; we therefore focus on a selected area in the Electricity prices differ between the providers in Berlin and southern uptown. This area is mainly served by the two in the federal state of Brandenburg where the waterworks waterworks Beelitzhof (BEE) and Tiefwerder (TIE), and it Stolpe is located. In the scenario with variable electricity includes three pumping stations: Columbiadamm and prices, a reduction by about 13% has been applied at the Marienfelde (COL and MAR, with tanks), and Kleistpark waterworks Stolpe during nighttime (18:00-08:00). (KLE, without tank). Note that the GEG differences (at The groundwater extraction fees (GEG, Grundwasserent- Spandau and Tegel) and the nighttime reduction of the nahmeentgelt in German) also differ between the waterworks electricity price (at Stolpe) occur far from the area of of Berlin and Brandenburg. They are about six times higher interest; nevertheless we will see effects on the optimal in Berlin compared to the fees in the federal state of operation schedules. Brandenburg. Within Berlin, the current groundwater Fig. (7) displays the raw water production at waterworks extraction fees are identical all over the city, whereas BEE and TIE, and the tank inflows at pumping stations COL previous fees have been reduced at the waterworks Spandau and MAR. We observe that the raw water production is quite and Tegel. steady, as desired. Production is low during nighttime and In the following, every figure compares for some high during daytime at almost constant levels. The slopes in quantity of interest the time histories of the following four between are also constant, showing that the gradient scenarios: constraint (8) is binding. In scenarios 1 and 3 (normal demand) we have brief transitions between long periods with (1) fixed electricity price, current GEG, normal demand constant levels, and in scenarios 2 and 4 (high demand) we (top left, reference); have a long nighttime transition and a brief constant daytime (2) fixed electricity price, current GEG, high demand period. The two waterworks are always active in either case. (top right); In the case of normal demand, only one pumping station

Fig. (8). Optimal discharge flows into the southern uptown at BEE, TIE, COL, MAR, and KLE (m3/h). Scenarios 1 (top left), 2 (top right), 3 (bottom left), and 4 (bottom right). 26 The Open Applied Mathematics Journal, 2009, Volume 3 Burgschweiger et al.

Fig. (9). Optimal outlet pressures into the southern uptown at BEE, TIE, COL, MAR, and KLE (bar). Scenarios 1 (top left), 2 (top right), 3 (bottom left), and 4 (bottom right).

(COL) fills its tank during a brief period (either before Fig. (9). displays the outlet pressures at waterworks BEE midnight or in the early morning, depending on the GEG), and TIE, and at pumping stations COL, MAR, KLE. In the whereas heavier nightly tank inflow and an additional late- case of normal demand we observe only slight pressure afternoon inflow occur at both COL and MAR in the case of variations, as desired. Note that pumping stations COL and high demand. If the GEG is reduced, both BEE and TIE MAR reach their maximal pressures during nighttime, produce significantly less water than in the reference case. although they are not pumping. The reason is that The reduction of the nighttime electricity price at the distant consumption is low, hence there is very little pressure loss waterworks Stolpe has no visible effect here. from the waterworks outlets to the customers. If the demand is high, there are substantial variations, especially before and Fig. (8) displays the outlet flow rates to the southern during the morning peak, when the pressures reach their uptown at waterworks BEE and TIE, and at pumping stations maximal values. A reduction of the GEG or the electricity COL, MAR, and KLE. In the reference case (normal demand), the outflow at TIE varies only slightly whereas price does not result in significant differences, except for higher nighttime pressure at TIE and lower pressure at KLE BEE roughly follows the demand profile and KLE is under in scenario 4, corresponding to altered pump operation. heavy load during the morning and evening peaks. Pumping station COL contributes a small share between the peak Fig. (10) displays the tank filling levels at waterworks times. In scenario 2 (high demand) the behavior is totally BEE and TIE, and at pumping stations COL and MAR. In different. Both BEE and TIE are under heavy load during the case of normal demand, the filling level at TIE is almost daytime and still active at nighttime, while both COL and constant, and the tank is deflated very slightly during MAR feed the network only during the morning peak. daytime. The tank at BEE is filled during peak times and Pumping station KLE works continuously during day and deflated in between. In the reference case, the tank at COL is night, supplying a substantial share of water from a full most of the time and is deflated during the evening peak, neighboring pressure zone where plants with high capacity while the filling level at MAR remains constant. With and high efficiency are located. This effect is even more reduced GEG (scenario 3) the level at COL remains constant pronounced with reduced GEG at Spandau and Tegel while the tank at MAR shows an insignificant deflation (scenario 3), where KLE becomes the main source in during nighttime. The slight variations are partly caused by compensating for the reduced production at BEE and TIE. the constant electricity prices. Another reason is that the Variable electricity costs result in lower nighttime supply potential energy of the water is higher when the tanks are from KLE and increased supply from TIE. full, which reduces the power consumption of the outlet Operative Planning in Large Drinking Water Networks The Open Applied Mathematics Journal, 2009, Volume 3 27

Fig. (10). Optimal tank filling levels at BEE, TIE, COL, MAR (m). Scenarios 1 (top left), 2 (top right), 3 (bottom left), and 4 (bottom right). pumps. In the case of high demand, the tanks at BEE and degree of detail for optimization in Berlin is mainly limited TIE are operated as in scenario 1 but with somewhat greater by what can be achieved in reasonable response time (up to deflation, while the tanks at COL and MAR are both 30 minutes) on affordable hardware (a PC workstation). substantially deflated during daytime. This holds irrespective From the modeling side, direct extensions to network-wide of the reduced nighttime electricity price which, however, mixed-integer optimization as well as detailed component causes permanently lower filling levels at TIE. models are already available [41]. This allows for more accurate optimization as soon as faster hardware or improved 6. SUMMARY algorithms become available. The use of the current NLP model is likely to result in further gains in efficiency by the We have presented a method for network-wide operative development of custom sparse solvers based on similar planning in pressurized water distribution networks that is techniques as in [35, 54]; in such a way, the rich sparse practically applicable to large networks and under a wide structure induced by the network model and time range of operating conditions. An optimization module discretization can be exploited. implementing our approach is integrated into the operational control system at Berliner Wasserbetriebe, where it is used REFERENCES for the daily planning. Such an integration is emphasized in [8] as the “hook” that interests the city water managers in [1] Coulbeck B, Brdys M, Orr CH, Rance JP. A hierarchical approach trusting and, ultimately, using the system. Notwithstanding to optimized control of water distribution systems. I: Decomposition. Optim Control Appl Methods 1988; 9(1): 51-61. this correct assessment, carefully dovetailed optimization [2] Coulbeck B, Brdys M, Orr CH, Rance JP. A hierarchical approach models and numerical methods are essential for obtaining to optimized control of water distribution systems. II: lower-level meaningful results, given the enormous complexity of the algorithm. Optim Control Appl Methods 1988; 9(2): 109-26. planning problem. Apart from sub-model approximations, [3] Diba A, Louie PWF, Yeh WWG. Planned operation of large-scale convergence acceleration techniques, and the like, our water distribution system. J Water Resour Plan Manage 1995; (121): 260-9. approach features a network reduction strategy whose [4] Ernst AT. Continuous-time quadratic cost flow problems with tradeoff between accuracy and numerical effort can be applications to water distribution networks. J Aust Math Soc, Ser B adjusted via a scalar parameter. It also features smooth 1996; 37(4): 530-48. minimum up and down time constraints which, in [5] Klempous R, Kotowski J, Nikodem J, Ulasiewicz J. Optimization algorithms of operative control in water distribution systems. J combination with pump aggregation, enable us to handle Comput Appl Math 1997; 84(1): 81-99. pump switching without introducing integral decision [6] Papageorgiou M. Optimal control of generalized flow networks. In: variables. Individual pump schedules are obtained in a post- system modelling and optimization, Proceedings 11th IFIP processing step by solving separate mixed-integer NLP Conference, Copenhagen 1983. Lecture Notes Control Information models (MINLP) locally at each outlet, with flows and Science Berlin 1984; vol. 59: pp. 373-82. pressures given by the network-wide NLP solution. The 28 The Open Applied Mathematics Journal, 2009, Volume 3 Burgschweiger et al.

[7] Sun YH, Yeh WWG, Hsu NS, Louie PWF. Generalized network [31] Gugat M. Boundary controllability between sub-and supercritical algorithm for water-supply-system optimization. J Water Resour flow. SIAM J Control Optim 2003; 42: 1056-70. Plan Manage 1995; (121): 392-8. [32] Gugat M, Leugering G, Schittkowski K, Schmidt EJPG. Modelling, [8] Wilson RL, Reely BT, Cox M. The water resource management Stabilization, and control of flow in networks of open channels. In: system (WREMS) linking data management and operational Grötschel M, Krumke SO, Rambau J, Eds. Online optimization of optimization. Ann Oper Res 1997; 72: 105-24. large scale systems. Berlin: Springer 2001; pp. 251-70. [9] Can EK, Houck MH. Real-time reservoir operations by goal [33] Leugering G, Schmidt EJPG. On the modelling and stabilization of programming. J Water Resour Plan Manage 1984; (110): 297-309. flows in networks of open canals. SIAM J Control Optim 2002; [10] Carpentier P, Cohen G. Applied mathematics in water supply 41(1): 164-80. networks management. Automatica 1993; (29): 1215-50. [34] Ostapenko VV, Pavlygin AI. Dynamic network flows for [11] Cembrowicz RG. Steuerungsoptimierung eines Wasserversor- generalized Kirchhoff law. Cybern Syst Anal 1996; 32(3): 309-97. gungssystems. GWF Wasser/Abwasser 1990; 131(10): 550-62. [35] Steinbach MC. On PDE solution in transient optimization of gas [12] Murray DM, Yakowitz SJ. Constrained differential dynamic networks. J Comput Appl Math 2007; 203(2): 345-61. programming and its application to multireservoir control. Water [36] Burgschweiger J. Grundlagenermittlung zum Modul Optimierung Resour Res 1979; 15: 223-35. innerhalb des LSW-Managementsystems. Internal Report, Berliner [13] Orr CH, Parker MA, Tennant ST. Implementation of on-line Wasserbetriebe 2001. control scheme for city water system. J Water Resour Plan Manage [37] Burgschweiger J. Optimierung der verteilten Wasserförderung in 1990; (116): 708-26. großen Rohrnetzen. Internal Report, Berliner Wasserbetriebe 2002. [14] Zessler U, Shamir U. Optimal operation of water distribution [38] GAMS - A Users Guide. Redwood City: Scientific Press 1988. systems. J Water Resour Plan Manage 1989; (115): 737-51. [39] Gnädig B, Steinbach MC. Betriebsoptimierung der Berliner [15] Boulos PF, Wu Z, Orr CH, Moore M, Hsiung P, Thomas D. Trinkwasserversorgung. Study for ABB Utilities GmbH, Optimal pump operation of water distribuion systems using genetic Mannheim. Zuse Institute Berlin 2003. algorithm, H2ONET - Users Guide. MW Software INC 2000. [40] Gnädig B, Steinbach MC. Betriebsoptimierung der Berliner [16] Cembrano G, Wells G, Quevedo J, Perez R, Argelaguet R. Optimal Trinkwasserversorgung mit Gesamtnetzmodell. Study for ABB control of a water distribution network in a supervisory control Utilities GmbH, Mannheim. Zuse Institute Berlin 2004. system. Control Eng Pract 2000; (8): 1177-88. [41] Burgschweiger J, Gnädig B, Steinbach MC. Optimization models [17] Cohen D, Shamir U, Sinai G. Optimal operation of multi-quality for operative planning in drinking water networks. Optim Eng water supply systems - II: The Q-H model. Eng Optim 2000; 32: 2009; 10(1): 43–73. Published online 2008. 687-719. [42] Byrd RH, Gould NIM, Nocedal J, Waltz RA. An algorithm for [18] Guhl F. Gestion optimale des réseaux d’eau potable [dissertation]. nonlinear optimization using and equality L’Université Louis Pasteur 1999. constrained subproblems. Math Program Ser B 2004; 100(1): 27- [19] Sakarya ABA, Mays LW. Optimal operation of water distribution 48. pumps considering water quality. J Water Resour Plan Manage [43] Chin CM, Fletcher R. On the global convergence of an SLP-filter 2000; 126: 210-20. algorithm that takes EQP steps. Math Program 2003; 96(1): 161- [20] Rossman LA. EPANET Users Guide. Cincinnati 1994. 77. [21] Bragalli C, D’Ambrosio C, Lee J, Lodi A, Toth P. An MINLP [44] Fletcher R, de la Maza ES. Nonlinear programming and nonsmooth solution method for a water network problem. IBM Res Div 2006; optimization by successive Linear programming. Math Program RC23893 (W0602-210). 1989; 43(3): 235-56. [22] Hansen CT, Madsen K, Nielsen HB. Optmization of pipe networks. [45] Byrd RH, Nocedal J, Waltz RA. Feasible interior methods using Math Program, Ser B 1991; 52: 45-58. slacks for nonlinear optimization. Comput Optim Appl 2003; [23] Sherali HD, Subramanian S, Loganathan GV. Effective relaxations 26(1): 35-61. and partitioning schemes for solving water distribution network [46] Hackländer P. Integrierte Betriebsplanung von Gasversorgungssys- design problems to global optimality. J Glob Optim 2001; 19(1): temen. Verlag Mainz, Wissenschaftsverlag, Aachen 2002. 1-26. [47] Martin A, Möller M. Cutting Planes for the optimization of gas [24] Young B. Analysis and optimisation of looped water distribution networks. In: Bock HG, Kostina E, Phu HX, Rannacher R, Eds. networks. J Aust Math Soc, Ser B 2000; 41(4): 508-26. Modeling, Simulation and optimization of complex processes. [25 ] Mijaoka S, Funabashi M. Optimal control of water distribution Berlin: Springer 2005; pp. 307-29. systems by network flow theory. IEEE Trans Automat Contr 1984; [48] Möller M. Mixed integer models for the optimisation of gas 29: 303-11. networks in the stationary case [dissertation]. Technische [26] Reinisch K, Thümmler C, Hopfgarten S. Hierarchical on-line Universität Darmstadt 2004. control algorithm for repetitive optimization with predicted [49] Benson HY, Shanno DF, Vanderbei RJ. Interior-Point methods for environment and its application to water management problems. nonconvex nonlinear programming: complementarity constraints. Syst Anal, Model Simul 1984; 1: 263-80. Princeton University 2002; ORFE 02-02. [27] Andersen JH, Powell RS, Marsh JF. Constrained state estimation [50] Fletcher R, Leyffer S. Solving mathematical programs with with applications in water distribution network monitoring. Int J complementary constraints as nonlinear programs. Optim Methods Syst Sci 2001; 32(6): 807-16. Softw 2004; 19(1): 15-40. [28] Laird CD, Biegler LT, van Bloemen Waanders BG, Bartlett RA. [51] Raghunathan AU, Biegler LT. Interior point methods for Time dependent contamination source determination for water mathematical programs with complementarity constraits networks using large scale optimization. J Water Resour Plan (MPCCs)USA. Carnegie Mellon University 2003. Manage 2005; 131(2): 125-34. [52] Scholtes S. Convergence properties of a regularization scheme for [29] de Wolf D, Smeers Y. The gas transmission problem solved by an mathematical programs with complementarity constraints. SIAM J extension of the simplex algorithm. Manage Sci 2000; 46(11): Optim 2001; 11(4): 918-36. 1454-65. [53] Stein O, Oldenburg J, Marquardt W. Continuous reformulations of [30] Ehrhardt K, Steinbach MC. Nonlinear optimization in gas discrete-continuous optimization problems. Comput Chem Eng networks. In: Bock HG, Kostina E, Phu HX, Rannacher R, Eds. 2004; 28(10): 1951-66. Modeling, Simulation and Optimization of Complex Processes. [54] Ehrhardt K, Steinbach MC. KKT Systems in operative planning for Berlin: Springer 2005; pp. 139-48. gas distribution networks. Proc Appl Math Mech 2004; 4(1): 606-7.

Received: September 15, 2008 Revised: November 21, 2008 Accepted: January 11, 2009

© Burgschweiger et al.; Licensee Bentham Open.

This is an open access article licensed under the terms of the Creative Commons Attribution Non-Commercial License (http://creativecommons.org/licenses/by- nc/3.0/), which permits unrestricted, non-commercial use, distribution and reproduction in any medium, provided the work is properly cited.