Modelling hydraulic regimes of pipeline systems using the theory of hydraulic circuits in the Internet

Along with a brief description of the main problems of pipeline systems (water, gas, heat, fire extinguishing), it is claimed that the energy and resource saving reserves available here can, to a large extent, be implemented through the rational organization of hydraulic operating modes using modern methods of mathematical and computer modelling. The paper reviews the software and computing complex of the new generation. The complex provides the possibility of remote application of effective methods for calculating modes. The principles of the complex implementation ensure the execution of calculations anytime, anywhere, and with any number of users with a connection to the global Internet and a standard web browser. The paper briefly outlines the technologies that form the basis of such complex, as well as its user capabilities and computational characteristics. Results of the pilot industrial operation of the complex are also described. The complex is potentially applicable in different industries (energy, housing and utilities, construction, etc.) and spheres of activity (design, operation, research, training). It would be also useful to the specialists of different levels (engineers, researchers, graduate students, etc.).


Introduction
Significant reserves of energy and resource saving in pipeline systems (water, gas, heat supply, fire extinguishing, etc.) (PLS) can be implemented in the way of rational organization of their operation modes.Due to a number of progressive trends in the general aging of equipment, changes in the structure and level of loads, there are problems in many cities and towns of Russia associated with the non-design operating modes, increased production costs, transportation and distribution of water, energy and material losses, violations of technological requirements, consumers, increased accidents, and others.The solution of these problems is possible only through the analysis and rationalization of PLS operation modes based on the application of modern methods of mathematical and computer modelling.
To date, in many organizations of Russia (MESI SB RAS [1], LLC "Polyterm" [2], CJSC Potok [3], etc.) and abroad (Intergraph Corporation [4], Sunrise Systems Ltd [5], Bentley Systems Incorporated [6], etc.), the corresponding software and computer complexes (SCC) are actively developed and implemented on a commercial basis.However, in view of the wide range of tasks to be solved, as well as the high level of development, cost and complexity of development, these SCCs are used mainly at large enterprises that operate large-scale water supply systems.
Below is a brief description of the software of the new generation developed by the MESI SB RAS, namely the SCC "ISIGR" [7], which does not require purchasing and downloading on users' computers.

The task and methods of calculating the flow distribution in PLS
The traditional model of steady isothermal flow distribution in PLS includes two analogues of the Kirchhoff law and the closing relations (flow laws): where mn  is the matrix of incidents of nodes and branches of the calculation scheme with elements 1 The problem is to determine the vectors x , y and ( 1 m− ) that is the dimensional vector of nodal pressures P for the given matrices A , vector Q , and the well-known f ( ) ii x for 1, in = and the given pressure in one of the nodes ( m P ).Numerous methods and algorithms for solving this problem are known on the basis of the model (1) ; however, as shown in the monograph [8], two methods are basic: contour expenditure and nodal pressures.Both are based on the Newton method, but with a preliminary decrease in the order of the linearized systems of equations.
Thus, for example, the method of nodal pressures [8] involves searching for a solution in the space of nodal pressures and reduces to the organization of the process x ;  is the vector-function inverse to f with elements () ii  y , 1, in = .It can be seen that the computational scheme of the method of nodal pressures does not depend on the form y = f (x), to which only the requirements of monotonic increase are required to ensure the uniqueness of solving the flow distribution problem [8].However, the specifics of implementing this method depend on the specifics of calculating () kk  = xy and x f  .We show this by the example of the well-known Darcy-Weisbach formula [9] for the loss of pressure in the pipeline, which concretizes y = f (x): where d, l are the pipeline's diameter and length, m; g is the acceleration of free fall m/s 2 ; is the velocity of fluid flow, m/s; x is the mass flow, kg/s.
The coefficient of hydraulic resistance  in (2) depends on the Reynolds number Re (V) = Vd/v, where v is the coefficient of kinematic viscosity (m 2 /s) of the fluid, which is assumed to be constant for the isothermal flow.To calculate  , in turn, there are many formulas that reflect the purpose of the pipeline, its type, the material of the inner coating, the service life, the flow regime of the medium (laminar, transient, turbulent), etc. Shevelev's formula [10,11] : where 01 , , , A A C  are the coefficients that depend on the pipe material and the flow regime.
Summarizing all the known cases of formulas for calculating  of the i-th passive branch of the design scheme, we can write that The expression for the derivative in case (4) has the form where 2 3 7 ,, s s / 32 / ( ) The calculation (5) for a pipeline of an arbitrary type and purpose only requires specification ,

Vi
 .In this case, searching for k i x can be performed iteratively, for example, using the simple iteration method, when 1 | | / s( ) sign( ) Or by the method of Newton, according to which 1 , ( f ( )) / (f ) where k is the index of the iteration of the flow distribution calculation, t is the index of the search iteration k i x , 01 : k ii − = xx , which avoids applying the known technique of double iteration cycles [12].
The traditional model of the active branch (pump unit, pumping station) has the form ( ) . However, they can differ by different exponents of powers bq,i, by the number Ki, and by the composition of the summands (with the forced assignment of aq,i = 0 for some q).For the parameterization (6), a "piecewise" approximation of one characteristic by different polynomials can be applied [12].

Purpose and main features of SCC
The SCC "ISIGR" (Internet Hydraulic Calculation System) [13] is the final implementation of the models and methods of the theory of hydraulic circuits [8], designed to simulate the modes of multi-loop water, gas, and fire extinguishing systems in the Internet.Accordingly, it allows to perform calculations at anytime, anywhere, and any number of users with an Internet connection and a standard web browser.This SCC can be useful to the specialists of design and operation organizations, scientific and research institutions, engineers, and graduate students.The complex has an intuitive interface, a small nesting of editable forms and convenient mechanisms for creating and editing network diagrams and data, which significantly reduces the time necessary for training and application.
The graphical interface is implemented on the basis of the Microsoft Silverlight software component [14,15], which to use SCC in a standard Web browser (Windows).The SCC is based on the client-server architecture, where the client is a graphical interface being provided to users, and the server part is responsible for performing calculations using the library of payment modules.This approach does not require users to have high-performance computers, install, and update the SCC in the workplace, since the computing part is on the server (the developer's computer).
The graphical interface (Fig. 1) provides the following options.
1. Creating and editing calculation schemes, which are assembled from nodes and branches (links between nodes), having the appropriate symbols.The nodes in the "ISIGR" can be of three types: connecting, consumer, and source ones.There also various branches: a site, stop valves, a pump set.The mechanism for working on schemes is similar to modern programs that allow you to edit charts containing graphic objects.Thus, for example, a method is used where the end of the link when moving "sticks" to the nearest node in some radius, which speeds up the assembly of the circuit.Or, when one observes inserting a node into an existing link when the new node also "sticks" to the link during its addition to the circuit.
2. Using graphic maps, space images, and other images of the terrain to link network diagrams.
3. Saving and loading calculation schemes is implemented without attracting network databases, which allows users to store data on a personal computer.
4. Parameters are entered in the table elements using "smart fields," which give the user the choice of the element's parameters from the list of the equipment database, the description of which is given below (Figure 2).
5. Sending schematic source data to the server for calculating and receiving the calculation results and test results, in case of errors.
6. Mapping and interpretation of the calculation results together with the initial data is carried out in the following ways: • Graphicalon the callouts to the elements of the circuit (Figure 1); • Tabularin the individual properties window of elements (Fig. 2); • Colorassigning colors for links with respect to a given criterion; • Animationallows you to accentuate the scheme's elements that require user attention, moving graphics; • Symbolicallows to automatically replace or supplement the image of an element relative to its parameter.
There is the possibility of constructing a piezometric graph along a given path, either manually (by uniquely indicated key nodes of the network) or automatically, when the shortest path search methods are applied.
The SCC "ISIGR" allows solving the problems of flow distribution in an arbitrary structure (with arbitrary number and location of sources, pumping stations, reservoirs, consumption nodes, and other elements) and configuration (multi-contour, tree, mixed) with fixed [8] and non-fixed [16] loads.Calculation modules in the "ISIGR" library includes the implementation of several different methods for solving load flow problems as classical (methods of nodal pressures and outline costs [8]) and new ones ("chordal" nodal pressure method the method of simple iteration [18][19][20], modified methods of nodal pressures [21], and contour costs [22]).In this case, sparseness is used when solving a system of linear algebraic equations in these methods, which in most cases reduces the total counting time by an average of two orders of magnitude.It is planned to further expand the library as the existing ones develop and alternative methods gradually emerge.
The conducted research on comparative testing of the effectiveness of different methods showed the following.The computational costs depend not only on the number of iterations of solving the nonlinear flow distribution problem, but also on the costs of each iteration that are associated with the specific configuration of the hydraulic circuit.At each iteration, one or another system of linear algebraic equations is solved, differing in dimension and methods of formation.For example, in the pressure method, the number of solved equations is m-1, and in the contour flow method is c, where m is the number of nodes of the design scheme, and c is the number of its independent circuits.The ratio m c for different schemes can vary within a very wide range [13].
A user can choose not only the calculation method but also the calculated dependence.For example, in order to calculate the head losses in the pipeline section of the water supply system in the SCC, the formulas of Shevelev, Shifrinson [23], Prandtl-Nikuradze [24,25], Kohlbrook-Watt [9] or Hazen-Williams [26] are used abroad.The loss of pressure in the stop valve is calculated according to the known Darcy formula, and the head of the pumping unitaccording to the polynomial, which approximates its performance.
The equipment database is intended for parametrization of the elements of the calculation circuits through the interface of the SCC.It contains a description of tube assortments (about 6000 positions out of 19 GOSTs), a set of coefficients of approximating dependencies for tabulated characteristics of stop valves and pumps, and a standard set of local resistances.Users of the complex also have the ability to add hardware parameters to the database.

Practical experience of using the SCC
The SCC "ISIGR" has been tested in open access (see 51.isem.irk.ru) on the Internet since 2013.Analysis of the data on the number of performed calculations of real networks and their fragments (Fig. 3) by users (Fig. 4) from different cities (Fig. 5) allows us to conclude that there is a significant and growing demand for this development, despite the fact that there was no any measures to to promote it.
Die to the implemented computational capabilities [13], the SCC "ISIGR" allows to perform calculations for circuits up to 1000 knots, which corresponds to several tens of thousands of people.The time being spent on calculation takes no more than 5 seconds, taking into account the necessary of data transmission in the Internet.

Conclusion
In sum, the paper has described essential characteristics of the SCC "ISIGR", which is an innovative development allowing (for the first time in domestic and foreign practice) to remotely apply effective methods for calculating the regimes of water, gas, and fire suppression systems in the Internet.The SCC is equipped with all the necessary functions that facilitate the process of setting information and interpreting the results of calculations.To date, with its help, tens of thousands of multivariate calculations of hundreds of hydraulic networks have been performed by a large number of Internet users from dozens of cities in Russia and the near abroad.In the future, it is planned to expand this development for modeling the heat supply systems.
ji a =−, if node j is the initial (final) for branch i, and 0 ji a = if the branch i is not incident to the node j; A -[(1) ] mn − is the incidence matrix formed from A deleting one of the lines; x , y -n are the dimensional vectors of flow and pressure differentials on branches of the design scheme; f( ) x -n is the dimensional vector function with elements f ( ) ii x , 1, in = , reflecting the laws of pressure drop from consumption (flow laws) on the branches of the design scheme; node j, and 0 j = Q if the node j is a simple join point of branches; is the dimensional vector of nodal pressures.
x f  is the diagonal matrix of partial derivatives f/ ii  x , 1, in = , at the point k

;
 is the density of the transported medium, kg/m 3 .

Fig. 1 .
Fig. 1.Example of a circuit with a graphic substrate-card.

Fig. 2 .
Fig. 2. Example of a site parameterization using the equipment database.

Fig. 3 .
Fig. 3.The schedule of the number of settlements on the SCC "ISIGR".
where Yi is the value of the head developed by the pump, and