Improved water distribution systems design and operating methodologies using fast steady state network solvers by Ellis, D.J. and Simpson, A.R.
Hydrastorm’98 Conference
Citation: Ellis, D.J. and Simpson, A.R. (1998). “Improved water distribution systems design and operating methodologies using fast steady state network solvers”. Hydrastorm’98 Conference, The Institution of Engineers Australia, Adelaide, Australia, 27-30 September, 317–322. For further information about this paper please email Angus Simpson at
[email protected]
HydraStorm '98 Adelaide, Australia 27-30 September, 1998
Improved water distribution systems design and operating methodologies using fast steady state network solvers David J. Ellis and Dr Angus Simpson The University of Adelaide
Summary: This paper examines the behaviour of the Linear Theory Method, Newton-Raphson method and a Linear Theory Newton-Raphson hybrid technique applied to the flows (Q), unknown nodal heads (H) and loop corrective flow (AQL) formulations of the pipe network equations. An insight into the paradigm about the need to provide a starting point "sufficiently close" to the solution is provided. The investigations show clearly that the initial starting vector chosen for the iteractive solution procedure has a signifiucant effect on the speed of convergence for all three numerical solution techniques with and all three equation formulations.
INTRODUCTION Water distribution systems in Australia represent a significant portion of the total cost of physi cal infrastructure. The growing need for the reduction in the capital operating and maintenance costs of such infrastructure has required new design and operating methodologies to be developed. The performance of these new design and operating methodologies will be significantly enhanced with faster and more efficient steady state solvers for simulating water distribution systems networks. The analysis oflooped pipe networks for steady state flows and pressures involves solving a number of simultaneous, nonlinear equations which in general do not have explicit solutions. It is necessary then to adopt an iterative solution technique. Prior to the development of computers the iterative , solution of the equations was an immense task. With arrival of computers the task has become less difficult. Many pipe network computer programs are now commercially available (eg. WATSYS, H20NET, KYPIPE EPANET and Stoner SWS) which use the pipe network equations in various forms and employ a range of solution techniques. The speed of Solution of these equations has become an important issue. Recent developments in design, operation and optimisation ~ethodologies (especially genetic algorithm optimisation of PI~enetworks) require the fastest possible solution techniques. It IS often necessary to solve the network equations hundreds of thousands oftimes, Simpson, et al.(I). Other important areas of application of fast pipe network solvers are irrigation O~dering fOT piped systems and real time simulation of water dIstribution system operation.
~~ this
paper the efficiency of the Linear Theory Method
l'h™), the Newton-Raphson method (NR)and the Linear eory Method-Newton-Raphson hybrid method (L TM-NR) are · . InvestIgated. The methods have been used to solve for ~nknown steady state flows and pressures in the unknown OWs (Q), unknown nodal heads (H) and loop corrective flow
(..1 QL) formulations of the pipe network equations, developed for a simple pipe network. The H formulation requires the solution of fewer simultaneous equations than the Q formulation does, however, the equations in the H formulation are all non-linear. For larger networks the ..1 Ql formulation has, in general, fewer equations, than either the Q or H formulations. All of the equations in the ..1 QL formulation are non-linear.
BASINS OF ATTRACTION CONSTRUCTION The concept of basins of attraction is useful for describing the global performance (robustness) of a numerical solver, Bums and Locasio (2). Basinslab is a computer program for creating basins of attraction plots based on the research developments of the Algorithm Visualisation Laboratory at the University of Illinios at Urbana-Champaign. The program enables one to visualise the performance of iterative numerical methods in solving an equation or a set of equations. The set of starting points which result in convergence to a particular solution under the action of the solver is called the basin of attraction of that solution. Basinslab uses a two dimensional lattice of thousands of starting points to produce a basin of attraction image. Basins of attraction are specific to the pipe network geometry, formulation of the governing equations, the iterative solution technique being employed and the convergence criterion chosen. The development of computer graphics programs such as Basinslab has enabled the exploration of the behaviour of iterative solvers by the visual representation of large amounts of data. Iterative numerical methods do not always exhibit swift, stable convergence to the solution from any starting point that happens to be chosen. The sequence of iterations may stall or become trapped in an endless limit cycle (where the iterations These visit the same sequence of values repeatedly). behaviours may occur with the same solver depending on the
317
starting point that is chosen. The proximity of the starting point to the solution is not a guaranteed measure of the number of iterations required by the solver to reach the solution. Depending on the selection of the starting point for the iterative solution procedure, different numbers of iterations are required to reach a particular solution and this has a significant impact on the efficiency of pipe network analysis.
NUMERICAL :METHODS Selecting the best numerical technique to solve a particular problem is a difficult task. Generally, the methods which perform best are those which exploit the structure of the specific problem being solved, Press, et al. (3). Different numerical methods can be compared by considering the number of iterations required for tIle solution to be reached with the desired accuracy and the ability to converge to a solution from a wide range of starting points. This is known as the global performance or robustness of a numerical solver. The global performance of particular methods can be determined through plotting an image of the basin of attraction. TIlis paper considers t]uee methods that have been used previously in computer hydraulic network analysis software for solving pipe network equations in the design of pipe networks. The first method, The Linear Theory Method was developed by Wood and Charles (4). The second method
EL.=40m
--".
--
Path 1 ___)
AQ"
- '.
Q,
..........
- -.....
node 2 \.
l~
AQ,.
~-
Figure 1 :Four Pipe Network is the Newton~Raphson method. The third method evaluated in this paper is a hybrid technique originally proposed by Nielsen (5) which uses the Linear Theol)' Method of Wood and Charles (4) for the fIrst iteration followed by the Newton~Raphson method for all subsequent iterations. Wood and Charles (6) in a closure to discussion of their 1972 paper introduced an altemative solution method whiell they referred to as a gradient technique based on a Taylor's series expansion of the non~linear head loss. This gradient technique was further investigated by Fietz (7) and was implemented in KYPIPE, Wood (8). It has been referred to as the "Linear Method" by Wood and Rayes (9) and as the "modified linear
318
method" by Ormsbee and Wood (10). There has been llluc confusion of these methods with the LTM, however 01 investigation has shown that these methods are not the origin. Linear Theory Method of 1972. Salgado et al (1.1) and Salgad et al ( 12) also made this observation. Wood and Funk (I: revisited the wo rk presented in Wood and Rayes (9) and i addition to the original paper provide the algorith.ms for tb various techniques investigated, from which it is clear that th algorithm used in the Wood and Rayes (9) and the Wood an Funk (13) paper is based on a Taylor's series expansior Examination of the KYPTPE SO UTce code, Wood (8); Woo< ( 14) reveals that this method is actually the N ewton~RaphsoJ method. A great deal of confusion is ev ident in the literature La nsey and Mays ( 15); Ki m (16) sUlTounding the differenc! between the Wood and Charles (4) origi nal linear theon method and that used in KYPJPE. .
RESULTS In this section a visual insight is presented of the behaviour 01 the LTM and NR methods applied to the different formulations of the pipe network equations for the simple four pipe network (Fig. 1). Basin of attraction images have been produced in black and white throughout the results (a]though the original images are in color). In the figures, the starting points which result in an odd number of iterations for the path to converge with the required accuracy are shown as black whilst those requiring an even number of iterations are shown as white. The analytical solution (attractor) in each of the images has been denoted. A dual convergence criterion has been used in order to determine when to tenninate the iterative process. Continuity at the nodes was required to within a tolerance of 0.000 I m3/s (0.1 LI s) and a head loss balance around loop I and path I was required to within a tolerance of 0.0] m. Theset of equations for the Q formulation explicitly contain the linear continuity equations which are solved simultaneously with the linearized non-linear equations in either the LTM or NR method and thus El.=20m I the condition of continuity is satisfied after a single iteration. In the L1 Q£ formulation the initial flows Qo ,s provided must satisfy continuity thus flows at all subsequent iterates satisfy continuity. The criteria of headloss around the loops governs in Q and L1 Ql formulations, however continuity at the nodes is the governing criteria for the H fonnulation. If oniy the headloss around the ioops is tested for with the H formulation convergence to an incorrect point which does not satisfy continuity at the nodes may result. Many such poin~ may exist within the feasible solution space and can occur In close proximity to the actual solution. The tolerance valUes chosen for each of the convergence criteria prodUced convergence fro m tests results to a similar accuracy for the different formulations in which they govern. An alternate method used in KYPIPE, Wood (11) and EPANET, Ross~ (17) for testing the convergence is the 'average' chan~e I~ flowrate between successive iterates. Each of the baSIn : attraction constructions presented here has a field of 201 . ; 201 pixels, which results in 40,401 different starting ~I~ combinations. The pixels create a lattice of starting poln within the selected bounds. The bounds for each image have
,
grid reference of the pixel and the other two were taken as 28.03 Lis for both the L TM and the NR method. Fig. 2 shows
been chosen as metres for the H formulation and Lis for the .Q and LI Ql formulations. Each pixel is assigned values which are its grid reference. TIle grid reference values are detemlined by the number of pixels and the bounds.
the basin ofattraction image for the LTM. Itis symmetric about the Q2 and Q3 axes. Singularity of the matrix occurs in the Q formulation when all the flows in a loop or path are simultaneously equal to zero. This is evident where the flow in pipes 2 and 3 simultaneously equal zero. The image ofthe NR method in Fig. 3 reveais a complex pattern which has clear banding where the number of iterations required to reach the solution is seen to fluctuate as the start vector moves away from the solution.
The Q formulation provides six possible pairs of flows. The images of one of the pairs (Q2' Q3) are presented in this paper. The four unknown pipe Q's were solved for simultaneously. The starting point of two of the unknown Q's was taken as the
singularity error
7 iterati