Meshless Computation of Water Hammer

Similar documents
International Journal of Civil Engineering and Geo-Environment. Investigation of Parameters Affecting Discrete Vapour Cavity Model

FURTHER INVESTIGATION OF PARAMETERS AFFECTING WATER HAMMER WAVE ATTENUATION, SHAPE AND TIMING PART 2: CASE STUDIES

Water hammer simulation by explicit central finite difference methods in staggered grids

IMPORTANCE OF NUMERICAL EFFICIENCY FOR REAL TIME CONTROL OF TRANSIENT GRAVITY FLOWS IN SEWERS

Parameters Affecting Water Hammer Wave Attenuation, Shape and Timing

ACCEPTED VERSION.

FLUID-STRUCTURE INTERACTION AND TRANSIENT CAVITATION TESTS IN A T-PIECE PIPE. P.O. Box 513, 5600 MB Eindhoven

HYDRAULIC TRANSIENTS IN PUMPING SYSTEMS WITH HORIZONTAL PIPES

Comparison of MOC and Lax FDE for simulating transients in Pipe Flows

Fluid structure interaction and transient cavitation tests in a T-piece pipe

AN EFFICIENT NUMERICAL SCHEME FOR MODELING TWO-PHASE BUBBLY HOMOGENEOUS AIR-WATER MIXTURES

PVP ACOUSTIC RESONANCE EXPERIMENTS IN A RESERVOIR - PIPELINE - ORIFICE SYSTEM

Hydraulic Design Of Polyethylene Pipes

Reservoir Oscillations with Through Flow

Solution of Unsteady Flow Equations in High Pressure Pipe

Lesson 6 Review of fundamentals: Fluid flow

An overview of the Hydraulics of Water Distribution Networks

GODUNOV-TYPE SOLUTIONS FOR TWO-PHASE WATER HAMMER FLOWS

Uncertainty Analysis of Transient Flow Modeling and Transient-Based Leak Detection in Elastic Water Pipeline Systems

ACCEPTED VERSION.

COMPUTATION OF LAMINAR AND TURBULENT WATER HAMMER FLOWS

Hydraulics Prof. Dr. Arup Kumar Sarma Department of Civil Engineering Indian Institute of Technology, Guwahati

Binary-coded and real-coded genetic algorithm in pipeline flow optimization

Implementing unsteady friction in Pressure Time measurements

IMPROVED METHOD FOR SIMULATING FRICTIONAL LOSSES IN LAMINAR TRANSIENT LIQUID PIPE FLOW KAMIL URBANOWICZ, ZBIGNIEW ZARZYCKI

Surge Analysis Using Transient Pressure Theory

Ilaboya, I. R. 1, *, Oti, E. O. 1, Atikpo E. 3, Enamuotor, B. O. 2, Umukoro, L. O Introduction

Chapter 8: Flow in Pipes

Simulating water hammer with corrective smoothed particle method Hou, Q.; Kruisbrink, A.C.H.; Tijsseling, A.S.; Keramat, A.

Analysis of flow characteristics of a cam rotor pump

Unsteady Flow with Cavitation in Viscoelastic Pipes

Uncertainties in hydraulic transient modelling in raising pipe systems: laboratory case studies

Chapter 8: Flow in Pipes

Diagnosis of water pipeline systems by frequency domain analysis

STRUCTURAL RESPONSE OF A PIPELINE APPARATUS TO PULSATING FLOW AT RESONANCE AND NON- RESONANCE CONDITIONS

Viscous Flow in Ducts

dx.doi.org/ /wwj ( ).(Haghighi & Keramat 2012)

EINDHOVEN UNIVERSITY OF TECHNOLOGY Department of Mathematics and Computer Science. CASA-Report July 2010

ENERGY RELATIONS IN TRANSIENT CLOSED-CONDUIT FLOW. By Bryan W. Karney 1

ACCEPTED VERSION. Bergant, Anton; Simpson, Angus Ross Pipeline column separation flow regimes Journal of Hydraulic Engineering.

V/ t = 0 p/ t = 0 ρ/ t = 0. V/ s = 0 p/ s = 0 ρ/ s = 0

Transient Phenomena in Liquid/Gas Flow in Pipelines

Effect of hydrogen injection into natural gas on the mechanical strength of natural gas pipelines during transportation

Avenue, , Lisbon, Portugal c Instituto Superior Técnico, Technical University of Lisbon (TULisbon), Rovisco Pais

Effect of drop in pipe wall stiffness on water-hammer speed and attenuation

NPTEL Quiz Hydraulics

Two-Fluid Model 41. Simple isothermal two-fluid two-phase models for stratified flow:

Numerical Simulation of Pressure Surge with the Method of Characteristics

RANS COMPUTATIONS OF A CAVITATING VORTEX ROPE AT FULL LOAD

Dynamic Behavior of a 2 Variable Speed Pump- Turbine Power Plant

Pump-turbine characteristics for analysis of unsteady flows

Water Hammer Simulation For Practical Approach

Theory Analysis and CFD Simulation of the Pressure Wave Generator

The effect of geometric parameters on the head loss factor in headers

Head loss coefficient through sharp-edged orifices

Laminar flow heat transfer studies in a twisted square duct for constant wall heat flux boundary condition

IMPLICIT NUMERICAL SCHEME FOR REGULATING UNSTEADY FLOW IN OPEN CHANNEL Mohamed. T. Shamaa 1, and Hmida M. Karkuri 2

International Research Journal of Engineering and Technology (IRJET) e-issn: Volume: 05 Issue: 03 Mar p-issn:

Modelling Vaporous Cavitation on Fluid Transients

Simulation of low pressure water hammer

Reynolds, an engineering professor in early 1880 demonstrated two different types of flow through an experiment:

ME 305 Fluid Mechanics I. Part 8 Viscous Flow in Pipes and Ducts. Flow in Pipes and Ducts. Flow in Pipes and Ducts (cont d)

TECHNISCHE UNIVERSITEIT EINDHOVEN Department of Biomedical Engineering, section Cardiovascular Biomechanics

FE Fluids Review March 23, 2012 Steve Burian (Civil & Environmental Engineering)

Influence of Pipe-Diameter on Water Hammer Phenomenon

The Fluid Flow in the T-Junction. The Comparison of the Numerical Modeling and Piv Measurement

LOSSES DUE TO PIPE FITTINGS

Implementation and Validation of a Free Open Source 1D Water Hammer Code

ME 305 Fluid Mechanics I. Chapter 8 Viscous Flow in Pipes and Ducts

THE PRESSURE-TIME MEASUREMENTS PROJECT AT LTU AND NTNU

Evaluation of pump characteristic from measurement of fast deceleration

Experimental and Numerical Investigations of the Effect of Net Positive Suction Head on Water Hammer In Pipeline Systems

Linear Hyperbolic Systems

CST Investigation on High Speed Liquid Jet using Computational Fluid Dynamics Technique

Pressure pulsations in reciprocating pump piping systems Part 1: modelling

Basic Fluid Mechanics

Unsteady skin friction experimentation in a large diameter pipe

COMPUTATION OF MASS OSCILLATIONS IN A SURGE TANK BY FINITE ELEMENT TECHNIQUE

ENGINEERING FLUID MECHANICS. CHAPTER 1 Properties of Fluids

ASYMPTOTIC MULTIPLE-SCALES ANALYSIS OF HYDRAULIC TRANSIENTS IN ELASTIC AND VISCOELASTIC PRESSURIZED CONDUITS

ScienceDirect. A pipe network simulation model with dynamic transition between free surface and pressurized flow

Chapter 10 Flow in Conduits

NUMERIC MODELLING OF WATER HAMMER EFFECTS IN PENSTOCKS

TCCS Published by Elsevier Ltd. Selection and/or peer-review under responsibility of [name organizer]

ON THE INTEGRATION OF EQUATIONS OF MOTION: FEM AND MOLECULAR DYNAMICS PROBLEMS

STEADY FLOW THROUGH PIPES DARCY WEISBACH EQUATION FOR FLOW IN PIPES. HAZEN WILLIAM S FORMULA, LOSSES IN PIPELINES, HYDRAULIC GRADE LINES AND ENERGY

Investigation of Flow Profile in Open Channels using CFD

Natural Frequencies Behavior of Pipeline System during LOCA in Nuclear Power Plants

Studies on flow through and around a porous permeable sphere: II. Heat Transfer

Analysis of the Cooling Design in Electrical Transformer

Chapter (3) Water Flow in Pipes

AA214B: NUMERICAL METHODS FOR COMPRESSIBLE FLOWS

Comparing Unsteady Modeling Approaches of Surges Caused by Sudden Air Pocket Compression

Viscoelastic Model of Waterhammer in Single Pipeline Problems and Questions

Investigation of transient cavitating flow in viscoelastic pipes

Modelling of a Two Phase Water Hammer

CFD analysis of the transient flow in a low-oil concentration hydrocyclone

Iterative Controller Tuning Using Bode s Integrals

Thermal Dispersion and Convection Heat Transfer during Laminar Transient Flow in Porous Media

Numerical simulation of the coil spring and investigation the impact of tension and compression to the spring natural frequencies

Transcription:

Meshless Computation of Water Hammer Arris S. TIJSSELING (corresponding author) Department of Mathematics and Computer Science Eindhoven University of Technology Den Dolech P.O. Box 53, 5600 MB Eindhoven, The Netherlands Phone: +3 40 47 755; Fax: +3 40 44 489; Email: a.s.tijsseling@tue.nl Anton BERGANT Litostroj E.I. d.o.o. Litostrojska 50 000 Ljubljana, Slovenia Phone: +386 584 84; Fax: +386 584 74; Email: anton.bergant@litostroj-ei.si

Abstract Water hammer concerns the generation, propagation, reflection and damping of pressure waves in liquidfilled pipe systems. The numerical simulation of water-hammer events is usually based on one-dimensional mathematical models. Two equations representing the conservation of mass and momentum govern the unsteady flow in the pipes. Boundary and/or intermediate conditions model the behaviour of hydraulic machinery and the additional complication of column separation. The method of characteristics is the preferred method of solution and the conventional approach is to define a fixed grid in the distance-time plane. On this grid, the unknown pressures and velocities (or heads and discharges) are numerically computed in a time-marching procedure that starts from a given initial condition. Rectangular or diamond grids are used that in general do not exactly match the given pipe lengths or the chosen time step. Therefore numerical interpolations and/or adjustments of wave speeds or pipe lengths are necessary, and these necessities introduce error. This paper presents a different way of water-hammer computation. The procedure is based on the method of characteristics, but a numerical grid is not required. Any point in the distance-time plane can be selected to compute the local solution without explicitly using stored previous solutions. The computation is based on back-tracking waves by means of a very simple recursion, so that the programming effort is small. Exact solutions are thus obtained for frictionless water-hammer. Approximate solutions are obtained when the distributed friction in individual pipes is concentrated at the pipe boundaries. The new algorithm is fully described and the new method is evaluated and compared with conventional water-hammer calculations. The following boundary conditions are tested: reservoir, instantaneous and gradual valve closure, and pipe junction. The algorithm is easy to implement and its exact solutions can be used to asses the numerical error in more conventional methods for the test cases of frictionless waterhammer and lumped friction. Key words Unsteady pipe flow; Hydraulic transients; Pressure surges; Water hammer; Wave propagation; Wave reflection; Method of characteristics; Mesh-free method; Exact solution.

. Introduction.. Water-hammer equations Classical water-hammer theory [-7] adequately describes the low-frequency elastic vibration of liquid columns in fully-filled pipes. The pipes are straight, prismatic, thin-walled, linearly elastic and of circular cross-section. The two equations, governing velocity, V, and pressure, P, are V P V V + = f t ρ z 4R, () V P + = 0 * z K t, () with R = + * K K E e. (3) Notation: E = Young modulus, e = wall thickness, f = Darcy-Weisbach friction factor, K = bulk modulus, K * = effective bulk modulus, R = inner pipe radius, t = time, z = distance along pipe, and ρ = mass density. The pressure wave speed is * K c =. (4) ρ.. Conventional methods of solution The method of characteristics (MOC) is the preferred technique to solve the water-hammer equations [8-9], because the wave speed c is constant and, unlike finite-difference [0-], finite-volume [-3], finiteelement [4-5] and lattice-boltzmann [6] methods, steep wave fronts can be properly dealt with. The distance-time (z-t) plane is covered with either a rectangular (collocated) or a diamond (staggered) computational grid in accordance with the Courant condition x = c t. Horizontal-vertical [-7] or diagonal [7] time-marching from a known initial condition gives approximate and exact solutions in systems 3

with and without friction, respectively. In multi-pipe systems the Courant condition cannot be satisfied in all pipes if a common time step t is adopted, and wave-speed or pipe-length adjustments and/or interpolations have to be applied. These introduce numerical error. In single pipes, interpolations are necessary when numerical data is required in between grid points, for example at the exact location of measuring equipment. Wood et al. [8, 9] developed and commercialised an alternative MOC-based solution procedure. Closedform analytical solutions can be obtained for water hammer in a single pipe with lumped [0] or linearised [] friction..3. New algorithm The new approach presented in this paper has no adjustments (of wave speeds or pipe lengths), no numerical interpolations and no approximations (except for lumped friction). The method automatically tracks waves backward in time by means of a simple recursion. The exact solutions obtained for frictionless water-hammer in multi-pipe systems can be used: to check numerical results and schemes, to serve as reference solutions in benchmark problems, and to perform parameter variation studies without parameter changes generated by the numerical method itself (e.g. changed wave speeds or pipe lengths). The method is mesh-free in the sense that a conventional computational grid is not required. The theory is presented in general form so that it can be applied to analogous two-equations systems in, for example, open channel flow, structural vibration, and electronics. It can be extended to four-equation systems encountered in, for example, the theory of linear(ised) waves in two-phase flows, two-layer density currents, liquid-saturated porous media, and water hammer with fluid-structure interaction []. The method even works for higher-order systems like those developed for water hammer by Bürmann [3], noting that then the necessary eigenvalues and eigenvectors cannot be found in closed form.. Theory.. General hyperbolic equations 4

The general linear equations A φ ( z, t ) + B φ ( z, t ) + C φ ( z, t ) = 0 (5) t z describe wave propagation in one spatial dimension. The constant matrices A and B are invertible and A B is diagonalizable. The constant matrix C, which may be non-invertible, causes frequency dispersion (if C O). The N dependent and coupled variables φ i, constituting the state vector φ, are functions of the independent variables z (space: 0 z L) and t (time: t 0). Herein N = and C = O... Method of characteristics (MOC) The MOC introduces a new set of dependent variables through η ( z, t ) φ ( z, t ) or φ ( z, t ) = S η( z, t ) η = S φ φ η, (6) so that each η i is a linear combination of the original variables φ i. Substitution of (6) into (5), with C = O, gives A S η ( z, t ) + B S η ( z, t ) = 0. (7) t z Multiplication by S A yields t η ( z, t ) + Λ η ( z, t ) = 0, (8) z in which = Λ S A B S. (9) A set of decoupled equations is obtained when Λ is diagonal: λ 0 = Λ. (0) 0 λ Substitution of (0) into (9) and solving for S reveals that a non-trivial solution exists only when the diagonal elements of Λ are eigenvalues satisfying the characteristic equation ( λ ) det B A = 0, () 5

in which case S consists of the eigenvectors ( ξ ξ ) ξ i belonging to λ i : S = ξ ξ. () The decoupled equations (8), η ( z, t ) η ( z, t ) i i + λ i = 0, i =, t z, (3) transform to d η ( z, t ) i d t = 0, i =,, (4) when they are considered along characteristic lines in the z-t plane defined by d z d t = λ, i =, i. (5) The solution of the ordinary differential equations (4) and (5) is η ( z, t ) = η ( z λ t, t t ), i =,, (6) i when a numerical time step i i t is used, or, more general and with reference to Fig., η i ( P ) = η i ( Ai ), i =,, or η ( A ) η ( P ) =. (7) η ( A ) The value of the unknown variable η i does not change along the line A i P. The original unknowns in φ are obtained from η through (6). This gives = S Ri S φ i i= φ ( P ) φ ( A ), (8) where the i-th diagonal element of the matrix R i is and all other elements are 0..3. Boundary conditions At the boundaries at z = 0 and z = L, the relations (6) or (7) provide just one equation (see Fig. ). To find the two unknowns η i (P), i =,, at z = z b (z b = 0 or z b = L), one additional equation per boundary is required. These are given by the linear boundary conditions d ( t) φ( z, t ) = q ( t) or T z b b z b d ( t) S η( z, t ) = q ( t), (9) T z b b z b 6

T where d is a row vector with coefficients and the scalar z b convenience, the two row vectors q z is the (boundary) excitation. For b T T d 0 and d L are stacked in the by matrix D, and the vector q consists of the two scalars q = q 0 and q = q L. Section.6 gives an example of matrix D. Fig. Interior point P and "feeding" characteristic lines in the distance-time plane. Fig. Boundary point P and "feeding" characteristic line in the distance-time plane. 7

.4. Junction conditions At junctions at z = z j the unknowns η i (P) may be discontinuous. The relations (6) or (7) provide two ± equations for ηi (P ), i =, (see Fig. 3). Two additional equations are required to find the unknowns at both sides of the junction, z = z j and z = z j +. These are given by the linear junction conditions J( t) z, t ) J( t) z, t ) r ( t) φ ( + j = φ ( j + or η j η j J( t) S η ( z, t ) = J( t) S η ( z, t ) + r ( t), (0) where J and J are by coefficient matrices and the vector r is the (junction) excitation. Section.6 gives an example of J and J. Thus the state vector φ can be discontinuous at z = z j. In general, the Riemann invariants η = S φ and η = S φ in the domains left and right of the junction are different. Only if ( t) ( t) η φ J S = J S the junction will not cause wave reflection. Fig. 3 Junction point P and "feeding" characteristic lines in the distance-time plane. 8

.5. Initial conditions The initial condition at t = 0 can be the steady-state solution φ ( z,0) = φ 0, where the constant state φ 0 is consistent with the boundary and junction conditions, or it can be any non-equilibrium state φ ( z, 0) = φ ( z) exciting the system (e.g. sudden release of pressure). 0.6. Water-hammer two-equation model In terms of the general equation (5), frictionless water-hammer [Eqs. (-) with f = 0] is represented by the state vector V φ = () P and the matrices of coefficients 0 A = * 0, () K 0 ρ B = 0. (3) The characteristic (dispersion) equation (), corresponding to the matrices () and (3), yields * K λ, = = ρ c, (4) where λ is positive and λ is negative. The transformation matrix used [Eq. ()] is S = ( TA ) with T defined by λ ( ρc) T =, so that S =. (5) λ ( ρ ) c It is noted that transformation matrices are not unique. For example, S = ( TB ) is an equally valid transformation matrix. The boundary conditions are defined through coefficient matrix D and excitation vector q [see Eq. (9)]. For example, a reservoir at z = 0 and a valve at z = L, as in the test problems in Section 4, are represented by 9

T ( ) d 0 = 0 and q 0 = P res, (6) T L ( 0) d = and q = 0, (7) L where P res is the reservoir pressure. Now Eqs. (6) and (7) are combined to give 0 D = and 0 Pres q =. (8) 0 The junction conditions are defined through coefficient matrices J and J, and excitation vector r [see Eq. (0)]. For example, continuity of flow rate and pressure at the junction of two pipes requires that A 0 J =, 0 A 0 J = 0 and 0 r =, (9) 0 where A and A are the cross-sectional pipe areas left and right of the junction..7. Nonlinear non-instantaneous valve closure In steady turbulent pipe flow the pressure loss, P0, across a fully open valve is given by the orifice equation P = ξ ρv V, (30) 0 0 0 0 where ξ 0 is an empirical loss coefficient [4, pp. 44-45]. The same relation is assumed to hold for a closing valve, P = ξ ρv V, (3) where ξ depends on valve position and hence of time. Division of (3) by (30) and introduction of the dimensionless valve closure coefficient τ = ξ 0 / ξ gives the nonlinear boundary condition 0 =τ ( ) 0 0 P V V t V V P, (3) where the pressure downstream of the valve has been taken zero, so that P0 = P 0 and P = P. The specific function τ ( t) used herein is 3.53 c ( t / T ) for 0 t 0.4 Tc τ ( t) = 0.394 ( t / T ) for 0.4 T t T 0 for t Tc.70 c c c, (33) 0

in which T c is the valve closure time and ξ 0 = 0. (see Fig. 4). This function, which is based on measured ball-valve discharge coefficients, was provided by Professor DC Wiggert (Michigan State University, USA) to Delft Hydraulics (The Netherlands) in 987. More information on ball-valve discharge characteristics can be found in [4-5]. The quadratic equation (3) is solved simultaneously with one linear equation (one compatibility equation). This is done exactly in Appendix A. In using the quadratic formula for (3), care should be taken of possible cancellation [6]. The resistance of the valve in steady state leads to a small initial pressure, so that V0 φ 0 =, (34) P 0 with P 0 equal to P res to ensure initial equilibrium. tau (-) 0.5 0 0 0.0 0.0 0.03 time (s) Fig. 4 Valve-closure function τ(t) for T c = 0.03 s.

.8. Modelling of friction Distributed friction (f > 0) is modelled by lumping it to one of the pipe ends, which is the common procedure in graphical [7] and wave-plan [8] methods. For example, the pressure loss at a reservoir-pipe entrance is then represented by the boundary condition [4, p. 03] L ρv V Pres P = ( + k + f ) R, (35) where k is the (minor) entrance loss and L is the pipe length. The term +k is neglected herein..9. Modelling of column separation Column separation [8] occurs when the absolute pressure drops to the vapour pressure modelled at closed pipe ends by adopting the boundary condition positive. The calculation of through P = v P v. This can be P as long as the cavity volume is ( t) = ( t t) ± A V ( t) t (36) can only be done by explicitly storing (and interpolating) previous cavity volumes. 3. Algorithm This section with its two appendices is the heart of the paper. It describes an algorithm for finding the exact value of the state vector φ in any point (z, t) in the distance-time plane. The algorithm is formulated in terms of the Riemann invariants η i, i =,, and it is based on a "coast-to-coast" approach, which is explained in words now. Figure is essential. The vector η in point P on the left boundary at z = 0 at time t consists of the two components η and η. The component η is assumed to be known because, according to equation (7), it is equal to η in the point A, on the right boundary at z = L. The component η follows from the boundary condition (9) and it depends on T d 0, S, q 0 and η. Naturally, the same story holds for any point P on the right boundary. For the calculation of η in point P on the left boundary, one needs information from the "earlier"

point A on the right boundary; and for the calculation of η in the point A on the right boundary, one needs information from the "earlier" point A on the left boundary. This whole process can nicely be captured in a simple recursion that stops when characteristic lines intersect the t = 0 line, at which η has a given initial value. The recursion and the treatment of internal points (Fig. ) are presented for a single pipe in Appendix B. The treatment of junctions (Fig. 3) and double pipes is similar and dealt with in Appendix C. 4. Results The new method is validated through the calculation of some basic results for frictionless water-hammer. The obtained exact solutions give details as fine as the chosen resolution in time or distance. Conventional MOC results obtained on very fine computational grids are given as a control. R E SE R V O IR PIPE V A L V E Fig. 5 Single-pipe test problem. 4.. Single pipe The single-pipe test problem [] sketched in Fig. 5 is a water-filled reservoir-pipe-valve system defined by: L = 0 m, R = 398.5 mm, e = 8 mm, E = 0 GPa, K =. GPa, ρ = 000 kg/m 3, f = 0, and Q 0 = 0.5 m 3 /s, so that the initial flow velocity V 0 =.00 m/s and the wave speed c = λ = λ = 05.7 m/s [Eq. (4)]. A pressure transducer (PT) is assumed to be located at distance z =.5 m from the reservoir. Rapid closure of 3

the valve generates the Joukowsky pressure P = ρ cv 0 =.08 MPa only if the closure time T c is smaller than the wave reflection time L/c. This is the case for the pressure histories (taken relative to a constant static pressure high enough to prevent the occurrence of cavitation) portrayed in Fig. 6. The classical case of instantaneous valve closure is shown in Fig. 6a. Figure 6b, which is for non-instantaneous valve closure with T c = 0.03 s, reveals that the pressure effectively starts to rise after time corresponding pressure distribution along the pipe at time t = 0.4 seconds. 0.7T c. Figure 7 displays the The results in Figs. 6 and 7 were obtained with the new method and with the conventional MOC method utilising a very fine computational grid (94 reaches and a time step of microseconds) and a marginally changed wave speed c = 05.3 m/s. Both solutions are displayed in the Figs. 6 and 7, but the differences are hardly visible, thus confirming the validity of the new method. The new method calculated solutions in 40 points in time ( millisecond step) to produce Fig. 6 and in 40 reaches to produce Fig. 7. These values were chosen to obtain high resolution, not high accuracy, because exact solutions are always obtained. It is noted that finding exact solutions for frictionless water-hammer in a single pipe is nothing special, except that the exact solutions are not necessarily in equidistantly spaced grid points. pressure (Pa).5.0 6.0 6 5.0 5 0 5.0 5.0 6.5.0 6 0 0.05 0. 0.5 0. time (s) (6a) 4

pressure (Pa).5.0 6.0 6 5.0 5 0 5.0 5.0 6.5.0 6 0 0.05 0. 0.5 0. time (s) (6b) Fig. 6 Single-pipe test problem. Pressure history calculated at z =.5 m: (a) T c = 0 s, (b) T c = 0.03 s. Solid line: new method. Dotted line: conventional method..5.0 6 pressure (Pa).0 6 5.0 5 0 0 4 6 8 0 4 6 8 0 distance (m) (7a) 5

0 pressure (Pa) 5.0 5.0 6.5.0 6 0 4 6 8 0 4 6 8 0 distance (m) (7b) Fig. 7 Single-pipe test problem. Pressure distribution along the pipe calculated at t = 0.4 s: (a) T c = 0 s, (b) T c = 0.03 s. Solid line: new method. Dotted line: conventional method..5 3.85 0 0 PT L z j 0.8 Fig. 8 Double-pipe test problem. Distances in metres. 4.. Double pipe In the double-pipe test problem sketched in Fig. 8, the first 3.85 m of the pipeline has a twice thicker wall (e = 6 mm, e = 8mm). The wave speed in the thick section is c = 84.0 m/s, which is larger than c = 05.7 m/s. The calculated pressure histories are shown in Fig. 9. The instantaneous valve closure in Fig. 9a clearly brings out all the reflections from the thicker pipe at the inlet. Joukowsky s value is exceeded and a 6

beat is starting to develop. The mathematical challenge is to capture all the tiny peaks in the entire period of simulation. The new method is able to do so, because it is exact. The traditional water-hammer simulation can only achieve this by using again a very fine computational grid of 900 reaches with a time step of microseconds, and marginally changed wave speeds c = 84.3 m/s and c = 05.5 m/s. The new method used a time step of 500 microseconds to produce Fig. 9 and 480 reaches to produce Fig. 0. Figure 9b is the more realistic case of gradual valve closure. All tiny peaks are smeared out now, but Joukowsky is still exceeded and a beat still develops. Figure 0 is the pressure distribution along the pipeline at time t = 0.4 seconds. Both new and conventional solutions are displayed in the Figs. 9 and 0, but the differences are hardly visible, thereby confirming again the validity of the new method. Finding exact solutions for frictionless water-hammer in a double pipe is to the author s knowledge new..5.0 6.0 6 pressure (Pa) 5.0 5 5.0 5 0.0 6.5.0 6 0 0.05 0. 0.5 0. time (s) (9a) 7

.5.0 6.0 6 pressure (Pa) 5.0 5 5.0 5 0.0 6.5.0 6 0 0.05 0. 0.5 0. time (s) (9b) Fig. 9 Double-pipe test problem. Pressure history calculated at z =.5 m: (a) T c = 0 s, (b) T c = 0.03 s. Solid line: new method. Dotted line: conventional method. 8

.0 6 8.0 5 6.0 5 pressure (Pa) 4.0 5.0 5 0.0 5 4.0 5 6.0 5 0 4 6 8 0 4 6 8 0 distance (m) (0a) 0.0 5 4.0 5 pressure (Pa) 6.0 5 8.0 5.0 6..0 6.4.0 6 0 4 6 8 0 4 6 8 0 distance (m) (0b) Fig. 0 Double-pipe test problem. Pressure distribution along the pipeline calculated at t = 0.4 s: (a) T c = 0 s, (b) T c = 0.03 s. Solid line: new method. Dotted line: conventional method. 9

5. Conclusion The equations for water hammer without friction have been solved exactly for time-dependent boundary and constant (steady state) initial conditions with a new method based on the MOC. The strength of the method is the simplicity of the algorithm (recursion) and the fast and accurate (exact) calculation of transient events. Its weakness is that the calculation time strongly increases for events of longer duration. The solutions are exact for the selected points of calculation in the distance-time plane, but they do not give information on what exists in between these points (no guaranteed constant values as in methods that track discontinuities). The efficiency of the algorithm can be much improved because many repeat calculations occur, but this will be at the expense of simplicity and clarity. The method is mesh-free and ideal for parallellisation and adaptivity. It is highly suitable to quickly calculate a limited number of exact transient pressure histories and distributions in simple frictionless pipe systems. The new method has been successfully validated against conventional water-hammer software in two simple test problems. In the second test problem, for the first time, an exact solution for frictionless waterhammer in a two-pipe system is presented. 0

Nomenclature Scalars A cross-sectional area, m c det E e f K K * k L P pressure wave speed, m/s determinant Young modulus of pipe wall material, Pa pipe wall thickness, m Darcy-Weisbach friction factor bulk modulus, Pa effective bulk modulus, Pa minor (entrance) loss pipe length, m pressure, Pa Q flow rate, m 3 /s q z boundary excitation b R T c t V inner radius of pipe, m valve closure time, s time, s velocity, m/s cavity volume, m 3 z λ ξ axial coordinate, m numerical step size; change in magnitude eigenvalue, wave speed, m/s valve loss coefficient ρ mass density, kg/m 3 τ valve closure function - see Eq. (33)

Matrices and Vectors A coefficients - see Eqs. (5) and () B coefficients - see Eqs. (5) and (3) C coefficients - see Eq. (5) and C = O herein D boundary condition coefficients - see Eqs. (9) and (8) d row of matrix D T z b J, J junction condition coefficients - see Eqs. (0) and (9) O zero matrix q boundary excitation vector - see Eqs. (9) R matrix - see Eq. (8) r junction excitation vector - see Eqs. (9) S transformation matrix - see Eqs. () and (5) T transformation matrix - see Eq. (5) Λ diagonal matrix of eigenvalues - see Eq. (0) η Riemann invariants - see Eq. (6) ξ eigenvector - see Eq. () φ dependent variables - see Eqs. (5) and () Subscripts b j L res v boundary junction boundary position z = L reservoir vapour 0 boundary position z = 0; initial state t = 0 Extensions pipe pipe

Appendix A Solution of nonlinear equation (3) The nonlinear boundary condition (3) is solved simultaneously with one linear equation for the two variables V and P. The system of equations can be written as a V + a P = a 3, (37a) + = 3 b V b P b, (37b) where the coefficients a i and b i (i =,, 3) can be time dependent and a 0 and b 0. Elimination of P gives + 3 3 = 0 a b V a b V a b a b, (38) so that V ± 3 3 { 4 ( )} = a b a b a b a b a b a b. (39) This formula is susceptible to numerical error, because of cancellation [6]. In the present paper the coefficients in (37) for the single pipe are = a S, = a S, a 3 =η(a ), b = ±, = τ ( ) 0 0 / 0 b t V V P, b 3 = 0, and for the double pipe these are = a S, = a S, a 3 =η ("A "), b = ±, = τ ( ) 0 0 / 0 b t V V P, b 3 = 0. The matrices S and S are given by (5) and the function τ(t) by (33). According to relation (3), which describes positive flow (in z-direction) for positive pressure P, the following condition must hold: b V 0. (40) In the examples presented herein, b = + and the + sign (+ root) in (39) gave valid solutions satisfying condition (40). 3

Appendix B Recursion for a single pipe Input The coefficient matrices A, B, D(t), the excitation vector q(t), the initial condition φ ( z), the length L, and the positive wave speed λ = λ describe the complete single-pipe system in general terms. It is stressed once again that C = O in Eq. (5), so that the algorithm does not apply to systems with distributed friction, viscous damping, etc. 0 Output The output is the state vector φ = Sη as a function of distance and time. Boundary points See Figure. The subroutine BOUNDARY calculates η in the boundary points (finally) from constant initial values. The pseudo-code reads: BOUNDARY (input: z, t ; output: η) if (t 0) then else η := η 0 if (z = 0) then CALL BOUNDARY (L, t + L / λ ; η) η := η η := α(t) η + β(t) q (t) η := η 4

if (z = L) then CALL BOUNDARY (0, t L / λ ; η) η := η η := η η := α(t) η + β(t) q (t) if (z 0 AND z L) then "z is not at a boundary" end Note that λ is a negative number herein. The coefficients α and β are given in Table. They define the unknowns η and η at the left and right boundaries, respectively, as the exact solution of the linear equation (9). For the case of nonlinear non-instantaneous valve closure, as described in Section.7, in subroutine BOUNDARY: q ( t ) = V from Eq. (39), for z = L. Interior points See Figure. The subroutine INTERIOR calculates η in the interior points from the boundary values. The pseudo-code reads: INTERIOR (input: z, t ; output: η) if (0 < z < L) then CALL BOUNDARY (0, t z / λ ; η) η := η CALL BOUNDARY (L, t (z L) / λ ; η) η := η η := η η := η 5

else "z is not an interior point" end Implementation The algorithms have been implemented in Mathcad [9]; the interested reader may find the Mathcad worksheet in Appendix D. z = 0 z = L α( t) β( t) DS( t), DS t := α( t) := DS t ( ), := β( t) := DS( t), ( ), DS( t), DS( t), Table Definition of the coefficients α and β in subroutine BOUNDARY. DS(t) is the matrix product of D(t) and S. 6

Appendix C Recursion for a double pipe Input The coefficient matrices A, B, A, B, D(t), J(t), J(t), the excitation vectors q(t) and r(t), the initial conditions φ 0 ( z) and φ 0 ( z), the lengths z j and L, and the positive wave speeds λ = λ and λ = λ, describe the complete double-pipe system in general terms. The extensions and in the notation refer to the domains left and right of the junction at z = z j. See Figure 3. Output The output is the state vector φ = Sη as a function of distance and time, with φ = S η if 0 z z and φ = j S η if z j+ z L. Boundary and junction points See Figure 3. The subroutine BOUNDARY calculates η and η in the boundary and junction points (finally) from constant initial values. The pseudo-code reads: BOUNDARY (input: z, t ; output: η, η) if (t 0) then η := η 0 else η := η 0 if (z = 0) then CALL BOUNDARY (z j, t + z j / λ ; η, η) η := η 7

η := α(t) η + β(t) q (t) η := η if (z = L) then CALL BOUNDARY (z j, t (L z j) / λ ; η, η) η := η η := η η := α(t) η + β(t) q (t) if (z = z j) then CALL BOUNDARY (0, t z j / λ ; η, η) η := η CALL BOUNDARY (L, t (z j L) / λ ; η, η) η := η η := η η := γ(t) η + γ(t) η + δ(t) r (t) + δ(t) r (t) η := γ(t) η + γ(t) η + δ(t) r (t) + δ(t) r (t) η := η if (z 0 AND z L AND z z j) then "z is not at a boundary or junction" end Note that λ and λ are negative numbers herein. The coefficients α and β are given in Table. They define the unknowns η and η at the left and right boundaries, respectively, as the exact solution of the system of two linear equations (9). For the case of nonlinear non-instantaneous valve closure, as described in Section.7, in subroutine BOUNDARY: q ( t ) = V from Eq. (39), for z = L. The coefficients γ and δ are given in Table 3. They define the unknowns η and η at the left and right sides of the junction, respectively, as the exact solution of the system of two linear equations (0). 8

Interior points The subroutine INTERIOR calculates in the interior points from the boundary and junction values. The pseudo-code reads: INTERIOR (input: z, t ; output: η, η) if (0 < z < z j) then CALL BOUNDARY (0, t z / λ ; η, η) η := η CALL BOUNDARY (z j, t (z z j) / λ ; η, η) η := η η := η η := η if (z j < z < L) then CALL BOUNDARY (z j, t (z z j) / λ ; η, η) η := η CALL BOUNDARY (L, t (z L) / λ ; η, η) η := η else end η := η η := η "z is not an interior point" Implementation 9

The algorithms have been implemented in Mathcad [9]; the interested reader may find the Mathcad worksheet in Appendix E. z = 0 z = L α( t) β( t) DS( t), DS t := α( t) := DS t ( ), := β( t) := DS( t), ( ), DS( t), DS( t), Table Definition of the coefficients α and β in subroutine BOUNDARY. DS(t) is the matrix product of D(t) and S, and DS(t) is the matrix product of D(t) and S. junction side, z = z j junction side, z = z j + γ( t) JS t := ( ), JS t ( ), det( t) JS t ( ), JS t ( ), γ( t) JS t := ( ), JS t ( ), det( t) JS t ( ), JS t ( ), γ( t) JS t := ( ), JS t ( ), det( t) JS t ( ), JS t ( ), γ( t) JS t := ( ), JS t ( ), det( t) JS t ( ), JS t ( ), δ( t) JS t := det( t) ( ), δ( t) JS t := det( t) ( ), δ( t) := JS( t), det( t) δ( t) := JS( t), det( t) det ( t) := JS( t), JS( t), JS( t), JS( t), Table 3 Definition of the coefficients γ and δ in subroutine BOUNDARY. JS(t) is the matrix product of J(t) and S, and JS(t) is the matrix product of J(t) and S. 30

References [] Aronovich, G. V., Kartvelishvili, N. A., and Lyubimtsev, Ya. K., 968, Gidravlicheskii Udar i Uravnitel nye Rezervuary, (Water Hammer and Surge Tanks,) Izdatel stvo Nauka, Moscow, Russia (in Russian). (English translation by D. Lederman, 970, Israel Program for Scientific Translations, Jerusalem, Israel.) [] Fox, J. A., 977, Hydraulic Analysis of Unsteady Flow in Pipe Networks, Macmillan Press Ltd, London, UK; Wiley, New York, USA. [3] Chaudhry, M. H., 987, Applied Hydraulic Transients (nd edition), Van Nostrand Reinhold, New York, USA. [4] Wylie, E. B., and Streeter, V. L., 993, Fluid Transients in Systems, Prentice Hall, Englewood Cliffs, New Jersey, USA. [5] Záruba, J., 993, Water Hammer in Pipe-Line Systems (nd edition), Czechoslovak Academy of Sciences, Prague, Czech Republic; Developments in Water Science, 43, Elsevier Science Publishers, Amsterdam, The Netherlands. [6] Popescu, M., Arsenie, D., and Vlase, P., 003, Applied Hydraulic Transients for Hydropower Plants and Pumping Stations, A.A. Balkema Publishers, Lisse, The Netherlands. [7] Thorley, A. R. D., 004, Fluid Transients in Pipeline Systems (nd edition), Professional Engineering Publishing, London, UK. [8] Ghidaoui, M. S., Zhao, M., McInnis, D. A., and Axworthy, D. H., 005, A Review of Water Hammer Theory and Practice, ASME Applied Mechanics Reviews, 58, 49-76. 3

[9] Bergant, A., Tijsseling, A. S., Vítkovský J. P., Covas D., Simpson A. R., and Lambert M. F., 007, Parameters Affecting Water-Hammer Wave Attenuation, Shape and Timing, Accepted for Publication in IAHR Journal of Hydraulic Research. [0] Chaudhry, M. H., and Hussaini, M. Y., 985, Second-Order Accurate Explicit Finite-Difference Schemes for Waterhammer Analysis, ASME Journal of Fluids Engineering, 07, pp. 53-59. [] Arfaie, M., and Anderson, A., 99, Implicit Finite-Differences for Unsteady Pipe Flow, Mathematical Engineering for Industry, 3, pp 33-5. [] Guinot, V., 000, Riemann Solvers for Water Hammer Simulations by Godunov Method, International Journal for Numerical Methods in Engineering, 49, pp. 85-870. [3] Hwang Yao-Hsin, and Chung Nien-Mien, 00, A Fast Godunov Method for the Water-Hammer Problem, International Journal for Numerical Methods in Fluids, 40, pp. 799-89. [4] Jović, V., 995, Finite Elements and the Method of Characteristics Applied to Water Hammer Modelling, Engineering Modelling, 8(3-4), pp. 5-58. [5] Shu, J.-J., 003, A Finite Element Model and Electronic Analogue of Pipeline Pressure Transients with Frequency-Dependent Friction, ASME Journal of Fluids Engineering, 5, pp. 94-99. [6] Cheng Yong-guang, Zhang Shi-hua, and Chen Jian-zhi, 998, Water Hammer Simulations by the Lattice Boltzmann Method, Transactions of the Chinese Hydraulic Engineering Society, Journal of Hydraulic Engineering, 998(6), pp. 5-3 (in Chinese). [7] Thanapandi, P., 99, An Efficient Marching Algorithm for Waterhammer Analysis by the Method of Characteristics, Acta Mechanica, 94, pp. 05-. 3

[8] Wood, D. J., Dorsch, R. G., and Lightner, C., 966, Wave-Plan Analysis of Unsteady Flow in Closed Conduits, ASCE Journal of the Hydraulics Division, 9, pp. 83-0. [9] Wood, D. J., Lingireddy, S., Boulos, P. F., Karney, B. W., and McPherson, D. L., 005, Numerical Methods for Modeling Transient Flow in Distribution Systems, Journal AWWA, 97(7), pp. 04-5. [0] Jones, S. E., and Wood, D. J., 988, An Exact Solution of the Waterhammer Problem in a Single Pipeline with Simulated Line Friction, ASME - PVP, 40, pp. -6. [] Sobey, R. J., 004, Analytical Solutions for Unsteady Pipe Flow, Journal of Hydroinformatics, 6, pp. 87-07. [] Tijsseling A. S., 003, Exact Solution of Linear Hyperbolic Four-Equation Systems in Axial Liquid- Pipe Vibration, Journal of Fluids and Structures, 8, pp. 79-96. [3] Bürmann, W., 975, Water Hammer in Coaxial Pipe Systems, ASCE Journal of the Hydraulics Division, 0, pp. 699-75. (Errata in 0, p. 554.) [4] Rij, A. A. van, 970, Standaard Afsluiterkarakteristieken (Standard Valve Characteristics), Delft Hydraulics Laboratory, Report V 95, Delft, The Netherlands (in Dutch). [5] Schedelberger, J., 975, Closing Characteristics of Spherical Valves, 3R international, 4, pp. 333-339 (in German). [6] Bergant, A., and Simpson, A. R., 99, Quadratic-Equation Inaccuracy for Water Hammer, ASCE Journal of Hydraulic Engineering, 7, pp. 57-574. [7] Bergeron, L., 96, Waterhammer in Hydraulics and Wave Surges in Electricity, John Wiley & Sons, New York, USA. 33

[8] Bergant, A., Simpson, A. R., and Tijsseling, A. S., 006, Water Hammer with Column Separation: A Historical Review, Journal of Fluids and Structures,, pp. 35-7. [9] Mathcad, 00, User's Guide, MathSoft Engineering & Education, Inc., Cambridge, USA. 34