You are on page 1of 16

8th Annual Water Distribution Systems Analysis Symposium, Cincinnati, Ohio, USA, August 27-30, 2006

ON THE CONVERGENCE PROPERTIES OF THE DIFFERENT PIPE NETWORK ALGORITHMS


Ezio Todini
Dipartimento di Scienze della Terra e Geologico-Ambientali, University of Bologna Bologna, Italy e-mail: todini@geomin.unibo.it

Abstract
Scope of this paper is to propose a unified insight to the problem of solving the looped water distribution systems non-linear hydraulic equations as well as to compare the convergence of the different resulting algorithms. After showing that the problem can be formulated as the solution of a system of equations, partly linear and partly non-linear, it will be demonstrated how most of the widely used algorithms for the analysis of looped pipe networks, can be formulated in terms of a gradient search approach and can be derived from the Global Gradient (Todini and Pilati, 1987) by simple linear transformations. For the sake of simplicity, the problem of analysing a looped pipe network will be defined on the absence of minor losses, pumps, valves and other concentrated dissipation devices, which may however be introduced without affecting the substance of the results. It will be shown how the different solution methods can be classified according to the space of the state variables used as unknowns (the pipe flows, the nodal heads, the mesh residual flows), and can be divided into two main categories: a first group incorporating the flow based algorithms (the Linear Theory, Wood and Charles, 1972; the Simultaneous Loop, Epp and Fowler, 1970; Kesavan and Chandrashekar, 1972; the Global Gradient, Todini and Pilati, 1987) and a second group based on the Nodal Heads (Martin and Peters, 1963, Shamir and Howard, 1968). Using an extremely simple example, the paper shows that all the flow based algorithms have exactly the same convergence properties ,in that they require the same number of non-linear Newton-Raphson steps to reach exactly the same result. Therefore, the computer time consumption only depends on the dimension of the space on which the problem is solved (the nodes, the pipes, the meshes) and on the symmetry and the sparsity of the resulting system matrix. This does not happens when the nodal head solvers are used. In this case the convergence properties of the Newton-Raphson algorithm are affected by the different concavity of the resulting functions, with the consequence of generating less convergent algorithms, which never reach the convergence properties of the flow based ones, even if corrected with relaxation coefficients (and Wolla 1972; Lemieux,1972; Donachie, 1974).

Keywords
Pipe network analysis, looped pipe network algorithms, Global Gradient, Linear Theory, Simultaneous Loops, Nodal Head solvers

1. INTRODUCTION
The analysis of a looped water distribution network, operating under pressure in steady flow conditions, can be accomplished given the topology of the network, the geometry of the pipes, the discharges delivered at the nodes and the head value at least one node. Historically, the search for the most efficient algorithm, or rather the one which offers the most rapid convergence, has the lowest computational requirements and is the most "robust", i.e. which is able to reduce the number of cases in which the search for the solution fails, stretches over a period extending

1 Copyright ASCE 2006 Water Distribution Systems Analysis Symposium 2006


Downloaded 06 Jun 2012 to 143.106.52.210. Redistribution subject to ASCE license or copyright. Visit http://www.ascelibrary.org

8th Annual Water Distribution Systems Analysis Symposium, Cincinnati, Ohio, USA, August 27-30, 2006

from the application of local linearization methods in the 1930's (Cross, 1936) right down to the present day and the development of simultaneous linearization techniques, i.e. techniques applied to all the equations in the system simultaneously. Probably, the most comprehensive approach to the problem is the one set out by Collins et al. (1978), entailing the definition of the "content" model, i.e. the definition of a functional in terms of discharge flowing through the branches of the network, or of its dual model (the co-content) in terms of head values at the nodes. The network analysis problem is accordingly reduced to the search for the minimum of the functional (either in terms of discharge in the branches or in terms of head at the nodes) which is performed by means of numerical least-squares techniques such as those proposed by Collins et al. (1978) and by Contro and Franzetti (1983), or alternatively by solving the system of equations simultaneously in terms of both the discharge and head values, as proposed by Todini, (1979), Todini and Pilati (1987). The search for the minimum solution of the content model by means of mathematical programming algorithms is particularly laborious, given the large number of variables present in real cases, therefore, given the convexity of the content functional, which guarantees the existence and the uniqueness of the solution, linearization of the non-linear equations can be performed efficiently by means of the NewtonRaphson gradient techniques, reducing the problem to the iterative solution of a system of linear equations. Accordingly a wide variety of algorithms have been developed which differ from each other in terms of the unknowns used in the differentiation of the original system. Basically, four different algorithms can be found in the literature, which characterise the solution algorithm, according to the selected unknowns: 1) The Global Gradient Algorithm [G] (Todini, 1979, Todini and Pilati, 1987; Salgado et al 1987; Salgado, 1988) in which the unknowns are all the pipe discharges Q, totalling n p , the number of 2) 3) pipes, plus all the head values at the nodes H totalling n n the number of nodes. The Linear Theory algorithm [LT] (Wood and Charles, 1972), in which the unknowns are all the pipe discharges Q totalling n p the number of pipes.

The Simultaneous Loop algorithm [L] in which the unknowns are all the loop discharges QL, totalling n l the number of closed loops. This algorithm can be seen as an extension of the Cross (1936) method from local (loop by loop and iterative) to simultaneous (all the loops at the same time) (Epp and Fowler, 1970; Kesavan and Chandrashekar, 1972). 4) The Newton Raphson Nodal algorithm [H] (Martin and Peters, 1963; Shamir and Howard, 1968; Mignosa, 1987), in which the unknowns are all the head values at the nodes H totalling n n the number of nodes. Scope of this paper is to illustrate and discuss the convergence properties of all these algorithms, which share the common need to solve a system of linear equations several times in order to reach, iteratively and by means of successive approximations, the solution of the original partly linear and partly non-linear system of equations. It will be shown that the convergence depends on the size of the linear system to be solved together with the information that has to be provided to formulate it and to identify the first-guess solution (if required) to initiate the iterative process.

2. A GENERAL MATHEMATICAL FORMULATION: THE GLOBAL GRADIENT ALGORITHM


Following the formulation given in Todini (1979), Todini and Pilati (1988), the minimisation of the Collins et al. (1978) content leads to the following system of equations describing a general looped water distribution network problem:

2 Copyright ASCE 2006 Water Distribution Systems Analysis Symposium 2006


Downloaded 06 Jun 2012 to 143.106.52.210. Redistribution subject to ASCE license or copyright. Visit http://www.ascelibrary.org

8th Annual Water Distribution Systems Analysis Symposium, Cincinnati, Ohio, USA, August 27-30, 2006

A11 M A12 Q A10 H 0 K L L L = L 0 H q A 21 M

(1)

with

Q T = [Q1 , Q2 , L , Qn p ]
H T = [ H1 , H 2 ,L , H nn ]
H T = [ H n n +1 , H n n + 2 ,L , H n t ] 0 q = [ q1 , q2 ,L , qn n ]
T

the [1, n n ] unknown pipe discharges the [1, n n ] unknown nodal heads the [1, n t n n ] known nodal heads the [1, n n ] known nodal demands is the total

where n p is the number of pipes; n n is the number of nodes with unknown head; n t number of nodes in the network; n t n n is the number of nodes with known head.

In equation (1) A 11 is a diagonal matrix which elements, including minor losses, are defined for

k 1, n p ; i 1, n t ; j 1, n t as:

A 11 (k , k ) = r Qij
for pipes and:

n 1

+ m Qij
n

(2)

A11 (k , k ) = 2 (h0 r (Qij )

)Q

ij

or A 11 (k , k ) = (a0 2 Qij + b0 + c0Qij ) (3)

(or other similar equations) for pumps (Salgado et al., 1988). Note that in reality all the coefficients, r , m, n, , a0 , b0 , c0 are relevant to specific pipes or pumps; the i,j indexes have been omitted to more closely follow their representation given in EPANET 2 (Rossman, 2002). The actual network topology is then described by means of a topological incidence matrix A12 defined as follows:

1 A12 (i, j ) = 0 + 1

if the flow of pipe j leaves node i if pipe j is not connected to node i if the flow of pipe j enters node i
(4)

The uniqueness of the solution of equation (1) requires at least one node with known head. The overall incidence matrix, which is an [n p , n t ] matrix, can thus be partitioned into the two matrices,

A12 = [A12 M A10 ]


T T the sake of clarity the following notation is used A10 = A 01 and A12 = A 21 .

(5)

relating the pipes to the nodes with unknown head ( A12 ) and to the nodes with known head ( A10 ). For

The derivation of the Global Gradient Algorithm [G], Todini and Pilati (1988), is based upon the simultaneous differentiation of the entire system of equations with respect to the pipe discharges and to the nodal heads, to give:

3 Copyright ASCE 2006 Water Distribution Systems Analysis Symposium 2006


Downloaded 06 Jun 2012 to 143.106.52.210. Redistribution subject to ASCE license or copyright. Visit http://www.ascelibrary.org

8th Annual Water Distribution Systems Analysis Symposium, Cincinnati, Ohio, USA, August 27-30, 2006

D11 M A12 dQ dE K L L L = L 0 dH dq A 21 M
n 1

(6)

where D11 is a diagonal matrix which elements are defined for k 1, n p ; i 1, n t ; j 1, n t as:

D11 (k , k ) = nr Qij for pipes and:

+ 2m Qij
n1

(7)

D11 (k , k ) = nr 2n Qij

or

D11 (k , k ) = (b0 + 2c0Qij )

(8)

for pumps according to the chosen model. Equation (6) can be written, assuming a local linearization between the solution at iteration and that at iteration + 1 , by defining:
dQ = Q Q +1 dH = H H +1 dE = A11Q + A12 H + A10 H 0 dq = A 21Q + A 22 H + q
(9)

Substituting for equations (9) into equation (6) and analytically solving the system of equations, the iterative formulation of the Global Gradient Algorithm [G] can be found:

H +1 = A 1 F Q +1 = Q D1 (A Q + A H +1 + A H ) 11 11 12 10 0
where:
1 A = A 21D11 A12

(10)

(11)

and
1 1 F = A 21Q + q A 21D11 A11Q A 21D11 A10 H 0

(12)

Matrices A and F can be filled, by defining

pij =

nr Qij

n1

+ 2m Qij

and

yij = pij r Qij

n 1

+ m Qij

)
n

(13)

for pipes and:


pij =
or

1
nr
2n

Qij

n 1

and

yij = pij 2 h0 r (Qij )

)Q

ij

(14)

4 Copyright ASCE 2006 Water Distribution Systems Analysis Symposium 2006


Downloaded 06 Jun 2012 to 143.106.52.210. Redistribution subject to ASCE license or copyright. Visit http://www.ascelibrary.org

8th Annual Water Distribution Systems Analysis Symposium, Cincinnati, Ohio, USA, August 27-30, 2006

pij =

1 b0 + 2c0Qij

and

yij = pij (a0 2 Qij + b0 + c0Qij )

(15)

for pumps, according to the chosen model given by equations (3), and following the notation used by

Rossman (2002) in EPANET 2.


Note that, in order to avoid sign problems a slightly different definition of yij is used in this paper, namely:

yij =

yij
Qij

(16)

where yij is the expression defined in EPANET 2 manual (Rossman, 2002). With the given notations it is possible to fill the matrix A and vector F as follows:
A(i, i ) =

p
j

ij

i j , i 1, n n , j 1, n t

(17) (18)

A(i, j ) = pij
F(i ) =

i j , i, j 1, n n

(1 y )Q
ij j

ij

+ qi +

p H
if f

i 1, n n i j , j 1, n t i f , f n + 1, n n t

(19)

Although the initial unknowns involved in equation (1) are n p + n n , i.e. the n n head values at the nodes and the n p pipe discharges, the problem has been transformed into equation (10), which only requires the iterative solution of A , a symmetrical and sparse matrix of size [n n , n n ] , given that the inverse of the diagonal matrix D11 is trivial, and the remaining are vector matrix products that can be easily

and efficiently performed in scalar form. 3. THE LINEAR THEORY AND THE SIMULTANEOUS LOOPS ALGORITHMS
T If one defines the loop incidence matrix M 31 = M 13 as the

[n n , n p ]

matrix with the following

properties:

1 if flow of pipe i flows clockwise in loop k M 31 (i, l ) = 0 if pipe i does not pertain to loop k 1 if flow of pipe i flows anti - clockwise in loop k

(20)

by, making appropriate use of topological properties linking nodes, branches and loops in a network, namely A 21M 13 = 0 , M 31 A12 = 0 , A 01M 13 = 0 and M 31 A12 = 0 , it is possible to project the system of equations (1) onto vector bases different from the original base of size n p + n n as in equation (1). For instance, if one pre-multiplies both sides of equation (1) by the following matrix,

5 Copyright ASCE 2006 Water Distribution Systems Analysis Symposium 2006


Downloaded 06 Jun 2012 to 143.106.52.210. Redistribution subject to ASCE license or copyright. Visit http://www.ascelibrary.org

8th Annual Water Distribution Systems Analysis Symposium, Cincinnati, Ohio, USA, August 27-30, 2006

M 31 M 0 K L L M I 0
Where I is an [n n , n n ] identity matrix, namely:

(21)

M 31 M 0 A11 M A12 Q M 31 M 0 A10 H 0 K L L K L L L = K L L L M I A 21 M M I q 0 H 0 0

(22)

The following result can be obtained, taking into account the mentioned topological properties:

M 31 A11 0 K [Q] = L A 21 q

(23)

And, by differentiating both sides of equation (23), one obtains the following result: M 31 D K [dQ ] = LT A 21 dE LT L dq LT

(24)

Equation (24) can be written, assuming a local linearization between the solution at iteration and that at iteration + 1 , by defining:
+ dQ LT = Q LT Q LT1 dELT = M 31 A11Q LT

(25)

dq LT = A 21Q

LT

+q

to give the Linear Theory Algorithm [LT]:

+ Q LT1

M 31D = Q LT K A 21

M 31 A11Q LT L A 21Q LT + q

(26)

The original problem of equation (1) is thus transformed into the iterative solution of a linear system of equations, with a non-symmetrical, albeit sparse, system matrix of size [n p , n p ] . Improvements in terms of system matrix size and properties can be obtained with an additional linear transformation, which originates the Simultaneous Loop Algorithm.

6 Copyright ASCE 2006 Water Distribution Systems Analysis Symposium 2006


Downloaded 06 Jun 2012 to 143.106.52.210. Redistribution subject to ASCE license or copyright. Visit http://www.ascelibrary.org

8th Annual Water Distribution Systems Analysis Symposium, Cincinnati, Ohio, USA, August 27-30, 2006

If one substitutes for Q = M13Q L in equation (23), where Q L is the so-called loop discharge, namely the spurious discharge originating in an unbalanced mesh, bearing in mind that M 31 A12 = 0 , owing to the topological properties of matrix M 13 , one obtains:

[M 31 A11M13 ][Q L ] = 0
By differentiating both sides of equation (27), one obtains the following result:

(27)

[M 31D M13 ][dQ L ] = [dEL ]

(28)

Equation (28) can be written, assuming a local linearization between the solution at iteration and that at iteration + 1 , by defining:
dQ L = Q L Q L+ 1 dE L = M 31 A11M 13Q L

(29)

to give the Simultaneous Loop Algorithm [L]:


Q L+1 = Q L [M 31 D M 13 ] [M 31 A 11M 13Q L ] 1

(30)

The original problem of equation (1) is now transformed into the iterative solution of a linear system of equations, with a sparse symmetrical system matrix of size [n l , n l ] .

It is interesting to note that the Simultaneous Loop Algorithm can be re-projected back on the pipes by pre-multiplying equation (30) by M 13
M 13Q L+ 1 = M 13Q L M 13 [M 31D M 13 ] [M 31 A11M 13Q L ]

(31)

and by substituting back for Q LT = M 13Q L to produce an Improved Linear Theory Algorithm [ILT], which only requires the iterative inversion of a symmetrical matrix of size [n l , n l ]
+ Q LT1 = Q LT M 13 [M 31 D M 13 ] [M 31 A 11Q LT ]

(32)

4. THE NODAL HEAD GRADIENT ALGORITHMS


To derive the basic Nodal Head Gradient algorithm, Equation (1) can be re-written as:

A11Q + A12 H = A10 H 0 A 21Q = q

(33)

And using the first of the two equations it is possible to derive an expression for Q , the pipe discharge vector:

7 Copyright ASCE 2006 Water Distribution Systems Analysis Symposium 2006


Downloaded 06 Jun 2012 to 143.106.52.210. Redistribution subject to ASCE license or copyright. Visit http://www.ascelibrary.org

8th Annual Water Distribution Systems Analysis Symposium, Cincinnati, Ohio, USA, August 27-30, 2006

1 Q = A11 [A12 H + A10 H 0 ]

(34)

to be substituted into the second equation, to give:


1 A 21 A11 [A12 H + A10 H 0 ] = q

(35)

which can be re-written as:

[A

21

1 1 A11 A12 ]H = q A 21 A11 A10 H 0

(36)

Differentiating both sides of equation (36), one obtains the following result:

[A

21

D11 A12 ][dH H ] = [dq H ]

(37)

Equation (37) can be written, assuming a local linearization between the solution at iteration and that at iteration + 1 , by defining:
dH H = H H H H+1

1 1 dq H = A 21 A11 A12 H H q + A 21 A11 A10 H 0

(38)

to give the Nodal Head Gradient algorithm [H]:


1 1 H H+ 1 = H H [A 21D11 A12 ] [A 21 A11 A12 H H q + A 21 A11 A10 H 0 ] 1

(39)

The original problem of equation (1) is thus transformed into the iterative solution of a linear system of equations, with a sparse symmetrical system matrix of size [n n , n n ] .

5. COMPUTATIONAL SPEED AND CONVERGENCE PROPERTIES


The analysis of the computational speed and the convergence properties of the different algorithms can be assessed on the basis of the following issues to be discussed in the sequel: 1) Non-linear system convergence 2) Linear system solution 2.1) Dimension of linear system matrix 2.2) Symmetry of linear system matrix 2.3) Sparsity of linear system matrix 3) Need for the definition of independent loops 4) Need for an initial balanced solution 5.1. Non-linear system convergence The Linear Theory, the Simultaneous Loops and the Improved Linear Theory algorithms, were obtained via simple linear transformation from the original set of equations (1) which is directly used to derive the Global Gradient. Therefore they will show exactly the same convergence properties in terms of the

8 Copyright ASCE 2006 Water Distribution Systems Analysis Symposium 2006


Downloaded 06 Jun 2012 to 143.106.52.210. Redistribution subject to ASCE license or copyright. Visit http://www.ascelibrary.org

8th Annual Water Distribution Systems Analysis Symposium, Cincinnati, Ohio, USA, August 27-30, 2006

Newton-Raphson steps, since the curvature of the original functional, which is linear in terms of the nodal heads and non-linear, with an exponent grater than one, for the pipe discharges, is not modified by linear transformations. On the contrary, the Nodal Head Gradient approach, is obtained via a non-linear transformation, due to the fact that matrix A11 , which is inverted in equation (34) is a function of Q and after substituting for equation (34) into the second of equations (33) the non-linearity is characterised by positive and smaller than one exponents. As can be seen from Figure 1b, this creates the conditions for a slow alternate convergence (Stoer and Burlish, 1980).
10 10

f(x2)

8 6 4 2 0

f(x1/2)

8 6 4 2

-4

-3

-2

-1 -2 -4 -6 -8 -10

0 4 -4 -3 -2 -1 -2 -4 0 1 2 3

(a)

-6 -8 -10

(b)

Figure 1. Convergence of the Newton-Raphson algorithm shown for functions characterised by exponent larger than one (a) and smaller than one (b). (1a) One side convergence: when the exponent is larger than one the convexity enhances the performances of the N-R algorithm resulting in a high rate of convergence; (1b) Alternate convergence: when the exponent is smaller than one the convexity reduces the performances of the N-R algorithm resulting in a low rate of convergence. This undesired property was discussed by several authors (Shamir and Howard, 1968; Lamm and Wolla 1972; Lemieux,1972; Donachie, 1974; Mignosa, 1987), who proposed the use of over-relaxation coefficients in order to improve the rate of convergence of the Nodal Head Gradient.
1 1 H H+ 1 = H H* [A 21D11A12 ] [A 21 A11 A12 H H* q + A 21 A11 A10 H 0 ] * 1

(40)

This has given rise to an additional algorithm, the pre-conditioned Nodal Head Gradient [H#], with improved performances with respect to the original [H], but still less convergent, in terms of non linear steps, than the previous group [G], [LT], [L], [ILT].
5.2. Linear system solution As one can see from the equations describing the different recursive algorithms (10), (26), (30), (32), (39), and (40), each non-linear iteration corresponds to the solution of a linear system of equations. The size, the symmetry and the sparsity of the resulting matrix has a strong impact on the computer time requirements. The Linear Theory [LT] is the less convenient in this respect, since it requires the solution of a linear system with a sparse but non-symmetrical matrix of size [n p , n p ] with n p the number of pipes. The Global Gradient [G], the Nodal Head Gradient [H] and the pre-conditioned Nodal Head Gradient [H#] algorithms, require the solution of a linear system with a sparse symmetrical matrix of size [n n , n n ] with n n the number of nodes with unknown head.

9 Copyright ASCE 2006 Water Distribution Systems Analysis Symposium 2006


Downloaded 06 Jun 2012 to 143.106.52.210. Redistribution subject to ASCE license or copyright. Visit http://www.ascelibrary.org

8th Annual Water Distribution Systems Analysis Symposium, Cincinnati, Ohio, USA, August 27-30, 2006

The Simultaneous Loop [L] and the Improved Linear Theory [ILT] algorithms require the solution of a linear system with a sparse symmetrical matrix of size [n l , n l ] with n l the number of independent loops. In terms of computer time it is evident that the [LT] is the most demanding one, due to the size and the non-symmetry of the matrix. In theory the [L] and the [ILT] algorithm should be the less computer time demanding, due to the generally smaller number of independent meshes with respect to the number of unknown head nodes. Nonetheless, it has been reported that it is not so due to the increased density of the matrix (the number of extra-diagonal non zero elements is the same as in the case of the [n n , n n ] matrix ) that reduces the benefits of the sparsity by increasing its fill-in (Carpentier et al., 1987). 5.3. Need for the definition of independent loops
T The [LT], [L] and [ILT] also require the definition of matrix M 31 = M13 , a matrix describing the topology of the chosen set of independent meshes. Several algorithms can be found in the literature to produce this matrix (Carpentier et al. 1987), which is not unique. It is not a complex problem but still it implies the definition of virtual loops, particularly when multiple reservoirs are present, and some computational time to produce efficient loop definitions, which can be comparable to the one needed for a non-linear iteration. On the contrary the [G], the [H] and the [H#], which in practice solve the matrix on the node space, do not require this preliminary computation.

5.4. Need for an initial balanced solution The loop based algorithms, such as [L] and [ILT], require the initial computation of a mass balanced solution in terms of pipe flows, while all the other algorithms [LT], [G], the [H] and the [H#], do not suffer from this necessity. Again, this is a need that implies a computation which can be estimates as the one needed for one non-linear iteration.

6. NUMERICAL EXPERIMENTS
The verification of the above mentioned convergence properties was conducted via numerical simulation based on an extremely simplified network scheme (5 nodes and 7 pipes) schematically shown in Figure 2. Table 1 provides the relevant hydraulic data. The following tests were performed: 1 - Network analysis using the different algorithms starting with the same initial solution; 2 - Network analysis using the different algorithms starting with 100 initial solutions randomly generated around the true solution of the problem The compared algorithms were the six discussed above, namely [G], [LT], [L] and [ILT], [H] and [H#]. In the case of [H#] an optimal value for the relaxation coefficient, which was found to be = 0.7 ,was used. Table 1. Hydraulic data relevant to the test case PIPES Q [l s-1] r [ m-5 s ] x 106 NODES -4 1 800 1.5625 10 0 2 200 5.0000 10-5 1 3 100 1.0000 10-2 2 4 400 1.2500 10-5 3 5 200 7.5000 10-4 4 6 100 2.0000 10-2 7 100 1.0000 10-2 q [ l s-1] -1000 100 200 300 400 H [m] 100 99 98 97 96

10 Copyright ASCE 2006 Water Distribution Systems Analysis Symposium 2006


Downloaded 06 Jun 2012 to 143.106.52.210. Redistribution subject to ASCE license or copyright. Visit http://www.ascelibrary.org

8th Annual Water Distribution Systems Analysis Symposium, Cincinnati, Ohio, USA, August 27-30, 2006

1000 l/s

0
800 l/s 1 100 l/s 3

200 l/s 2 200 l/s

2
100 l/s

2
400 l/s 4

3
200 l/s

100 l/s

300 l/s

100 l/s

400 l/s

Figure 2. Schematic representation of the looped pipe network used in the numerical example 6.1. Network analysis starting with the same initial solution The simulation results are given on a number of selected nodes and pipes, since the behaviour of the other is quite similar. Figures 3 and 4 show the trend in the head values at nodes 2 and 4; Figures 5 and 6 show the corresponding results in terms of computed demand while Figures 7 and 8 show the computed pipe discharges, at the successive Newton-Raphson iteration steps. In all the figures, the solid line represents the behaviour of the [H] algorithm, the dashed line the behaviour of the [H#] algorithm, while the dotted line describes the identical behaviour of the other four algorithms, namely [G], [LT], [L] and [ILT]. It is easy to see from the figures the performance of the [G], [LT], [L] and [ILT] approaches in terms of stability of solutions and of rate of convergence: the final solution is reached with the required accuracy (10-6 l s-1) in 7 steps as opposed to the 24 of the [H#] scheme and the 60 iterations necessary to the [H] scheme. 6.2. Network analysis starting with 100 randomly generated initial solutions With a view to generalising this study and analysing whether the convergence properties are influenced by the initial nodal head guess solution, 100 different initial solutions were generated, adding to the true solution of the problem a zero mean uniform random error component in the range 50 m. For each of the six methods examined, the problem was solved 100 times, starting each time with a different initial solution and the distribution of the histogram of the number of iterations required to reach convergence is shown in Figure 9. Once again the four methods [G], [LT], [L] and [ILT] give exactly the same results and perform better than [H] and [H#]. The experiments indisputably show the greater dependence of the [H] method on the initial solution with a wide spread of the number of iterations that can reach 110 iterations even in the case of the extremely simple network analysed. A marked improvement is achieved by using the [H#] with an optimal value for : the number of iterations now centres around 23-24 iterations with a modest dispersion of between 22 and 25; however, it should be stressed that the optimal parameter value for one network cannot be generalised. Finally one

11 Copyright ASCE 2006 Water Distribution Systems Analysis Symposium 2006


Downloaded 06 Jun 2012 to 143.106.52.210. Redistribution subject to ASCE license or copyright. Visit http://www.ascelibrary.org

8th Annual Water Distribution Systems Analysis Symposium, Cincinnati, Ohio, USA, August 27-30, 2006

should appreciate the optimal performance of the other four algorithms [G], [LT], [L] and [ILT] that show a narrow histogram with a minimum dispersion between 5 and 7 iterations and a mean of 6.

Figure 3. Node 2 convergence of the different algorithms in terms of nodal head H. [H] Solid line; [H#] Dashed line; [G] = [LT] = [L] = [ILT] Dotted line

Figure 4 - Node 4 convergence of the different algorithms in terms of nodal head H. [H] Solid line; [H#] Dashed line; [G] = [LT] = [L] = [ILT] Dotted line

12 Copyright ASCE 2006 Water Distribution Systems Analysis Symposium 2006


Downloaded 06 Jun 2012 to 143.106.52.210. Redistribution subject to ASCE license or copyright. Visit http://www.ascelibrary.org

8th Annual Water Distribution Systems Analysis Symposium, Cincinnati, Ohio, USA, August 27-30, 2006

Figure 5. Node 2 convergence of the different algorithms in terms of nodal head H. [H] Solid line; [H#] Dashed line; [G] = [LT] = [L] = [ILT] Dotted line

Figure 6. Node 4 convergence of the different algorithms in terms of nodal head H. [H] Solid line; [H#] Dashed line; [G] = [LT] = [L] = [ILT] Dotted line

13 Copyright ASCE 2006 Water Distribution Systems Analysis Symposium 2006


Downloaded 06 Jun 2012 to 143.106.52.210. Redistribution subject to ASCE license or copyright. Visit http://www.ascelibrary.org

8th Annual Water Distribution Systems Analysis Symposium, Cincinnati, Ohio, USA, August 27-30, 2006

Figure 7. Pipe 2 convergence of the different algorithms in terms of nodal discharge q. [H] Solid line; [H#] Dashed line; [G] = [LT] = [L] = [ILT] Dotted line

Figure 8. Pipe 6 convergence of the different algorithms in terms of nodal discharge q. [H] Solid line; [H#] Dashed line; [G] = [LT] = [L] = [ILT] Dotted line

14 Copyright ASCE 2006 Water Distribution Systems Analysis Symposium 2006


Downloaded 06 Jun 2012 to 143.106.52.210. Redistribution subject to ASCE license or copyright. Visit http://www.ascelibrary.org

8th Annual Water Distribution Systems Analysis Symposium, Cincinnati, Ohio, USA, August 27-30, 2006

80

[G] = [LT] = [L] =[ILT]


70 60

[H#]
50 40 30

[H]
20 10 0 0 10 20 30 40 50 60 70 80 90 100 110 120

Figure 9. Frequency histograms of the number of iterations necessary to reach convergence from randomly generated initial guess solutions. [H] Grey line; [H#] Thin black line; [G] = [LT] = [L] = [ILT] Thick black line

7. CONCLUSIONS
It was shown that several well known algorithms available in the literature as well as in the market, can be derived from the original equations, descending from the minimisation of the Collins et al. (1978) content, by linear or non-linear transformation. The convergence properties of the different algorithms have been discussed on the basis of both theoretical analysis and numerical experiments. The numerical tests confirm the absolute identity of the Global Gradient, the Linear Theory, the Simultaneous Loops and the Improved Linear Theory in terms of non-linear iterations and their superiority with respect to the Nodal Head Gradient approach both in its original formulation and in the over-relaxed version. The final choice for an algorithm should then be made between the Global Gradient, the Simultaneous Loops or the Improved Linear theory, since the original Linear Theory method, which produces a system of linear equations with a larger non-symmetrical matrix is not efficient in computational terms. Nonetheless, the practical success of the Global Gradient algorithm as programmed in EPANET 2 (Rossman, 2002) leaves no doubts that the easiness of the approach that does not require neither a topological analysis aimed at determining the appropriate independent loops nor the need for an initial balanced solution, make it the most appropriate fast convergent and robust tool for pipe network analysis.

References
Cross H. (1936) "Analysis of flow in networks of conduits or conductors", Bulletin no.286, University of Illinois Engineering Experimental Station, Urbana Illinois, USA.

15 Copyright ASCE 2006 Water Distribution Systems Analysis Symposium 2006


Downloaded 06 Jun 2012 to 143.106.52.210. Redistribution subject to ASCE license or copyright. Visit http://www.ascelibrary.org

8th Annual Water Distribution Systems Analysis Symposium, Cincinnati, Ohio, USA, August 27-30, 2006

Carpentier P., G. Cohen and Y. Hamam (1987) "Water Network Equilibrium Variational Formulation and Comparison of Numerical Algorithms", from Computer Applications in Water Supply, Volume 1 (System analysis and simulation), John Wiley & Sons. Collins M., L. Cooper, R. Helgason, J. Kenningston and L. LeBlanc (1978) "Solving the pipe network analysis problem using optimization techniques", Management Science, Vol. 24. Contro R. and S. Franzetti (1983) " A new objective function for analysing hydraulic pipe networks in the presence of different states of flow", Meccanica. Donachie R.P. (1974) "Digital Program for Water Network Analysis", Journal of the Hydraulics Division, ASCE, Vol.100: 393-403. Epp R. and A. G. Fowler (1970) "Efficient code for steady-state flows in networks". Journal of the Hydraulics Division, ASCE , Vol. 96, No. HY1. Kesavan H.K. and M. Chandrashekar (1972) " Graph-theoretic models for pipe network analysis". Journal of the Hydraulics Division, ASCE , Vol. 98. Lamm C.F and M.L. Wolla (1972) "Computer Analysis of Water Distribution Systems: Part I Formulation of Equations, Journal of the Hydraulic Division, ASCE, Vol. 98: 335-344; Part II Numerical Solution, Journal of the Hydraulic Division, ASCE, Vol. 98: 447-460. Lemieux P.F. (1972) "Efficient Algorithm for Distribution Networks", Journal of the Hydraulics Division, ASCE, Vol.98, pp.1911-1920. Martin D.W. and G. Peters (1963) "The application of Newton's method to network analysis by digital computers" IWES Journal. Mignosa P. (1987) "Sui problemi di verifica delle reti di distribuzione idrica complesse". Idrotecnica, n.2:257-273 (in Italian). Rossman L. A., (2002) EPANET 2 Users Manual. Water Supply and Water Resources Division, National Risk Management Research Laboratory, Cincinnati, OH45268. Salgado R., E. Todini and P.E. O' Connell (1987) "Comparison of the gradient method with some traditional methods for the analysis of Water Supply and Distribution", from Computer Applications in Water Supply, Volume 1 (System analysis and simulation), John Wiley & Sons. Salgado R., E. Todini and P.E. O' Connell (1988) "Extending the gradient method to include pressure regulating valves in pipe networks", International Symposium on Computer Modelling of Water Distribution Systems, Lexington, Kentucky USA. Salgado R. (1988) "Computer modelling of water distribution networks using the Gradient Method", Ph.D. Thesis, University of Newcastle Upon Tyne, UK. Shamir U and C. D. D. Howard (1968) "Water distribution network analysis". Journal of the Hydraulics Division, ASCE , Vol. 94, No. HY1. Stoer, J., and Burlish, R., (1980) Introduction to Numerical Analysis, pp. 356. Springer-Verlag, New York. Todini, E. (1979) Un metodo del gradiente per la verifica delle reti idrauliche, Bollettino degli Ingegneri della Toscana, n. 11:11-14 (in Italian). Todini E. and S. Pilati (1987) "A gradient method for the solution of looped pipe networks", from Computer Applications in Water Supply, Volume 1 (System analysis and simulation), John Wiley & Sons. Wood D.J. and C. O. A. Charles (1972) "Hydraulic network analysis using linear theory". Journal of the Hydraulics Division, ASCE, Vol. 98, No. HY7.

16 Copyright ASCE 2006 Water Distribution Systems Analysis Symposium 2006


Downloaded 06 Jun 2012 to 143.106.52.210. Redistribution subject to ASCE license or copyright. Visit http://www.ascelibrary.org