Generalized Impedance-based Transient Analysis for Multi-branched Pipeline Systems

Transient analysis of multi-branched pipeline systems is generalized by the development of an impedance method. Both open and closed boundaries of branched pipeline elements were implemented in the analytical development of a reservoir multi-branched pipeline valve system, in which impedance and transient responses performance were compared with those of conventional approaches. To address realistic boundary conditions along the branched element, a partially opened boundary condition was implemented in the impedance expression of the branched pipeline system. The performance of the generalized multi-branch impedance method was evaluated on a large water supply system with 10 minor branches from the actual system. The impact of the designated branches was evaluated using the pressure root-mean-square error (RMSE) and the energy spectral density difference between the original and skeletonized systems. Combinations of multiple branches for certain flow conditions were identified based on the holistic response for both the frequency and time domains. The proposed method can be a useful alternative to effectively address the skeletonization issue for pipeline systems with multi-branched elements.


Introduction
Water distribution structures from main transmission pipelines have been frequently designed using multi-branched pipeline systems, due to operational efficiency and feasibility (Evangelista et al. 2015;Huang et al. 2017;Meniconi et al. 2021a). The general layout consists of a main pipeline with a large diameter and a long extension attached to several smaller supplementary branched pipeline elements. Proper transient modeling of branched pipeline systems has been extensively investigated because of their complicated wave propagations and reflections, including skeletonization issues in model applications, which are intended to address field pipeline complexity (Jung et al. 2007;Meniconi et al. 2021b). Moreover, both elastic and viscoelastic pipeline systems have been used to determine accurate models and parameters in branched pipeline systems (Evangelista et al. 2015;Meniconi et al. 2018).
The detection of unknown side branches or dead ends using transient analysis for simple reservoir pipeline valve (PRV) systems has been previously attempted (Meniconi et al. 2018;Duan and Lee 2015), whereby a method to identify leakages and blockages in pipelines has been successfully developed (Capponi et al. 2017;Meniconi et al. 2021b;Keramat et al. 2022;Pan et al. 2022a). Furthermore, detection methods for various abnormalities have been studied, particularly in the time and frequency domains of either elastic or viscoelastic materials for branched pipeline systems (Kim 2016;Bettaieb et al. 2020;Duan 2018;Liu et al. 2021;Pan et al. 2022b).
The frequency modeling method provides a more precise approach to describe the dimensions and properties of field pipeline systems than the discretization-based models such as the method of characteristics (MOC), owing to the absence of constraints of the Courant number in its analytical expression. In addition, analytical development in various pipeline systems allows for the isolation of a specific element, collection of designated elements, and obtain specific abnormalities (Kim 2020). However, existing frequency model studies have primarily focused on single-branched pipelines with dead-end boundary conditions (Duan and Lee 2015;Capponi et al. 2017). Considering the impact of multiple-branched elements of the frequency resonance in transient generation patterns, a general transient analysis method for multi-branched pipeline systems remains unexplored (Meniconi et al. 2021a). Furthermore, boundary conditions at both the ends and sides of the branched element tend to vary; hence, accounting for the model structure is critical in describing the behavior of pressure variations for various flow and leak conditions in field pipeline systems.
To predict the pressure variation in multi-branched pipeline systems, a series of formulations that extended the impedance method were proposed here. Moreover, this approach was used to perform the skeletonization of a multi-branched pipeline system, in which two distinct criteria were introduced to account for the impacts of the skeletonized pipeline elements. These criteria include the root-mean-square error (RMSE) between the pressure head of the original and skeletonization systems which helps minimize the time-domain transient response; and the minimum difference in the energy spectral density in the frequency domain to delineate the best skeletonization combination for a given boundary condition, as a comparison between the resonance responses in the frequency domain can be performed.
The applicability of the developed method was then tested using two hypothetical pipeline systems. The first contained dual-branched elements designed to highlight the accuracy of the analytical development compared with conventional approaches. The second, representing an actual system found in Umbria, Italy, had a long transmission pipeline with 10 minor branches designed to evaluate the potential of the proposed skeletonization scheme by Meniconi et al. (2021a).
The first objective of this study was to develop a generalized mathematical expression that more accurately represented multi-branched pipeline systems than existing approaches (Meniconi et al. 2021a;Pan et al. 2022a, b). The second was to demonstrate the capability of system representation fidelity as well as the computational efficiency of the proposed method, which rendered skeletonization feasible for field pipeline systems. These objectives provide a clearer transient response configuration as well as better model applicability than existing real life system approaches.

Transient Model for a Fluid Transmission System
The one-dimensional partial differential equations for mass and momentum conservation under transient conditions in a pipeline system can be expressed as (Chaudhry 2014): where t is time, x is the distance along the pipe, Q is the mean flow rate, g is the gravitational acceleration, A is the pipe cross-sectional area, H is the pressure head, a is the wave speed, and J is the pressure head loss per unit length due to friction.
The relationship between the upstream and downstream hydraulic impedances and discharge ratios (H U /Q D , H D /Q D , Q D /Q D , and Q U /Q D ) can be expressed in the frequency domain as follows: where and Z C are the propagation constant and characteristic impedance, which can be evaluated as √ gA a 2 s( s gA + R) and a 2 gAs , respectively, s is the complex frequency, and resistance R is 32 gAD 2 for laminar flow and f Q gDA 2 for turbulent flow. Depending on the consideration of friction (e.g., unsteady friction), the J term in Eq. (1) can be further determined using the instantaneous acceleration for turbulent flow (Brunone et al. 1991) or simplified two-dimensional Navier-Stokes equations for laminar flow (Brown 1962). This can then be implemented into Eqs. (3) and (4) for the propagation constant and characteristic impedance (Kim 2020).

Analytical Impedance Function for a Multi-branched Pipeline with Closed-boundary Conditions
A reservoir pipeline valve with dual-branched elements was introduced to develop general mathematical formulations for closed-boundary conditions at all branch ends (Fig. 1).
The hydraulic impedance at the starting point of the first branch in the main pipeline can be identified by implementing a constant upstream head condition (i.e., no oscillation), H U = 0 , in Eqs. (3) and (4). Their combined expression is as follows: Considering the no-flow condition at the end of the branched element, the upstream hydraulic impedance of the first branched element is expressed as follows: By combining Eqs. (5) and (6) using the flow rate continuity and common pressure head conditions, the downstream hydraulic impedance of the first branched element in the main pipeline can be expressed as follows: Considering the relationship between the upstream and downstream hydraulic impedance in the main pipeline, the hydraulic impedance at the starting point of the second branch can be expressed as: Further downstream development provides hydraulic impedances at downstream points such as H 5 Q 5 and H 6 Q 6 . Hence, the hydraulic impedance at the end of the main pipeline section, can be expressed as follows, as also shown in Fig. 1 point 7: Therefore, generalizing the number of branched pipelines as n for a multi-branched pipeline system, the general hydraulic impedance can be expressed as follows: where n is the number of upstream branches and m1 and m2 are the number of valid combinations (either even or odd) of Z ci tanh j j . Hence, this satisfies the connectivity from the last main pipeline element to other upstream elements and its sequential element Fig. 1 Schematic diagram of the dual-branched pipeline system with a closed-boundary conditions combinations from the formulations of the upstream relationship, in which the odd cmb and even cmb represent the number of Z ci tanh j j terms in each product notation ( ∏ ) . The Appendix provides analytical impedance functions with unsteady friction models for multibranched pipelines with closed-boundary conditions.

Analytical Impedance Function for a Multi-branched Pipeline with Open-boundary Conditions
A general mathematical formulation can be developed for a multi-branched pipeline system with an open-boundary conditions (Fig. 2) for a dual-branched pipeline. By implementing a constant head condition downstream of the first branched element, the upstream hydraulic impedance of the first branched element can be expressed as: Combining Eqs. (5) and (11) with the flow rate continuity and common pressure head conditions, the downstream hydraulic impedance of the first branched element can be expressed as follows: The hydraulic impedance at the starting point of the second branch of the main pipeline can be expressed as follows: Downstream hydraulic impedance can be developed by implementing the hydraulic impedance of the second branch with an open-boundary condition. The hydraulic impedance at the end of the main pipeline system can be expressed as: Therefore, the general mathematical impedance formulation for multi-branched elements (n ≥ 2, where n is the number of branches) with an open boundary can be expressed as follows: and for odd and even numbers of upstream branched elements, respectively.
The Appendix presents the mathematical development of the analytical impedance expressions using unsteady friction models for laminar and turbulent conditions.

Analytical Impedance Function for a Multi-branched Pipeline with Partially Opened Boundary Conditions
The pressure head and flow rate for partially opened (e.g., leakage) or closed boundaries for branched elements can be developed from the implementation of the orifice equation into frequency-domain expressions (Mpesha et al. 2001). With the assumption that the flow rate through a partially opened orifice or leakage is Q olk,i , where i represents the order of the upstream branched element, the hydraulic impedance at the upstream part of the branched element can be expressed as follows: where y s is the distance from the end of the orifice to the partially opened orifice, or leakage. If the upstream hydraulic impedance of the branched element in the main pipeline is H j ∕Q j , then the downstream hydraulic impedance can be expressed as: The hydraulic impedance to the downstream distance x j+2 , from the upper junction of the branch, can be expressed as: where Z cxj+2 is the characteristic impedance to the main pipe section ( x j+2 ).
Hydraulic impedances in further downstream directions can be obtained through sequential development of Eqs. (17) and (19) to downstream components.

Alternative Skeletonization Methods for Branched Pipeline Systems
The role of a specific branch or a collection of branches in a transient event is critical for a reliable skeletonization of branched pipeline systems (Jung et al. 2007;Evangelista et al. 2015;Meniconi et al. 2021a). Studies on model skeletonization for surge analysis have largely been conducted based on the MOC, owing to the proper modeling adaptation in discretization of the method that considers the complexity and representation of field pipelines. Determining the similarities in severe hydraulic transient events between the original and skeletonized systems have been one of the primary objectives in conventional approaches. Hydraulic transients in actual systems are not necessarily associated with instant or abrupt pressure surges, which rarely occur especially in field pipeline systems with large diameters. Moreover, frequency resonance between pipeline structures, particularly the main pipeline and branched element or a branched element and collection of specific branched elements, remains largely unexplored as it is not necessarily bounded under a specific transient event. Hence, accounting for these issues, determining the impact of specific branched pipeline elements for a more generalized transient response perspective warrants attention. In addition, accounting for transient response characteristics in terms of the frequency response ranges for available pipeline structural combinations is required, as it can result from all possible skeletonization scenarios.
Here, two objective functions were introduced to delineate the best combination for any given skeletonization condition, or the n numbers of branched element elimination. The first objective function, OF 1st , minimizes the difference in the pressure response in terms of the RMSE between the original and skeletonized systems, given by the equation as follows: where n is the number of transient time steps, h o i is the pressure response of the original system, and h s i is the pressure response of the skeletonized system. The second objective function, OF 2nd , minimizes the difference in the energy spectral density of the frequency-domain hydraulic impedance at a designated point j such as those at the end of the main pipeline system, between the original and skeletonized systems. The equation is given as follows: where Ω min and Ω max are the minimum and maximum frequency bounds, respectively, respectively. This addresses the issue of minimizing the difference in the frequency response functions in terms of a generalized sense of signal processing between the original and skeletonized systems. Figure 3 presents a flowchart for the optimum skeletonization scheme, in which different numbers of branch eliminations are considered to determine the number of DO loops. Hence, Eqs. (20) and (21) can be used to delineate the best combinations of branch skeletonization, in which the purpose of the system or the flow control condition in a particular system was considered.

Pipeline System Properties
To test the developed formulations for multi-branched systems, the dual-branched pipeline systems with no-flow (closed boundary) and constant head boundary conditions (open boundary) were used ( Figs. 1 and 2). Here, the diameter and wave speed were assumed as 0.02 m and 1431.43 m/s, respectively, based on estimations of the experimental pipeline system. The diameters and pipeline parameters of the branched elements were also assumed to be identical to those of the main pipeline to accurately evaluate the performance of the developed analytical impedance function and obtain a comparison with the existing conventional impedance function. The length of the main pipeline was 90 m, and the distances between the upstream to the first branched element, first and second branched element, and second branched element to the end of the main pipeline, were all 30 m. The lengths of the first and second branched elements were 10 and 20 m, respectively. The maximum frequency range was truncated at 943.5 rad/s and the number of samples for the fast Fourier transform (FFT) was 32,768 to obtain a comparison of the frequency responses between the developed and conventional formulations. Based on a steady water flow of 3.11 ⋅10 −5 m 3 /s from the upstream to the downstream, the instant valve closure in the downstream valve introduced a transient event.
In the actual multi-branched system in Umbria, Italy, the length and diameter of the main pipeline were 0.5 m and 30,288 m, respectively, including 10 minor branches (Meniconi et al. 2021a). This pipeline system was used to perform a skeletonization analysis using the proposed method, where an identical initial flow condition (v = 0.2 m/s) was used with a transient introduction to compare the performance between the proposed and conventional methods (Meniconi et al. 2021a). Here, the fast and complete closure of the downstream end valve was evaluated. The inherent pressure signal for each branched element associated with the diverted flow rate of each branch, in both the impedance-based frequency response and identified pressure signal in the time domain, was also identified. Considering the substantial length of the main pipeline with 10 minor branches of different dimensions, the maximum frequency range was truncated as 20 rad/s, and the number of samples for the FFT was 65,536.

Comparison Between the Conventional Approach and Analytical Impedance Function
Based on Eq. (9), the analytical impedance function (AIF) at the end of the pipeline for a dual-branched system with closed boundaries (Fig. 1) was evaluated. The conventional impedance (CI) method was also used to compute the hydraulic impedance (Kim 2016). The comparison between the hydraulic impedances ( , evaluated by AIF and CI, is shown in Fig. 4, where the hydraulic impedance distributions between the two methods were similar; however, high-amplitude responses in AIF near 21.3 rad/s and 66.2 rad/s were also observed. Although the distribution of CI showed substantial discontinuities at different points between the two methods, the AIF showed a more continuous frequency response with normal peaky responses. This can be attributed to the truncation error associated with the merging formulation in the junction, including the transfer function using conventional hydraulic impedance expressions, in which the substantial difference in the order of pressure head and flow rate was approximately 10 -7 , recurring in the combing and transmission along the sequential pipeline extension. In turn, this amplifies the truncation error. Further, as there was a high number of multi-branched elements, the CI method error in multi-branched pipeline systems also tended to be high. The AIF in Eq. (9) provides a holistic evaluation, as it extends the formulation for the nth number of branched element systems, where issues in the conventional methods were balanced by Eq. (10). The transient analysis comparison between the CI and AIF for a water hammer event with the instant closure of the downstream valve showed no difference between the two methods. The frequency range differences between the two methods were less than 0.15%, and the time-domain responses between the two methods were identical, unless the external surge or its resonance exactly matched the different points.
The performances of AIF and CI can also be compared to those of a dual-branched pipeline system with an open boundary. Equation (14) was used for the AIF, and a series of impedance functions for open boundaries were adapted for CI. Figure 5 presents the frequency amplitudes of the hydraulic impedance using the AIF and CI at the pipeline end, as shown in Fig. 2. The number of different points between AIF and CI was six (see Fig. 5), whereas the number of different points shown in Fig. 4 was eight, for frequency ranges less than 300 rad/s. This can be attributed to the generation of less reflections by the openbranch end boundaries, which result in fewer peaky harmonics, compared to that of the closed-boundary system. The pressure head responses of a downstream valve action surge between the two methods were also identical in the dual-branched with open-boundary system, implying that an instant valve action at the downstream point (Fig. 2) does not introduce matching harmonics for the unmatching points shown in Fig. 5.
The dual-branched pipeline with a partially-opened boundary system, including its succeeding downstream developments, was modeled using Eq. (17). A hydraulic transient for the fast valve closure was then modeled following the implementation of partially opened boundaries with a 2% leak rate based on the mean discharge at the two ends of the closed boundaries (Fig. 1). To validate the performance of the developed model, the MOC was employed. The lengths of the first and second branches were slightly reduced to 9.9 and 19.8 m, respectively, to fit the Courant number. The comparison of the pressure variations of surge events between the impedance-based method (IBM) and MOC are shown in Fig. 6, in which the congruence between the two methods can be observed, indicating that IBM can be a reliable approach for the transient analysis of multi-branched systems with partially opened boundaries.

Unsteady Friction Modeling
To consider a more realistic pressure damping under a laminar flow condition, an unsteady friction model with a two-dimensional velocity profile in the frequency domain was adapted into the AIF (Brown 1962;Kim 2020). Transient simulations with steady and unsteady friction models for the closed-branch boundary condition are presented in Fig. 7a, wherein the pressure reduction in the unsteady friction model (AIF_UNST) was greater than that in the steady friction model (AIF). In both friction models under open-branched boundary conditions, a faster damping in the transient response for the former was found, compared to the latter (Fig. 7b).
Owing to the more frequent resonances in the open-boundary condition than in the closed-boundary condition, the phase shift in the transient response for the former appeared slightly more severe.

Application of a Practical Case
Based on the case study of the Umbria tree-type pipe system (Meniconi et al. 2021a) and the delineation of the best combinations of branch pruning for different numbers of branches, derived from the objective functions of Eqs. (20) and (21), the number of DO loops and skeletonized branches were identical (Fig. 3), in which the corresponding developed formulation was adapted depending on the boundary conditions at branch end. In Table 1, the optimized skeletonization results for the number of pruned branch combinations between one and six show that the higher the skeletonization branches are, the higher the required iterations are to complete multiple loops (Fig. 3). For instance, with six pruning branched elements, 151,200 iterations were required. Here, the computational cost for this iteration was approximately 53 min using an Intel (R) Core(TM) 15-1135G7 @ 2.40 GHz, with an equivalent cost of 0.021 s for one Fig. 6 Normalized pressure responses between IBM and MOC for the dual-branched pipeline system with partially open boundaries evaluation, substantially lower than that of the MOC. Additional computational cost would normally be required for a higher number of branched elements in a system, such as those of the Umbria pipeline; however, in the developed method, the computation cost was negligible. This can be attributed to the structure of the IBM, which requires the addition of mathematical terms for an additional branched element implementation regardless of the pipeline size or heterogeneity, or in this case, wave speed. The best  (Table 1). Although this was identical to those used by Meniconi et al. (2021a), the best combinations differed slightly between the two objective functions for pruning numbers > 3 (Table 1), owing to the difference in the objective domain of the as presented in Eqs. (20) and (21). Equation (20) tends to match higher responses in the time domain, whereas Eq. (21) tends to concentrate the overall match in frequency resonances between the original and skeletonized systems.
Branched skeletonization optimization was performed using the frequency-domain unsteady friction model for turbulent flow (Brunone et al. 1991;Kim 2020). The results are presented in Table 2 with the overall identified branched elements being similar to those in Table 1. However, these identified branches with pruning branch numbers of two and three were slightly different between the steady and unsteady friction models, in which the minimum objective functions for the latter were lower than those of the former. Additionally, the similarity in the identified branched elements between OF 1st and OF 2nd was also higher in the latter, attributed to the possible generation of the peak resonance in the unsteady friction model, which were lower than those of the steady model.

Conclusion
The pressure variation in multi-branched pipeline systems depends not only on the number, dimensions, and distribution of branched pipeline elements, but also on the boundary conditions of multiple branches. This study provides precise analytical formulations in the frequency domain for a main pipeline with multiple-branched systems. Mathematical developments of impedance were presented for the closed, open, and partially open boundary conditions for branched elements. Furthermore, unsteady friction models were also implemented by considering laminar and turbulent flow conditions. A comparison with the existing approach for the impedance method indicates that the proposed formulations provide a continuous impedance response in all frequency ranges, whereas the traditional formulation occasionally showed discontinuity in several peak response areas. The time-domain response comparison between existing approaches (such as MOC and IM) and this study (AIF) showed negligible differences. This indicates the validity of all modeling approaches, applicable in most cases unless the injected resonance does not perfectly match with the very minor unmatching frequencies. The proposed method was tested on a widely known skeletonization in the Umbria pipeline system. Two objective functions were introduced to consider the matching 4L/a Min(RMSE(H i )) 1 2 4 5 6 10 8.11 ⋅ 10 −2 Min(∑ΔESD i ) 1 2 4 6 9 10 2.50 ⋅ 10 11 between the original and skeletonized systems: the RMSE for the time-domain pressure response, and the ESD for the overall resonance comparison. The skeletonization results of the proposed method were comparable with those from an existing study; however, this study demonstrated a more practical computational cost. Further development of AIF-based multi-branched pipeline models for viscoelastic pipes will improve the applicability of modeling in real systems. Extension of the model structure for leak detection is another important issue for water resource management for urban water systems.
Authors Contributions Sanghyun Kim contributed to the study conception, design, analysis, and paper draft.
Funding This work was supported by (2022R1A4A5028840) from the National Research Foundation of the Republic of Korea.

Availability of Data and Materials
The supporting data are available from the corresponding author upon reasonable request.

Declarations
Ethical Approval Not applicable.

Competing Interests
The author has no relevant financial and non-financial interests to disclose.