Multi-gas-source complex pipe network calorific value assignment method
By adopting steady-state simulation model and multi-gas source pipeline component tracking model in a multi-gas source pipeline network, combining the node-solving equation method and the Gauss Sedal iterative method, the calorific value assignment lag, insufficient accuracy and complex calculation in traditional methods are solved. The problem of the problem of rapid and accurate allocation of heat generation to each node of the pipeline network is achieved, and is suitable for real-time applications of large-scale complex pipeline networks.
Patent Information
- Application Number
- CN202411348999.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-26
- Publication Date
- 2025-01-03
- Estimated Expiration
- 2044-09-26
AI Technical Summary
The traditional multi-gas source pipeline heat generation assignment method is difficult to dynamically adapt to changes in gas flow, resulting in lag in assignment results, insufficient accuracy and high computational complexity, which cannot meet the needs of modern pipeline management.
The steady-state simulation model of the natural gas pipeline network combined with the multi-gas source pipeline component tracking model is adopted. By solving the node equation method and the Gauss Sedal iterative method, the correlation matrix and calculation equation system are constructed to achieve rapid and accurate heating of each node of the pipeline network. Assign value.
It improves the accuracy and real-time value assignment, ensures the accuracy of gas supply quality and energy measurement, and reduces the computational complexity, and is suitable for real-time applications of large-scale complex pipelines.
Smart Images

Figure CN119249737A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the field of calorific value assignment for a multi-gas source pipeline network, and in particular to a calorific value assignment method for a multi-gas source complex pipeline network. Background Art
[0002] In a pipeline network system with multiple gas sources, the gas composition and calorific value of different gas sources often differ, such as the proportion of hydrocarbons such as methane, ethane, and propane, and the degree of mixing of inert gases such as carbon dioxide and nitrogen. These factors directly affect the total calorific value of natural gas. In order to optimize energy utilization and rationally allocate the gas supply of each gas source, each node in the pipeline network needs to understand the composition and calorific value information of natural gas in real time. However, traditional pipeline management methods are difficult to cope with the dynamics and uncertainty of complex pipeline networks with multiple gas sources, resulting in many problems in the assignment of gas composition and calorific value.
[0003] In a complex pipeline network with multiple gas sources, it is necessary to accurately assign the gas components and calorific value of each node in the pipeline network. First, it can help the pipeline network operator to understand the gas quality status in the pipeline network in real time, so as to ensure that the safety and quality of gas supply meet national standards. Secondly, accurate calorific value information is the basis of energy trade and measurement, and plays an important role in safeguarding the interests of upstream and downstream users and energy trading parties. In addition, a reasonable assignment method can optimize pipeline scheduling, reduce energy loss, and improve overall operating efficiency. Therefore, it is of great practical significance to propose an effective calorific value assignment method for complex pipeline networks with multiple gas sources.
[0004] At present, the traditional methods for assigning heat value of pipe networks are mainly based on empirical formulas, linear interpolation and steady-state simulation. These methods often have the following problems:
[0005] (1) Lack of dynamics: Traditional methods usually ignore the real-time dynamic changes of gas flow in the pipeline network and cannot reflect the gas composition and calorific value distribution of each node in real time. This leads to a lag in the assignment results and is difficult to meet the requirements of modern pipeline network management.
[0006] (2) Insufficient assignment accuracy: The assignment method based on empirical formulas and linear interpolation cannot accurately handle the complex component changes after mixing multiple gas sources, resulting in insufficient calorific value calculation accuracy, which may affect the gas supply quality and energy metering accuracy.
[0007] (3) High computational complexity: Although some steady-state simulation methods can improve the accuracy of the assignment to a certain extent, their calculation process is complex and difficult to realize real-time application in large-scale pipeline networks, which limits their promotion in actual operations.
[0008] Therefore, there is an urgent need for a calorific value assignment method that can dynamically adapt to the complex network environment of multiple gas sources to improve the accuracy and real-time performance of the assignment. The present invention provides a calorific value assignment method for a complex network of multiple gas sources, which uses a steady-state simulation model of a natural gas network as the underlying model, couples the multi-gas source pipeline component tracking and calorific value assignment model, sets a convergence deviation in the iterative process of key parameters, and realizes the rapid assignment of the calorific value of each node in the network while ensuring the calculation accuracy, effectively making up for the shortcomings of traditional methods. Summary of the invention
[0009] The present invention provides a method for assigning calorific value of a complex pipe network with multiple gas sources, which is characterized by comprising the following steps:
[0010] S1: Based on the network topology, generate the correlation matrix A, input the basic parameters of the network, set the node pressure convergence deviation and the initial value of each pipeline flow;
[0011] The basic parameters of the pipeline network include gas source quality components, pipeline length, pipeline inner diameter, pipeline roughness, pipeline ambient temperature, node pressure boundary and node load boundary;
[0012] The initial flow rate of the pipeline is a fixed value determined based on historical production data;
[0013] S2: Using the node equation method, the pipeline admittance matrix is constructed based on the initial pipeline flow, the pipeline flow and node pressure are inversely calculated, and the pipeline pressure drop is calculated by substituting them into the hydraulic calculation formula of the gas transmission pipeline;
[0014] S3: Calculate the physical properties of natural gas based on the flow rate and pressure back-calculation results and the BWRS equation, wherein the physical properties include density, compressibility factor, dynamic viscosity and specific heat at constant pressure;
[0015] S4: Determine the actual direction of the pipeline based on the calculation results of pipeline flow and node pressure, solve the thermal equation, and calculate the pipeline temperature drop, average temperature and node temperature;
[0016] S5: Set the initial gas source ratio of the node, construct the gas source ratio calculation equation group, use Gauss-Saidal iteration to complete the solution, and determine the node gas source ratio;
[0017] S6: Based on the calculation results of water-thermal parameters, the natural gas flow time in each pipeline is calculated to complete the node calorific value assignment.
[0018] Preferably, it is characterized in that the specific steps of S2 are:
[0019] S201: According to the impedance S calculation formula, the hydraulic calculation formula of the gas pipeline is converted into a linear equation system expression, as shown in the following formula:
[0020] Impedance S calculation formula:
[0021] Gas pipeline hydraulic calculation formula:
[0022] The calculation formula of pressure drop after conversion is: Where S is the pipeline impedance; Δp is the pipeline pressure drop; Q is the volume flow rate under standard conditions; P Q is the starting pressure of the pipeline; P Z is the pressure at the end of the pipeline; D is the inner diameter of the pipeline; λ is the hydraulic friction coefficient; L is the length of the pipeline; T0 is the standard temperature; P0 is the standard pressure; R is the gas constant of air; is the pressure drop of pipeline j at the kth iteration; is the impedance of pipeline j at the kth iteration; is the flow rate of pipeline j in the k-1th iteration. For the first iteration, it is taken as the initial pipeline flow rate; is the flow rate of pipeline j in the kth iteration; is the relative pressure of node i at the kth iteration;
[0023] S202: According to the node relative pressure calculation formula, a linear relationship between pipeline flow and pressure drop is constructed, as shown in the following formula:
[0024] Node relative pressure formula:
[0025] Linear relationship between pipeline flow rate and pressure drop: Where p0 is the reference node pressure, which is usually the gas source node; is the pressure of node i at the kth iteration; is the admittance of pipeline j at the kth iteration;
[0026] S203: The relationship between the pipe flow rate and the pressure drop of the pipe network is expressed in the form of a matrix, and an admittance matrix is constructed. The process is shown in the following formula:
[0027] Pipeline flow and pressure drop matrix form: Q = GΔP
[0028] Admittance matrix:
[0029] Where, Q is the flow vector; G is the admittance matrix; ΔP is the pressure drop vector;
[0030] S204: Based on the node continuity equation, the converted pressure drop formula is converted into a matrix form, substituted into the pipeline flow and pressure drop matrix form, and the node pressure calculation equation group and the pipeline flow calculation equation group are obtained. The node pressure and pipeline flow are inversely calculated. The process is shown in the following formula:
[0031] Nodal continuity equation: AQ = q
[0032] Node pressure calculation equations: AGA T P = q
[0033] Pipeline flow calculation equation group: Q = GΔP = GA T P
[0034] Where P is the node relative pressure vector; q is the node load vector;
[0035] S205: Substituting the calculation results of the node pressure and pipeline flow into the hydraulic calculation formula of the gas transmission pipeline to calculate the pipeline pressure drop;
[0036] S206: Calculate the node pressure deviation during the iteration process and compare it with the convergence deviation. If the calculated deviation is smaller than the convergence deviation, output the calculation result. Otherwise, repeat S202 to S205 until the convergence deviation is satisfied.
[0037]
[0038] In the formula, ε p is the nodal pressure convergence deviation.
[0039] Preferably, it is characterized in that the specific steps of S4 are:
[0040] S401: Determine the actual direction of the pipeline according to the calculation results of the pipeline flow and node pressure in S2;
[0041] S402: Determine the number of nodes connected to the pipeline and determine the node N i Whether it is a gas source node, if it is a gas source node, it is assigned a value based on historical data; if it is a non-gas source node, it is calculated using the node temperature calculation formula, as shown below:
[0042]
[0043] Where, T out is the temperature of the outflow node i; m in is the mass flow rate flowing into node i; T in is the temperature of the inflow node i; m out is the mass flow rate out of node i;
[0044] S403: Calculate the pipeline temperature drop and average temperature according to the actual flow direction of the pipeline. The calculation formula is as follows:
[0045] Pipeline temperature drop calculation formula:
[0046]
[0047] The calculation formula of average pipe temperature is: Where, T Zis the terminal temperature of the pipeline; T0 is the ambient temperature of the pipeline; a is a dimensionless parameter; L is the length of the pipeline; T Q is the starting temperature of the pipeline; D i is the Joule-Thomson coefficient; K is the total heat transfer coefficient of the pipeline; M is the gas mass flow rate; T Z is the average pipe temperature.
[0048] Preferably, it is characterized in that the specific steps of S5 are:
[0049] S501: Set the initial gas source ratio of the node according to historical data, and construct a gas source ratio calculation equation, as shown in the following formula:
[0050]
[0051] In the formula, is the proportion of gas source j flowing out of node i; is the proportion of gas source j flowing into node i. If gas source j is located at node i, the proportion of gas source j is 100%; is the mass flow rate flowing into node i; is the mass flow rate out of node i;
[0052] S502: using Gauss-Saidar iteration to solve the gas source ratio calculation equation for each node in the pipeline network;
[0053] S503: Calculate the deviation between the gas source ratio result and the previous iteration result, as shown in the following formula. If the deviation is within the convergence deviation range, the solution is completed and the hydraulic and thermal parameters of the next iteration are corrected; otherwise, repeat S502 until the convergence deviation requirement is met.
[0054]
[0055] In the formula, ε y is the node gas source ratio convergence deviation.
[0056] Preferably, it is characterized in that the specific steps of S6 are:
[0057] S601: According to the calculation formula of the node instantaneous velocity and the pipeline average velocity, a flow time formula is constructed to calculate the flow time of natural gas in the pipeline, as shown in the following formula:
[0058] Node instantaneous speed calculation formula:
[0059] The formula for calculating the average pipeline velocity is:
[0060] Flow time calculation formula: In the formula, Q p is the flow rate of pipe p; Ti is the temperature of node i; p i is the pressure at node i; v i is the instantaneous velocity of node i; v j is the average flow velocity in pipe section p; Δt l is the flow time of natural gas through pipeline p;
[0061] S602: By calculating the flow time of the gas components of the gas source to the assigned station, the natural gas components of the assigned node are assigned and calculated. The formula is as follows:
[0062] X y (x,t)=X y (0,t-Δt)
[0063]
[0064] Where, X j (x, t) is the molar fraction of natural gas component y at the node to be assigned at a distance of x km from the gas source at time t; Δt is the natural gas flow time from the gas source to the station to be assigned;
[0065] S603: According to the result of the node component assignment, the node heat value is assigned. The heat value assignment formula is as follows:
[0066]
[0067] In the formula, is the ideal gas calorific value of the node to be assigned at time t, which is x km away from the gas source; is the calorific value of the ideal gas of component y; H x,t is the actual gas calorific value of the node to be assigned at time t, which is x km away from the gas source; Z x,t is the natural gas compression factor of the node to be assigned at a distance of x km from the gas source at time t.
[0068] In summary, the present invention has the following beneficial effects:
[0069] (1) Improve the accuracy of assignment: The traditional calorific value assignment method cannot accurately handle the complex component changes after the mixing of multiple gas sources, resulting in insufficient accuracy of the calculation results. The present invention can track the gas component changes of each node by introducing a steady-state simulation model and a multi-gas source pipeline component tracking model, and accurately assign the calorific value of each node, thereby improving the assignment accuracy and ensuring the accuracy of gas supply quality and measurement;
[0070] (2) Improve computational efficiency: The computational complexity of traditional steady-state simulation methods is high, making it difficult to implement real-time applications in large-scale pipe networks. The present invention uses a node equation method that has low initial value requirements, excellent convergence performance, and high computational accuracy to solve the underlying steady-state simulation model. It can quickly assign values to each node in the pipe network while ensuring accuracy, thereby improving the real-time application capability in large-scale complex pipe networks. BRIEF DESCRIPTION OF THE DRAWINGS
[0071] Figure 1 Flowchart of this method
[0072] Figure 2 Pipeline network topology diagram
[0073] Figure 3 Calculation result of node gas source ratio DETAILED DESCRIPTION
[0074] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0075] like Figure 1 As shown, the present invention provides a method for assigning calorific value of a complex multi-gas source pipeline network based on a DFS algorithm, which is characterized by comprising the following steps:
[0076] S1: Based on the network topology, generate the correlation matrix A, input the basic parameters of the network, set the node pressure convergence deviation and the initial value of each pipeline flow;
[0077] The basic parameters of the pipeline network include gas source quality components, pipeline length, pipeline inner diameter, pipeline roughness, pipeline ambient temperature, node pressure boundary and node load boundary;
[0078] The initial flow rate of the pipeline is a fixed value determined based on historical production data;
[0079] S2: Using the node equation method, the pipeline admittance matrix is constructed based on the initial pipeline flow, the pipeline flow and node pressure are inversely calculated, and the pipeline pressure drop is calculated by substituting them into the hydraulic calculation formula of the gas transmission pipeline;
[0080] S3: Calculate the physical properties of natural gas based on the flow rate and pressure back-calculation results and the BWRS equation, wherein the physical properties include density, compressibility factor, dynamic viscosity and specific heat at constant pressure;
[0081] S4: Determine the actual direction of the pipeline based on the calculation results of pipeline flow and node pressure, solve the thermal equation, and calculate the pipeline temperature drop, average temperature and node temperature;
[0082] S5: Set the initial gas source ratio of the node, construct the gas source ratio calculation equation group, use Gauss-Saidal iteration to complete the solution, and determine the node gas source ratio;
[0083] S6: Based on the calculation results of water-thermal parameters, the natural gas flow time in each pipeline is calculated to complete the node calorific value assignment.
[0084] In one embodiment, the specific steps of S2 are:
[0085] S201: According to the impedance S calculation formula, the hydraulic calculation formula of the gas pipeline is converted into a linear equation system expression, as shown in the following formula:
[0086] Impedance S calculation formula:
[0087] Gas pipeline hydraulic calculation formula:
[0088] The calculation formula of pressure drop after conversion is: Where S is the pipeline impedance; Δp is the pipeline pressure drop; Q is the volume flow rate under standard conditions; P Q is the starting pressure of the pipeline; P Z is the pressure at the end of the pipeline; D is the inner diameter of the pipeline; λ is the hydraulic friction coefficient; L is the length of the pipeline; T0 is the standard temperature; P0 is the standard pressure; R is the gas constant of air; is the pressure drop of pipeline j at the kth iteration; is the impedance of pipeline j at the kth iteration; is the flow rate of pipeline j in the k-1th iteration. For the first iteration, it is taken as the initial pipeline flow rate; is the flow rate of pipeline j in the kth iteration; is the relative pressure of node i at the kth iteration;
[0089] S202: According to the node relative pressure calculation formula, a linear relationship between pipeline flow and pressure drop is constructed, as shown in the following formula:
[0090] Node relative pressure formula:
[0091] Linear relationship between pipeline flow rate and pressure drop: Where p0 is the reference node pressure, which is usually the gas source node; is the pressure of node i at the kth iteration; is the admittance of pipeline j at the kth iteration;
[0092] S203: The relationship between the pipe flow rate and the pressure drop of the pipe network is expressed in the form of a matrix, and an admittance matrix is constructed. The process is shown in the following formula:
[0093] Pipeline flow and pressure drop matrix form: Q = GΔP
[0094] Admittance matrix:
[0095] Where, Q is the flow vector; G is the admittance matrix; ΔP is the pressure drop vector;
[0096] S204: Based on the node continuity equation, the converted pressure drop formula is converted into a matrix form, substituted into the pipeline flow and pressure drop matrix form, and the node pressure calculation equation group and the pipeline flow calculation equation group are obtained. The node pressure and pipeline flow are inversely calculated. The process is shown in the following formula:
[0097] Nodal continuity equation: AQ = q
[0098] Node pressure calculation equations: AGA T P = q
[0099] Pipeline flow calculation equation group: Q = GΔP = GA T P
[0100] Where P is the node relative pressure vector; q is the node load vector;
[0101] S205: Substituting the calculation results of the node pressure and pipeline flow into the hydraulic calculation formula of the gas transmission pipeline to calculate the pipeline pressure drop;
[0102] S206: Calculate the node pressure deviation during the iteration process and compare it with the convergence deviation. If the calculated deviation is smaller than the convergence deviation, output the calculation result. Otherwise, repeat S202 to S205 until the convergence deviation is satisfied.
[0103]
[0104] In the formula, ε p is the nodal pressure convergence deviation.
[0105] In one embodiment, the specific steps of S4 are:
[0106] S401: Determine the actual direction of the pipeline according to the calculation results of the pipeline flow and node pressure in S2;
[0107] S402: Determine the number of nodes connected to the pipeline and determine the node N i Whether it is a gas source node, if it is a gas source node, it is assigned a value based on historical data; if it is a non-gas source node, it is calculated using the node temperature calculation formula, as shown below:
[0108]
[0109] Where, T out is the temperature of the outflow node i; m in is the mass flow rate flowing into node i; T in is the temperature of the inflow node i; m out is the mass flow rate out of node i;
[0110] S403: Calculate the pipeline temperature drop and average temperature according to the actual flow direction of the pipeline. The calculation formula is as follows:
[0111] Pipeline temperature drop calculation formula:
[0112]
[0113] The calculation formula of average pipe temperature is: Where, T Z is the terminal temperature of the pipeline; T0 is the ambient temperature of the pipeline; a is a dimensionless parameter; L is the length of the pipeline; T Q is the starting temperature of the pipeline; D i is the Joule-Thomson coefficient; K is the total heat transfer coefficient of the pipeline; M is the gas mass flow rate; T Z is the average pipe temperature.
[0114] In one embodiment, the specific steps of S5 are:
[0115] S501: Set the initial gas source ratio of the node according to historical data, and construct a gas source ratio calculation equation, as shown in the following formula:
[0116]
[0117] In the formula, is the proportion of gas source j flowing out of node i; is the proportion of gas source j flowing into node i. If gas source j is located at node i, the proportion of gas source j is 100%; is the mass flow rate flowing into node i; is the mass flow rate out of node i;
[0118] S502: using Gauss-Saidar iteration to solve the gas source ratio calculation equation for each node in the pipeline network;
[0119] S503: Calculate the deviation between the gas source ratio result and the previous iteration result, as shown in the following formula. If the deviation is within the convergence deviation range, the solution is completed and the hydraulic and thermal parameters of the next iteration are corrected; otherwise, repeat S502 until the convergence deviation requirement is met.
[0120]
[0121] In the formula, ε y is the node gas source ratio convergence deviation.
[0122] In one embodiment, the specific steps of S6 are:
[0123] S601: According to the calculation formula of the node instantaneous velocity and the pipeline average velocity, a flow time formula is constructed to calculate the flow time of natural gas in the pipeline, as shown in the following formula:
[0124] Node instantaneous speed calculation formula:
[0125] The formula for calculating the average pipeline velocity is:
[0126] Flow time calculation formula: In the formula, Q p is the flow rate of pipe p; T i is the temperature of node i; p i is the pressure at node i; v i is the instantaneous velocity of node i; v j is the average flow velocity in pipe section p; Δt l is the flow time of natural gas through pipeline p;
[0127] S602: By calculating the flow time of the gas components of the gas source to the assigned station, the natural gas components of the assigned node are assigned and calculated. The formula is as follows:
[0128] X y (x,t)=X y (0,t-Δt)
[0129]
[0130] Where, X j (x, t) is the molar fraction of natural gas component y at the node to be assigned at a distance of x km from the gas source at time t; Δt is the natural gas flow time from the gas source to the station to be assigned;
[0131] S603: According to the result of the node component assignment, the node heat value is assigned. The heat value assignment formula is as follows:
[0132]
[0133] In the formula, is the ideal gas calorific value of the node to be assigned at time t, which is x km away from the gas source; is the calorific value of the ideal gas of component y; H x,t is the actual gas calorific value of the node to be assigned at time t, which is x km away from the gas source; Zx,t is the natural gas compression factor of the node to be assigned at a distance of x km from the gas source at time t.
[0134] In order to prove that the calorific value assignment method of a multi-gas source complex pipeline network provided by the present invention can realize the rapid and accurate assignment of the calorific value of each node in the pipeline network and effectively solve the problem of calorific value assignment in a multi-gas source pipeline network, a case analysis is carried out by taking a domestic multi-gas source pipeline network as an example. The pipeline network topology is as follows Figure 2 As shown, from Figure 2 It can be seen that the pipeline network has 34 nodes, 39 pipelines, 7 basic rings and 3 gas sources, among which nodes n1, n8 and n31 are gas source nodes, named gas source 1, gas source 2 and gas source 3 respectively. The structural parameters of the pipeline network are shown in Table 1, the node boundary conditions are shown in Table 2, and the gas source components are shown in Table 3. Set the initial flow rate of the pipeline to 100m 3 / h, node pressure convergence deviation ε p and gas source ratio convergence deviation ε y Both are 10 -6 , the calorific value is assigned, the overall solution time is 21s, and a total of 945 iterations are performed to reach the convergence deviation.
[0135] Table 1 Pipeline network structure parameters
[0136]
[0137]
[0138] Table 2 Node boundary conditions
[0139]
[0140] Note: Negative flow represents gas supply flow, n1, n8, and n31 are all gas sources, so the flow boundary is a negative number.
[0141] Table 3 Gas source component parameters
[0142]
[0143] Based on the simulation results of TGNET, the mainstream simulation software in the field of pipe network, the error of the node pressure, node temperature and pipeline flow is shown in Table 4 to Table 6. As can be seen from Table 4, the calculation error of the pipe network node pressure is small, the maximum relative error is 0.051%, and the average relative error is 0.012%; as can be seen from Table 5, the calculation results of the pipe network node temperature are highly consistent with the simulation results, the maximum relative pressure error is 0.410%, and the average relative error is 0.130%; as can be seen from Table 6, the error of the pipe network pipeline flow calculation results is stable in a small range, the maximum relative pressure is 0.092%, and the average relative error is 0.012%.
[0144] Table 4 Node pressure calculation results
[0145]
[0146] Table 5 Node temperature calculation results
[0147]
[0148]
[0149] Table 6 Pipeline flow calculation results
[0150]
[0151] The calculation results of the gas source ratio of the pipeline network are as follows: Figure 3 As shown. Figure 3 It can be seen that Figure 3 It can be seen that the proportion of gas source 1 in nodes n1 to n5 is 100%, indicating that their gas quality components are only affected by gas source 1; the proportion of gas source 2 in nodes n7 to n9 is 100%, indicating that their gas quality components are only affected by gas source 2; the proportion of gas source 3 in nodes n24 to n34 is 100%, indicating that their gas quality components are only affected by gas source 3; the remaining nodes receive gas from the three upstream gas source nodes at the same time, resulting in the gas quality components and calorific value of these nodes being affected by these three gases at the same time, among which gas source 2 accounts for the highest proportion, followed by gas source 3, and gas source 1 accounts for the least. When the gas quality of the three gas sources fluctuates, 15 nodes such as n6, n10, and n11 are most affected by the gas quality fluctuation of gas source 2.
[0152] The comparison between the calorific value assignment results of each node and the node calorific value results obtained by TGNET simulation is shown in Table 7. As can be seen from Table 7, the calorific value results of each node assigned by this method are basically the same as those obtained by TGNET simulation, indicating that the constructed multi-gas source pipeline network steady-state simulation model has high accuracy, can simulate the distribution of gas in the pipeline network, and analyze the influence range of the gas source, and can quickly and accurately assign the heat value of each node in the pipeline network, making up for the shortcomings of the traditional calorific value assignment method, and effectively solving the problem of calorific value assignment in the multi-gas source pipeline network.
[0153] Table 7 Node heat calculation results
[0154]
[0155] The above is only an example of the embodiment of the present specification and is not intended to limit the embodiment of the present specification. For those skilled in the art, the embodiment of the present specification may have various changes and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the embodiment of the present specification shall be included in the scope of the claims of the embodiment of the present specification.
Claims
1. A method for assigning calorific value of a complex pipe network with multiple gas sources, characterized in that: The following steps are involved: S1: Based on the network topology, generate the correlation matrix A, input the basic parameters of the network, set the node pressure convergence deviation and the initial value of each pipeline flow; The basic parameters of the pipeline network include gas source quality components, pipeline length, pipeline inner diameter, pipeline roughness, pipeline ambient temperature, node pressure boundary and node load boundary; The initial flow rate of the pipeline is a fixed value determined based on historical production data; S2: Using the node equation method, the pipeline admittance matrix is constructed based on the initial pipeline flow, the pipeline flow and node pressure are inversely calculated, and the pipeline pressure drop is calculated by substituting them into the hydraulic calculation formula of the gas transmission pipeline; S3: Calculate the physical properties of natural gas based on the flow rate and pressure back-calculation results and the BWRS equation, wherein the physical properties include density, compressibility factor, dynamic viscosity and specific heat at constant pressure; S4: Determine the actual direction of the pipeline based on the calculation results of pipeline flow and node pressure, solve the thermal equation, and calculate the pipeline temperature drop, average temperature and node temperature; S5: Set the initial gas source ratio of the node, construct the gas source ratio calculation equation group, use Gauss-Saidal iteration to complete the solution, and determine the node gas source ratio; S6: Based on the calculation results of water-thermal parameters, the natural gas flow time in each pipeline is calculated to complete the node calorific value assignment.
2. A method for assigning calorific value of a complex multi-gas source pipeline network as claimed in claim 1, characterized in that: The specific steps of S2 are: S201: According to the impedance S calculation formula, the hydraulic calculation formula of the gas pipeline is converted into a linear equation system expression, as shown in the following formula: Impedance S calculation formula: Gas pipeline hydraulic calculation formula: The calculation formula of pressure drop after conversion is: Where S is the pipeline impedance; Δp is the pipeline pressure drop; Q is the volume flow rate under standard conditions; P Q is the starting pressure of the pipeline; P Z is the pressure at the end of the pipeline; D is the inner diameter of the pipeline; λ is the hydraulic friction coefficient; L is the length of the pipeline; T0 is the standard temperature; P0 is the standard pressure; R is the gas constant of air; is the pressure drop of pipeline j at the kth iteration; is the impedance of pipeline j at the kth iteration; is the flow rate of pipeline j in the k-1th iteration. For the first iteration, it is taken as the initial pipeline flow rate; is the flow rate of pipeline j in the kth iteration; P i k is the relative pressure of node i at the kth iteration; S202: According to the node relative pressure calculation formula, a linear relationship between pipeline flow and pressure drop is constructed, as shown in the following formula: Node relative pressure formula: Linear relationship between pipeline flow rate and pressure drop: Where p0 is the reference node pressure, which is usually the gas source node; is the pressure of node i at the kth iteration; is the admittance of pipeline j at the kth iteration; S203: The relationship between the pipe flow rate and the pressure drop of the pipe network is expressed in the form of a matrix, and an admittance matrix is constructed. The process is shown in the following formula: Pipeline flow and pressure drop matrix form: Q = GΔP Admittance matrix: Where, Q is the flow vector; G is the admittance matrix; ΔP is the pressure drop vector; S204: Based on the node continuity equation, the converted pressure drop formula is converted into a matrix form, substituted into the pipeline flow and pressure drop matrix form, and the node pressure calculation equation group and the pipeline flow calculation equation group are obtained. The node pressure and pipeline flow are inversely calculated. The process is shown in the following formula: Nodal continuity equation: AQ = q Node pressure calculation equations: AGA T P = q Pipeline flow calculation equation group: Q = GΔP = GA T P Where P is the node relative pressure vector; q is the node load vector; S205: Substituting the calculation results of the node pressure and pipeline flow into the hydraulic calculation formula of the gas transmission pipeline to calculate the pipeline pressure drop; S206: Calculate the node pressure deviation during the iteration process and compare it with the convergence deviation. If the calculated deviation is smaller than the convergence deviation, output the calculation result. Otherwise, repeat S202 to S205 until the convergence deviation is satisfied. In the formula, ε p is the nodal pressure convergence deviation.
3. A method for assigning calorific value of a complex multi-gas source pipeline network as claimed in claim 1, characterized in that: The specific steps of S4 are: S401: Determine the actual direction of the pipeline according to the calculation results of the pipeline flow and node pressure in S2; S402: Determine the number of nodes connected to the pipeline and determine the node N i Whether it is a gas source node, if it is a gas source node, it is assigned a value based on historical data; if it is a non-gas source node, it is calculated using the node temperature calculation formula, as shown below: Where, T out is the temperature of the outflow node i; m in is the mass flow rate flowing into node i; T in is the temperature of the inflow node i; m out is the mass flow rate out of node i; S403: Calculate the pipeline temperature drop and average temperature according to the actual flow direction of the pipeline. The calculation formula is as follows: Pipeline temperature drop calculation formula: The calculation formula of average pipe temperature is: Where, T Z is the terminal temperature of the pipeline; T0 is the ambient temperature of the pipeline; a is a dimensionless parameter; L is the length of the pipeline; T Q is the starting temperature of the pipeline; D i is the Joule-Thomson coefficient; K is the total heat transfer coefficient of the pipeline; M is the gas mass flow rate; T Z is the average pipe temperature.
4. A method for assigning calorific value of a complex multi-gas source pipeline network according to claim 1, characterized in that: The specific steps of S5 are: S501: Set the initial gas source ratio of the node according to historical data, and construct a gas source ratio calculation equation, as shown in the following formula: In the formula, is the proportion of gas source j flowing out of node i; is the proportion of gas source j flowing into node i. If gas source j is located at node i, the proportion of gas source j is 100%; is the mass flow rate flowing into node i; is the mass flow rate out of node i; S502: using Gauss-Saidar iteration to solve the gas source ratio calculation equation for each node in the pipeline network; S503: Calculate the deviation between the gas source ratio result and the previous iteration result, as shown in the following formula. If the deviation is within the convergence deviation range, the solution is completed and the hydraulic and thermal parameters of the next iteration are corrected; otherwise, repeat S502 until the convergence deviation requirement is met. In the formula, ε y is the node gas source ratio convergence deviation.
5. A method for assigning calorific value of a complex multi-gas source pipeline network as claimed in claim 1, characterized in that: The specific steps of S6 are: S601: According to the calculation formula of the node instantaneous velocity and the pipeline average velocity, a flow time formula is constructed to calculate the flow time of natural gas in the pipeline, as shown in the following formula: Node instantaneous speed calculation formula: The average pipeline velocity calculation formula is: Flow time calculation formula: In the formula, Q p is the flow rate of pipe p; T i is the temperature of node i; p i is the pressure at node i; v i is the instantaneous velocity of node i; v j is the average flow velocity in pipe section p; Δt l is the flow time of natural gas through pipeline p; S602: By calculating the flow time of the gas components of the gas source to reach the assigned station, the natural gas components of the assigned node are assigned and calculated. The formula is as follows: X y (x,t)=X y (0,t-Δt) Where, X j (x, t) is the molar fraction of natural gas component y at the node to be assigned at a distance of x km from the gas source at time t; Δt is the natural gas flow time from the gas source to the station to be assigned; S603: According to the result of the node component assignment, the node heat value is assigned. The heat value assignment formula is as follows: In the formula, is the ideal gas calorific value of the node to be assigned at time t, which is x km away from the gas source; is the calorific value of the ideal gas of component y; H x,t is the actual gas calorific value of the node to be assigned at time t, which is x km away from the gas source; Z x,t is the natural gas compression factor of the node to be assigned at a distance of x km from the gas source at time t.
Citation Information
Patent Citations
Modeling method for collaborative operation of power system and natural gas system
CN108062599A
Natural gas pipeline network gas calorific value prediction method suitable for mixed gas source
CN113987943A
Method and device for predicting gas calorific value of natural gas pipeline network and storage medium
CN116822694A
Natural gas pipeline network steady state simulation method based on Newton iteration method, medium and equipment
CN117235950A
Fuel gas component and calorific value data assignment system
CN221575615U