A sampling layout method for determining the location of pipeline gas leaks
By constructing an information quantity matrix and a nonlinear optimization algorithm to optimize the coordinates of the sampling point, the problem of inefficient positioning caused by relying on experience in the existing technology is solved, and faster and more accurate positioning of pipeline leakage points is achieved, which improves the safety of gas pipelines.
Patent Information
- Application Number
- CN202210626622.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-06-03
- Publication Date
- 2025-08-26
- Estimated Expiration
- 2042-06-03
AI Technical Summary
In the prior art, the positioning sampling layout method of pipeline gas leakage points depends on the experience of the operator, resulting in low positioning efficiency and insufficient information, and the leakage location cannot be quickly and accurately positioned, posing safety hazards.
By constructing the sampling concentration expected value model and leakage position probability density function, an information quantity matrix is established, and the nonlinear multivariate optimization algorithm is used to search the optimal sampling point coordinates, and the sampling layout is optimized to improve the information quantity and positioning accuracy.
It realizes faster and more precise determination of the pipeline leakage location, improves the safety and positioning efficiency of gas pipeline operation, and solves the problem of insufficient information in the existing technology.
Smart Images

Figure CN114943196B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of gas leakage position determination, and in particular to a sampling layout method for determining the position of pipeline gas leakage points. Background Art
[0002] With the development of the petrochemical industry, natural gas, as a high-quality, efficient, and clean energy source, has gradually become the dominant source of urban gas, promoting socioeconomic development while reducing environmental pollution. However, as natural gas usage expands across a growing number of users and organizations, accidents pose a serious threat to public safety. Natural gas is a mixture primarily composed of methane, with small amounts of alkanes such as ethane, propane, and butane, as well as carbon dioxide, oxygen, nitrogen, hydrogen sulfide, and water. Due to its composition, natural gas is a flammable gas with a high fire hazard. When mixed with air, concentrations of 5% to 15% in the atmosphere can cause fires and explosions, potentially resulting in serious casualties, upon contact with an ignition source. However, over time, gas pipelines degrade, leading to leaks. These leaks often cause serious safety incidents, making the detection and location of these leaks essential.
[0003] Inspections using handheld or vehicle-mounted gas sensors or drone-mounted laser detection equipment are currently a common method for detecting gas pipeline leaks. When a leak is discovered, quickly pinpointing its precise location helps to initiate repairs as soon as possible, thereby reducing safety risks and economic losses. Once a leak is discovered within the pipeline's layout, more intensive gas concentration sampling and analysis are necessary to pinpoint the leak's location and facilitate subsequent repairs.
[0004] While new concentration detection technologies and equipment are constantly being introduced in related fields both domestically and internationally, there is no technology for optimizing sampling locations for gas leak locating. In current practice, sampling points are either determined based on operator experience or simply distributed evenly above or near pipelines. In practice, these sampling and analysis processes often require several weeks to achieve the required accuracy for pinpointing a leak, resulting in repair delays and potential safety hazards. Summary of the Invention
[0005] The purpose of the present invention is to provide an optimized sampling layout method for determining the location of pipeline gas leak points, thereby making full use of limited sampling equipment, increasing the amount of information in the sampling data, and ultimately improving positioning efficiency.
[0006] An embodiment of the present invention provides a sampling layout method for determining the location of a pipeline gas leak point, comprising the following steps:
[0007] S1, obtaining a model for estimating the expected value of sampling concentration based on the leakage location and sampling point coordinate information;
[0008] S2, obtaining the probability density function of the leakage location based on the existing information;
[0009] S3, establish the information matrix F with the coordinates of all sampling points as independent variables; the number of sampling points is N i , the information matrix F is of size N i ×N i The matrix of , formula (1) is the calculation formula of matrix elements:
[0010]
[0011] α and β are the row and column coordinates of the matrix elements associated with the sampling point; X and Y are the horizontal and vertical coordinate vectors of the sampling point respectively; is the covariance of the expected concentration values of the gas component m at the two sampling points α and β, where the expected concentration values are obtained by randomly sampling the leakage position using the expected concentration value model and the leakage position probability density function; σ m is the standard deviation of the measurement error of the equipment used to measure the concentration of component m; N m is the number of gas components involved in the expected value of the sample concentration model;
[0012] S4, search the horizontal and vertical coordinate vectors of the sampling points to optimize the information content index of the information content matrix.
[0013] The sampling layout method for determining the location of pipeline gas leakage points of the present invention as described above, further, the sampling concentration expected value model can provide an estimation of at least two or more gas concentrations.
[0014] The sampling layout method for determining the location of pipeline gas leakage points of the present invention as described above, further, the sampling concentration expected value model provides a concentration prediction in the form of formula (2);
[0015]
[0016] In formula (2): is the expected concentration value of gas component m at the i-th sampling point given by the sampling concentration expected value model; F m is the gas m concentration prediction function given by the model; x0 is the pipeline leakage location; X and Y are the horizontal and vertical coordinates of the sampling point i; N i is the number of sampling points.
[0017] The sampling layout method for determining the location of pipeline gas leakage points of the present invention as described above, further, the expected concentration value of the gas component m at the two sampling points α and β is obtained according to the following method: a random sampling of several leakage locations is generated according to the leakage location probability density function, and a leakage location series is composed of them; the expected concentration value corresponding to each leakage location in the leakage location series is calculated according to the sampling concentration expected value model and the sampling point coordinate information to form a concentration expected value series; and the covariance of the expected concentration value of the gas component m at the two sampling points α and β is calculated using the concentration expected value series.
[0018] The sampling layout method for determining the location of a pipeline gas leakage point of the present invention as described above can further employ a nonlinear multivariable optimization algorithm to search for the horizontal and vertical coordinate vectors of the sampling points.
[0019] The positioning sampling layout method for determining pipeline gas leakage points of the present invention can fully utilize the sampling concentration expected value model and the leakage position probability density function, and combine the two to construct an information content matrix associated with the horizontal and vertical coordinate vectors of the sampling points. By searching the horizontal and vertical coordinate vectors of the sampling points so that the information content index of the information content matrix reaches the optimal level, the optimal sampling coordinates of all sampling points are solved, so that the positioning sampling layout of the pipeline gas leakage point can obtain more information, solves the problems of low positioning efficiency and low information acquisition brought about by the current manual layout method based on operator experience, can more quickly determine the pipeline leakage position, and improves the overall safety of gas pipeline (such as gas pipeline) operation. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] In order to more clearly illustrate the present invention, the following description and illustrations of the present invention are provided. Obviously, the drawings described below only illustrate certain aspects of some exemplary embodiments of the present invention, and it is possible for a person skilled in the art to derive other drawings based on these drawings without inventive effort.
[0021] Figure 1 This is a flow chart of a sampling layout method for determining the location of a pipeline gas leak point according to a first embodiment of the present invention. DETAILED DESCRIPTION
[0022] Various exemplary embodiments of the present disclosure are described in detail below with reference to the accompanying drawings. The description of the exemplary embodiments is merely illustrative and is in no way intended to limit the present disclosure, its application, or use. The present disclosure can be implemented in many different forms and is not limited to the embodiments described herein. These embodiments are provided to make the present disclosure thorough and complete and to fully convey the scope of the present disclosure to those skilled in the art. It should be noted that unless otherwise stated, the relative arrangement of components and steps, numerical expressions, numerical values, etc. described in these embodiments should be interpreted as merely exemplary and not as limiting.
[0023] The words “include” or “comprising” and the like used in the present disclosure mean that the elements preceding the word include the elements listed after the word, and do not exclude the possibility of also including other elements.
[0024] All terms (including technical or scientific terms) used in this disclosure have the same meaning as those understood by ordinary technicians in the field to which this disclosure belongs, unless otherwise specifically defined. It should also be understood that terms defined in general dictionaries should be understood to have the same meaning as they have in the context of the relevant technology, and should not be interpreted in an idealized or extremely formal sense, unless otherwise explicitly defined herein.
[0025] Components, parameters such as specific models of components, relationships between components, and control circuits that are not described in detail in this section may be considered to be technologies, methods, and equipment known to ordinary technicians in the relevant fields, but where appropriate, such technologies, methods, and equipment should be considered as part of the specification.
[0026] Implementation Method 1
[0027] A sampling layout method for determining the location of a pipeline gas leak point includes the following steps:
[0028] S1, obtaining a model for estimating the expected value of sampling concentration based on the leakage location and sampling point coordinate information;
[0029] The sampling points are soil sampling points or aerial sampling points;
[0030] According to different theories and usage scenarios, the specific model used may be selected from the steady-state distribution model, Gaussian plume model, air mass model, etc. The model can give a concentration prediction in the form of formula (2);
[0031]
[0032] In formula (2): is the expected value of the concentration of gas component m at the i-th sampling point given by the model; F mis the gas m concentration prediction function given by the model; x0 is the pipeline leakage location; X and Y are the horizontal and vertical coordinates of the sampling point i; N i is the number of sampling points; N m is the number of gas components involved in the model, that is, the number of gas components that the model can predict. m Greater than or equal to 2, the concentration information of more gas components provides a richer basis for leak point location, which can further optimize the sampling coordinates and improve positioning accuracy.
[0033] S2, obtaining the probability density function of the leakage location based on the existing information;
[0034] Depending on the theory, the specific function used can be selected from uniform distribution functions, normal distribution functions, kernel density estimation functions, and other functions, and can be either continuous or discrete. The function can provide the probability density P(x) of a leak at any location x or within a region x of the pipeline. For example, for pipeline regions with severely insufficient information, a uniform distribution function can be used, meaning that the probability of a leak occurring at any location within the pipeline region is exactly the same.
[0035] S3, establish the information matrix function F with the coordinates of all sampling points as independent variables;
[0036] The number of sampling points is N i ; The information matrix F is an N i ×N i The matrix of size; Formula (1) gives the calculation method of each matrix element:
[0037]
[0038] α and β are the row and column coordinates of the matrix elements associated with the sampling points, respectively. The number of rows and columns of the matrix is equal to the number of sampling points. If each sampling point is numbered in sequence, the row and column coordinates of the matrix elements correspond to the sequence number of the sampling points. For example, when there are 3 sampling points, the information matrix F is a 3×3 matrix. The value range of α and β is 1, 2, 3, and all matrix elements are F. 1,1 (X, Y), F 1,2 (X, Y), F 1,3 (X, Y), F 2,1 (X, Y), F 2,2 (X, Y), F 2,3 (X, Y), F 3,1 (X, Y), F 3,2 (X, Y) and F 3,3 (X, Y); with matrix element F 1,2 (X, Y) as an example, the corresponding calculation formula is in The calculation involves the coordinates of the first sampling point, The calculation involves the coordinates of the second sampling point; that is, the matrix element F 1,2 (X, Y) is associated with the coordinate vector of the first sampling point and the coordinate vector of the second sampling point. Its calculation requires the coordinate vector of the first sampling point and the coordinate vector of the second sampling point. X and Y are the horizontal and vertical coordinate vectors of the sampling point respectively; represents the covariance of the expected concentration value of the gas component m at the two sampling points α and β according to the model in step 1, where the expected concentration value is obtained by using the expected concentration value model and random sampling of the leakage location generated according to the leakage location probability density function; σ m is the standard deviation of the measurement error of the equipment used to measure the concentration of component m; N m is the number of gas components involved in the sampling concentration expected value model. The above covariance calculation method is: the concentration expected value of gas component m at the two sampling points α and β is obtained according to the following method: generate a number of random samples of leakage locations according to the leakage location probability density function, and form a leakage location sequence from them; calculate the concentration expected value corresponding to each leakage location in the leakage location sequence according to the sampling concentration expected value model and the sampling point coordinate information, and form a concentration expected value sequence and The covariance of the expected concentration values of the gas component m at the two sampling points α and β is calculated using the expected concentration value series. In this step, the covariance is calculated by random sampling (according to the leakage location probability density function, a random sampling of several leakage locations is generated, and the leakage location series is composed of them) rather than analytical calculation. This is mainly because there is a nonlinear relationship between the expected concentration value and the leakage location coordinates in step 1, and the leakage location probability density function in step 2 may be more complicated. The use of random sampling method not only has faster calculation speed, but also better numerical stability. According to the law of large numbers, the more samples are taken, the closer the obtained covariance is to the theoretical true value. Taking into account factors such as computing power, model complexity, and time requirements, 100 to 500 points are generally selected, but in order to obtain higher layout accuracy, the number of samples can be greater than 500. The number of gas components is N m , solve the corresponding Then sum all component values to get the corresponding matrix elements.
[0039] S4, solve the optimal sampling coordinates of all sampling points.
[0040] Optimization of the sampling coordinates can be achieved by searching and determining the sampling coordinate vector value that optimizes the information content index of the information content matrix. There are many options for the information content index of the information content matrix, such as maximizing the matrix determinant (D optimization), maximizing the matrix rank (A optimization), and maximizing the minimum matrix eigenvalue (E optimization). The optimal coordinate vector value can be searched using a nonlinear multivariable optimization algorithm, a specific example of which is the particle swarm optimization algorithm.
[0041] It should be noted that although the steps of the above method of the present invention are marked S1, S2, S3 and S4, it should not be understood as limiting the execution or operation order of each step. For example, the difference in the execution order of S1 obtaining the model for calculating the expected value of the sampling concentration based on the leakage location and sampling point coordinate information and S2 obtaining the probability density function of the leakage location based on the existing information does not affect the establishment of the information matrix with the coordinates of all sampling points as independent variables.
[0042] The present invention proposes a positioning sampling layout method for determining pipeline gas leakage points. The method can fully utilize the sampling concentration expected value model and the leakage location probability density function, and combine the two to construct an information content matrix associated with the horizontal and vertical coordinate vectors of the sampling points. By searching the horizontal and vertical coordinate vectors of the sampling points so that the information content index of the information content matrix reaches the optimal level, the optimal sampling coordinates of all sampling points are solved, so that the positioning sampling layout for determining pipeline gas leakage points can obtain more information, solves the problems of low positioning efficiency and low information acquisition brought about by the current manual layout method based on operator experience, can more quickly determine the pipeline leakage location, and improve the overall safety of gas pipeline (such as gas pipeline) operation.
[0043] Implementation Method 2
[0044] To better illustrate the specific implementation method of the present invention, the following example uses five sampling points within a 12-meter-long, linear natural gas pipeline segment buried at a depth of 2.5 meters to locate a leak. Sampling points are selected within a 6-meter square on either side of the 12-meter segment. Holes with a diameter of 20 mm and a depth of 0.5 meters are drilled. The concentrations of methane (CH4, with an instrumental measurement error standard deviation of 0.5‰) and ethane (C2H6, with an instrumental measurement error standard deviation of 1‰) are measured at the bottom of the holes.
[0045] Step 1: Build a model to calculate the expected value of sampling concentration based on the pipeline leakage location and the coordinate information of the sampling points in the soil or air;
[0046] In this example, the distribution of methane (m=1) adopts the Gaussian diffusion model, and the distribution of ethane (m=2) adopts the steady-state distribution model, as shown in Equations (3.1 and 3.2):
[0047]
[0048]
[0049] The specific meanings of the parameters are as follows (the parameters are known data or obtained by fitting in previous experiments):
[0050]
[0051] Step 2: Obtain the probability density function of the leakage location based on the existing information;
[0052] In this example, a normal distribution with the midpoint of the target pipe section as the center and a 99% probability of the leakage point appearing within the target pipe section is used as the probability density function.
[0053] A random sample of 500 leak locations is generated according to the leak location probability density function, which forms a leak location sequence. The sequence of leak location x0 is 500 rows and 1 column. For ease of reading, it is folded into a table of 50 rows and 10 columns as follows:
[0054]
[0055]
[0056] Step 3: Establish an information matrix F with the coordinates of the five sampling points as independent variables. The obtained information matrix is a 5×5 matrix. Formula (1) is the calculation formula for the matrix elements:
[0057]
[0058] α and β are the row and column coordinates of the matrix elements associated with the sampling point; X and Y are the horizontal and vertical coordinate vectors of the sampling point respectively; is the covariance of the expected concentration values of gas component m at the two sampling points α and β. The expected concentration values of gas components m1 and m2 at the two sampling points α and β are obtained according to the following method: the expected concentration value corresponding to each leakage position in the leakage position series obtained in step 2 is calculated according to the sampling concentration expected value model and the sampling point coordinate information to form a concentration expected value series.
[0059] Step 4, solving the optimal sampling coordinates;
[0060] Search for the horizontal and vertical coordinate vectors of the sampling points to optimize the information content index of the information content matrix. This example uses the matrix determinant maximization (D optimization) method to search for the optimal solution using the particle swarm algorithm. The optimization results are: X = [-3.28, -1.49, 0.11, 1.03, 2.20], Y = [0, 0, 0, 0, 0], and the values of the elements of the information content matrix F are:
[0061] 4.90E+05 -2.56E+05 -1.98E+04 -3.01E+05 2.57E+05 -2.56E+05 4.91E+05 1.69E+05 2.12E+05 -8.95E+04 -1.98E+04 1.69E+05 4.21E+05 -3.25E+04 1.98E+05 -3.01E+05 2.12E+05 -3.25E+04 3.78E+05 -2.08E+05 2.57E+05 -8.95E+04 1.98E+05 -2.08E+05 4.35E+05
[0062] The determinant value (information content index) is 2.00E+27.
[0063] For Example 1, according to the classic cross positioning layout, five sampling points are distributed at the center of the natural gas pipeline segment and at cross positions 3 meters to the left, right, and front. The corresponding sampling point position coordinate vectors are X = [-3, 0, 0, 0, 3], Y = [0, -3, 0, 3, 0], and the values of the elements of the information matrix F are:
[0064] 3.86E+05 2.61E+03 -3.03E+04 2.61E+03 -3.06E+05 2.61E+03 3.11E+04 8.65E+04 3.11E+04 -7.06E+03 -3.03E+04 8.65E+04 4.26E+05 8.65E+04 -7.18E+04 2.61E+03 3.11E+04 8.65E+04 3.11E+04 -7.06E+03 -3.06E+05 -7.06E+03 -7.18E+04 -7.06E+03 4.36E+05
[0065] The determinant value (information content index) is 0. Here, an information content index of 0 does not mean "no information", but rather that there are sampling points that provide completely repeated information (in this example, the 2nd and 4th sampling points are measured symmetrically on both sides of the pipeline, providing repeated information for determining the leak location on the pipeline).
[0066] For example 2, according to the uniform sampling layout, 5 sampling points are evenly distributed directly above the pipeline. The corresponding sampling point position coordinate vectors are X = [-4.8, -2.4, 0, 2.4, 4.8], Y = [0, 0, 0, 0, 0], and the values of each element of the information matrix F are:
[0067] 2.25E+05 1.63E+05 -9.50E+04 -2.18E+05 -1.23E+05 1.63E+05 4.23E+05 2.32E+04 -3.10E+05 -2.25E+05 -9.50E+04 2.32E+04 4.26E+05 -1.98E+04 -1.21E+05 -2.18E+05 -3.10E+05 -1.98E+04 4.76E+05 1.71E+05 -1.23E+05 -2.25E+05 -1.21E+05 1.71E+05 2.55E+05
[0068] The determinant value (information content index) is 3.02E+26.
[0069] Accuracy Test: The positioning method employed was to substitute the sampling point coordinates into the concentration prediction model described in step 1 and solve for the leak location coordinate x0, minimizing the weighted sum of squared errors between the model predictions and the observed values at the sampling points (the weights being the inverse of the measurement error variance). This was achieved using the weighted least squares method. In actual testing, the optimized layout achieved an average positioning error of 330 mm, while the classic cross layout (control 1) achieved an average error of 490 mm, and the uniform sampling distribution (control 2) achieved an average error of 370 mm. The sampling layout method disclosed herein for determining the location of pipeline gas leaks improves sampling point positioning accuracy.
[0070] It should be understood that the specific embodiments described above are only used to explain the present invention, and the scope of protection of the present invention is not limited thereto. Any technician familiar with the technical field, within the technical scope disclosed by the present invention, who makes changes, substitutions, and combinations based on the technical solutions and inventive concepts of the present invention, should be covered by the scope of protection of the present invention.
Claims
1. A sampling layout method for determining the location of pipeline gas leakage points, characterized in that: The following steps are involved: S1, obtaining a model for estimating the expected value of sampling concentration based on the leakage location and sampling point coordinate information; S2, obtaining the probability density function of the leakage location based on the existing information; S3, establish the information matrix F with the coordinates of all sampling points as independent variables; The number of sampling points is N i , the information matrix F is of size N i ×N i The matrix of , formula (1) is the calculation formula of matrix elements: α and β are the row and column coordinates of the matrix elements associated with the sampling point; X and Y are the horizontal and vertical coordinate vectors of the sampling point respectively; is the covariance of the expected concentration values of the gas component m at the two sampling points α and β, where the expected concentration values are obtained by randomly sampling the leakage position using the expected concentration value model and the leakage position probability density function; σ m is the standard deviation of the measurement error of the equipment used to measure the concentration of component m; N m is the number of gas components involved in the expected value of the sample concentration model; S4, searching for the horizontal and vertical coordinate vectors of the sampling points so that the information content index of the information content matrix reaches the optimal value, and the sampling concentration expected value model can provide an estimation of at least two or more gas concentrations.
2. The sampling layout method for determining the location of pipeline gas leakage points according to claim 1, characterized in that: The sample concentration expected value model gives a concentration prediction in the form of formula (2); In formula (2): is the expected concentration value of gas component m at the i-th sampling point given by the sampling concentration expected value model; F m is the gas m concentration prediction function given by the model; x0 is the pipeline leakage location; X and Y are the horizontal and vertical coordinates of the sampling point i; N i is the number of sampling points.
3. The sampling layout method for determining the location of pipeline gas leakage points according to claim 1, characterized in that: The expected concentration values of the gas component m at the two sampling points α and β are obtained according to the following method: a random sampling of several leakage locations is generated according to the leakage location probability density function, and a leakage location series is composed of them; the expected concentration value corresponding to each leakage location in the leakage location series is calculated according to the sampling concentration expected value model and the sampling point coordinate information, and a concentration expected value series is composed; the covariance of the expected concentration values of the gas component m at the two sampling points α and β is calculated using the concentration expected value series.
4. The sampling layout method for determining the location of pipeline gas leakage points according to claim 1, characterized in that: The horizontal and vertical coordinate vectors of the search sampling points can be optimized using a nonlinear multivariable optimization algorithm.