Gas leakage temperature compensation method and system based on IoT gas appliances

By constructing two-dimensional coordinates in the IoT gas tool and performing cluster analysis, a category cluster is generated and the fitting function of the relationship between gas flow and temperature is fitted, the problem of gas metering deviation caused by temperature changes is solved, and the accurate compensation of gas flow and leakage identification is achieved.

CN120027872BActive Publication Date: 2025-08-29GUANGZHOU JINRAN INTELLIGENT SYST CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510197312.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-02-21
Publication Date
2025-08-29
Estimated Expiration
2045-02-21

AI Technical Summary

Technical Problem

Temperature changes affect the physical properties of the gas, resulting in deviations in the metering of the IoT ultrasonic gas meter, resulting in abnormal gas leakage identification.

Method used

By setting the monitoring period, gas flow, external temperature and pipeline pressure data are obtained, two-dimensional coordinates are constructed and clustered analysis is performed, category clusters are generated, fitted the fitting function of the relationship between gas flow and temperature, and data correction is performed to compensate for gas flow metering.

Benefits of technology

It improves the accuracy of gas flow metering, reduces the possibility of misjudgment and leakage judgment of gas leakage, and ensures the safety and reliability of the gas system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120027872B_ABST
    Figure CN120027872B_ABST
Patent Text Reader

Abstract

The present invention discloses a gas leakage temperature compensation method and system based on an Internet of Things gas appliance, belonging to the field of gas metering technology. The method and system specifically include: setting a monitoring period, and acquiring monitoring data of an Internet of Things ultrasonic gas meter within the monitoring period in real time; clustering the monitoring data using gas temperature and pipeline pressure as feature vectors to generate a plurality of category clusters; selecting any category cluster, acquiring external temperature data and gas flow data corresponding to all feature points in the category cluster, constructing a point map using the external temperature data as the horizontal coordinate and the gas flow data as the vertical coordinate, and fitting the point map to obtain a fitting function; acquiring the monitoring data of the current Internet of Things ultrasonic gas meter, and correcting the gas flow data according to the fitting function to obtain final gas flow data. The present invention improves gas metering accuracy and reduces the possibility of misjudgment and missed judgment of gas leakage.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of gas metering, and in particular to a method and system for compensating gas leakage temperature based on an Internet of Things (IoT) gas appliance. Background Art

[0002] In modern gas transmission systems, accurate monitoring and metering of gas flow is crucial for ensuring stable energy supply, optimizing resource allocation, and ensuring safe system operation. With the acceleration of urbanization and the increase in industrial activity, demand for gas, a clean and efficient energy source, is growing. Therefore, precise gas flow measurement has become an integral part of gas supply chain management.

[0003] The IoT ultrasonic gas meter is an advanced gas metering device that combines IoT technology with ultrasonic measurement principles. This device utilizes the relationship between the propagation speed of ultrasound in gas and its flow rate. By measuring the propagation time of the ultrasonic signal, it accurately calculates gas flow. Its unique non-invasive nature enables measurement without disrupting the fluid flow, which is crucial for maintaining the continuous flow of gas within pipelines. Its high-precision measurement capability means that even minute flow rate changes can be accurately captured, which is crucial for accurate gas billing and fine-tuning the supply-demand balance. Furthermore, the IoT ultrasonic gas meter's rapid response enables real-time monitoring of flow rate changes, providing real-time data support for dynamic gas system management. The application of IoT ultrasonic gas meters in gas pipeline flow monitoring not only improves measurement accuracy but also enhances system reliability and safety. Real-time analysis of gas flow data allows for timely detection of anomalies such as leaks or blockages, enabling appropriate measures to prevent accidents.

[0004] However, in actual operation, temperature changes will directly affect the physical properties of gas, especially its volume and density. For example, when the temperature rises, the gas expands, the volume increases, and the density decreases; when the temperature drops, the gas compresses, the volume decreases, and the density increases. The working principle of the IoT ultrasonic gas meter generally depends on the propagation speed of ultrasound in the medium. The propagation speed of ultrasound is closely related to the physical properties of the medium (such as temperature, density, viscosity, gas or liquid composition, etc.). Changes in the temperature of the medium will directly affect its density, viscosity, and other thermodynamic properties, thereby changing the propagation speed of ultrasound. At the same time, changes in the external temperature will also cause the optimal frequency of the IoT ultrasonic gas meter to change, causing deviations in gas measurement and leading to abnormal leak identification. Summary of the Invention

[0005] The purpose of the present invention is to provide a method and system for compensating gas leakage temperature based on an IoT gas appliance, to solve the following technical problems:

[0006] However, in actual operation, temperature changes directly affect the physical properties of gas, especially its volume and density. For example, when the temperature rises, the gas expands, increasing its volume and decreasing its density; when the temperature drops, the gas compresses, decreasing its volume and increasing its density. The operating principle of the IoT ultrasonic gas meter generally relies on the propagation speed of ultrasound in the medium. The propagation speed of ultrasound is closely related to the physical properties of the medium (such as temperature, density, viscosity, and the composition of the gas or liquid). Changes in the medium's temperature directly affect its density, viscosity, and other thermodynamic properties, thereby changing the propagation speed of ultrasound. At the same time, changes in external temperature can also cause the optimal frequency of the IoT ultrasonic gas meter to change, causing deviations in gas measurement and leading to abnormal gas leak identification.

[0007] The purpose of the present invention can be achieved through the following technical solutions:

[0008] A gas leakage temperature compensation method based on an Internet of Things gas appliance is characterized by comprising the following steps:

[0009] S1, set a monitoring period, and obtain monitoring data of the IoT ultrasonic gas meter in real time during the monitoring period; the monitoring data includes gas flow data, external temperature data, gas temperature data, and pipeline pressure data;

[0010] S2, with gas temperature as the horizontal coordinate and pipeline pressure as the vertical coordinate, construct a two-dimensional coordinate system to generate feature points corresponding to all monitoring data. Select any feature point as the center, set the clustering control radius R, obtain the feature point density P within the control radius R of each feature point, and calculate the mean feature point density VagP. If there is any feature point with a feature point density P greater than VagP within the radius R, then use this feature point as the core point and generate a category cluster to generate several category clusters.

[0011] S3: Select any cluster, obtain the ambient temperature data and gas flow data corresponding to all feature points in the cluster, construct a point map with the ambient temperature data as the horizontal coordinate and the gas flow data as the vertical coordinate, and fit the point map to obtain a fitting function F(T). The fitting function F(T) is used to fit the relationship between the gas flow data and the ambient temperature.

[0012] S4, obtaining the monitoring data of the current IoT ultrasonic gas meter, and correcting the gas flow data according to the fitting function to obtain the final gas flow data.

[0013] As a further solution of the present invention, it is characterized in that, in S2, the specific process of setting the cluster control radius R is:

[0014] Taking any feature point as the center, calculate the Euclidean distance d between the feature point and any other feature point, sum each Euclidean distance to get u, and get the control radius R based on the value u. The calculation formula is as follows:

[0015]

[0016] Among them, n is the number of all feature points, u is the sum of the Euclidean distances between any feature point and all other feature points, and d is the Euclidean distance between any feature points.

[0017] As a further solution of the present invention: It is characterized in that, in S2, the specific calculation process of the feature point density mean VagP is:

[0018] P=a / (πR 2 );

[0019]

[0020] Among them, a is the number of feature points within the control radius R, and n is the number of all feature points.

[0021] As a further solution of the present invention: it is characterized in that in the said S2, if in any category cluster, there is a non-core point whose density P within the control radius R is also greater than VagP, then the category cluster generated by the non-core point is merged with the original category cluster to generate several category clusters.

[0022] As a further solution of the present invention, it is characterized in that said S3 further includes:

[0023] Taking any characteristic point in the cluster as the center and R as the radius, several subclusters are generated. The degree of aggregation of each subcluster is calculated and marked as DP. The subcluster with the highest DP value is selected as the representative cluster. The mean of each axis coordinate of the characteristic point corresponding to the representative cluster is calculated. The mean of the horizontal axis coordinate is calibrated to the standard gas temperature data, and the mean of the vertical axis coordinate is calibrated to the standard pipeline pressure data. The standard gas temperature data and standard pipeline pressure data of all clusters are obtained.

[0024] The calculation formula of DP is:

[0025]

[0026] Among them, z is the number of feature points in any sub-cluster, z0 is the central feature point, and v0 is the other feature points in the sub-cluster.

[0027] As a further solution of the present invention: It is characterized in that, in S3, the specific expression of the fitting function is:

[0028] The point map is fitted using the least squares method to obtain the fitting line equation: F = k × T + b, where k represents the slope of the fitting line, T is the gas temperature, b represents the intercept of the fitting line, and k and b are constants.

[0029] As a further solution of the present invention, it is characterized in that it also includes:

[0030] The reference outside temperature is determined to be H0. The outside temperature data corresponding to the feature points in any category cluster is obtained as the feature points of H0 and marked as undetermined feature points. The product of the standard gas temperature data and the standard pipeline pressure data is calculated to obtain the target parameter. The relationship between the gas flow data at the same outside temperature and the target parameter is linearly fitted to obtain the fitting function F(G).

[0031] As a further solution of the present invention, it is characterized in that, in said S4, the specific process of correcting the gas flow data is as follows:

[0032] S11, extracting gas temperature data T and pipeline pressure data N from the current IoT ultrasonic gas meter monitoring data, obtaining standard gas temperature data T'i and standard pipeline pressure data N'i corresponding to any category cluster, and calculating the similarity Xi between the current IoT ultrasonic gas meter monitoring data and any category cluster according to the calculation formula Xi = α(T-T'i)+β(N-N'i);

[0033] S12: Select the category cluster corresponding to the minimum similarity MINHi and mark it as the target category cluster. Obtain the fitting function F(T) corresponding to the target category cluster. Obtain the current outside temperature data H1 and the reference outside temperature H0. Calculate the difference ΔH between H1 and H0. Substitute ΔH into the fitting function F(T) to calculate a first correction score. Sum the current gas flow data and the first correction score to obtain the first gas flow data.

[0034] S13: Determine reference gas temperature data and reference pipeline pressure data, calculate the product of the reference gas temperature data and the reference pipeline pressure data to obtain a reference target parameter, extract gas temperature data and pipeline pressure data from the monitoring data, calculate the product of the gas temperature data and the pipeline pressure data to obtain a current target parameter, calculate the difference between the current target parameter and the reference target parameter, substitute the difference into the fitting function F(G), calculate a second correction score, sum the first gas flow data and the second correction score to obtain final gas flow data.

[0035] A gas leakage temperature compensation system based on an Internet of Things gas appliance is characterized by comprising:

[0036] The data acquisition module is used to set the monitoring period and obtain the monitoring data of the IoT ultrasonic gas meter in real time during the monitoring period; the monitoring data includes gas flow data, external temperature data, gas temperature data and pipeline pressure data;

[0037] The data analysis module is used to construct a two-dimensional coordinate system with the gas temperature as the horizontal coordinate and the pipeline pressure as the vertical coordinate, generate feature points corresponding to all monitoring data, select any feature point as the center, set the clustering control radius R, obtain the feature point density P within the control radius R of each feature point, and calculate the feature point density mean VagP. If there is any feature point with a feature point density P greater than VagP within the radius R, then the feature point is used as the core point and a category cluster is generated to generate several category clusters.

[0038] Select any category cluster, obtain the ambient temperature data and gas flow data corresponding to all feature points in the category cluster, construct a point map with the ambient temperature data as the horizontal coordinate and the gas flow data as the vertical coordinate, and fit the point map to obtain the fitting function F(T). The fitting function F(T) is used to fit the relationship between the gas flow data and the ambient temperature.

[0039] The result generation module is used to obtain the monitoring data of the current IoT ultrasonic gas meter, correct the gas flow data according to the fitting function, and obtain the final gas flow data.

[0040] Beneficial effects of the present invention:

[0041] The present invention first determines the monitoring period and obtains the monitoring data of the Internet of Things ultrasonic gas meter within the monitoring period, which is the basis for subsequent analysis. By taking the gas temperature as the horizontal coordinate and the pipeline pressure as the vertical coordinate, a two-dimensional coordinate is constructed to generate characteristic points corresponding to all monitoring data, and the monitoring data is clustered to obtain several category clusters. It can be understood that the metering data of the Internet of Things ultrasonic gas meter is affected by the external temperature data, gas temperature data and pipeline pressure data at the same time. The data can be grouped by clustering. First, the monitoring data is grouped using the gas temperature data and pipeline pressure data as characteristic values, so as to obtain the gas flow data corresponding to different external temperatures under similar gas temperature data and pipeline pressure data, and the external temperature data is taken as the horizontal coordinate. The gas flow data is used as the vertical coordinate, and a point map is constructed. The point map is fitted to obtain a fitting function, which determines the relationship between the gas flow data and the ambient temperature. This serves as the basis for subsequent correction of the gas flow data. Similarly, the reference ambient temperature is determined as H0. The feature point corresponding to the ambient temperature data of H0 in any category cluster is obtained and marked as a pending feature point. The product of the standard gas temperature data and the standard pipeline pressure data is calculated to obtain the target parameter. A linear fit is performed on the relationship between the gas flow data and the target parameter at the same ambient temperature to obtain a fitting function. The reference target parameter and reference ambient temperature are determined. The currently detected gas flow data is compensated according to the fitting function, thereby achieving accurate gas flow measurement. The present invention considers the influence of ambient temperature, pipeline pressure, and gas temperature on gas flow data, and utilizes cluster analysis and fitting functions to compensate the metering data, thereby improving metering accuracy and reducing the possibility of misjudgment and omission of gas leaks. BRIEF DESCRIPTION OF THE DRAWINGS

[0042] The present invention will be further described below with reference to the accompanying drawings.

[0043] Figure 1 It is a flow chart of a gas leakage temperature compensation method based on an Internet of Things gas appliance of the present invention. DETAILED DESCRIPTION

[0044] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only 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 making any creative efforts shall fall within the scope of protection of the present invention.

[0045] See also Figure 1 As shown, the present invention is a gas leakage temperature compensation method based on an Internet of Things gas appliance, which is characterized by comprising the following steps:

[0046] S1, set a monitoring period, and obtain monitoring data of the IoT ultrasonic gas meter in real time during the monitoring period; the monitoring data includes gas flow data, external temperature data, gas temperature data, and pipeline pressure data;

[0047] S2, with gas temperature as the horizontal coordinate and pipeline pressure as the vertical coordinate, construct a two-dimensional coordinate system to generate feature points corresponding to all monitoring data. Select any feature point as the center, set the clustering control radius R, obtain the feature point density P within the control radius R of each feature point, and calculate the mean feature point density VagP. If there is any feature point with a feature point density P greater than VagP within the radius R, then use this feature point as the core point and generate a category cluster to generate several category clusters.

[0048] S3: Select any cluster, obtain the ambient temperature data and gas flow data corresponding to all feature points in the cluster, construct a point map with the ambient temperature data as the horizontal coordinate and the gas flow data as the vertical coordinate, and fit the point map to obtain a fitting function F(T). The fitting function F(T) is used to fit the relationship between the gas flow data and the ambient temperature.

[0049] S4, obtaining the monitoring data of the current IoT ultrasonic gas meter, and correcting the gas flow data according to the fitting function to obtain the final gas flow data.

[0050] The present invention first determines the monitoring period and obtains the monitoring data of the Internet of Things ultrasonic gas meter within the monitoring period, which is the basis for subsequent analysis. By taking the gas temperature as the horizontal coordinate and the pipeline pressure as the vertical coordinate, a two-dimensional coordinate is constructed to generate characteristic points corresponding to all monitoring data, and the monitoring data is clustered to obtain several category clusters. It can be understood that the metering data of the Internet of Things ultrasonic gas meter is affected by the external temperature data, gas temperature data and pipeline pressure data at the same time. The data can be grouped by clustering. First, the monitoring data is grouped using the gas temperature data and pipeline pressure data as characteristic values, so as to obtain the gas flow data corresponding to different external temperatures under similar gas temperature data and pipeline pressure data, and the external temperature data is taken as the horizontal coordinate. The target parameter is obtained by multiplying the standard gas temperature data by the standard pipeline pressure data. A linear fit is performed on the relationship between the gas flow data and the target parameter at the same ambient temperature to obtain a fitting function. The reference target parameter and reference ambient temperature are determined. The currently detected gas flow data is compensated according to the fitting function, thereby achieving accurate gas flow measurement. The present invention considers the influence of ambient temperature, pipeline pressure, and gas temperature on gas flow data and utilizes cluster analysis and fitting functions to compensate the metering data, thereby improving metering accuracy and efficiency and reducing the possibility of misjudgment and omission of gas leaks.

[0051] It is worth noting that in the gas pipeline transmission system, after the gas is extracted from the natural gas well or gas production facility, it is transmitted to the target location through the pipeline system. During the transportation process, due to different external temperatures, the gas temperature in the pipeline is also different. However, the amount of gas input into each pipeline is the same. Therefore, by obtaining gas monitoring data before each pipeline network first enters the pressure regulating valve, it is possible to directly monitor the real-time data of the same time period at the output end of different pipelines. Therefore, there is no need to rely on a large amount of test data, and the gas transmission information under actual operating conditions can be accurately captured, providing support for the efficient management and safe operation of the gas pipeline network.

[0052] In the prior art, a gas detector is also used to identify whether a gas leak has occurred. The gas detector determines whether there is a risk of gas leakage by detecting the concentration of combustible gas in the air. When the gas concentration reaches the preset alarm value, the alarm controller will issue an alarm signal and instruction, and may combine with a solenoid valve or fan to drive exhaust, cut off the power and close the valve, etc. However, the gas detector is affected by environmental factors such as temperature and humidity during use. Extreme environmental conditions may cause unstable equipment performance, or even false alarms or missed alarms, affecting the accuracy of the detection results. To ensure that gas leaks can be accurately and reliably detected in various environments, the present invention can be combined with a gas detector to perform more comprehensive gas leak detection.

[0053] In a preferred embodiment of the present invention, the specific process of setting the cluster control radius R in S2 is as follows:

[0054] Taking any feature point as the center, calculate the Euclidean distance d between the feature point and any other feature point, sum each Euclidean distance to get u, and get the control radius R based on the value u. The calculation formula is as follows:

[0055]

[0056] Among them, n is the number of all feature points, u is the sum of the Euclidean distances between any feature point and all other feature points, and d is the Euclidean distance between any feature points.

[0057] In another preferred embodiment of the present invention, in S2, the specific calculation process of the feature point density mean VagP is as follows:

[0058] P=a / (πR 2 );

[0059]

[0060] Among them, a is the number of feature points within the control radius R, and n is the number of all feature points.

[0061] In another preferred case of this embodiment, S2 also includes merging the category cluster generated by the non-core point with the original category cluster to generate several category clusters if the density P within the control radius R of the non-core point in any category cluster is also greater than VagP.

[0062] In another preferred embodiment of the present invention, the step S3 further includes:

[0063] Taking any characteristic point in the cluster as the center and R as the radius, several subclusters are generated. The degree of aggregation of each subcluster is calculated and marked as DP. The subcluster with the highest DP value is selected as the representative cluster. The mean of each axis coordinate of the characteristic point corresponding to the representative cluster is calculated. The mean of the horizontal axis coordinate is calibrated to the standard gas temperature data, and the mean of the vertical axis coordinate is calibrated to the standard pipeline pressure data. The standard gas temperature data and standard pipeline pressure data of all clusters are obtained.

[0064] The calculation formula of DP is:

[0065]

[0066] Among them, z is the number of feature points in any sub-cluster, z0 is the central feature point, and v0 is the other feature points in the sub-cluster.

[0067] The DP value represents the average distance from other feature set points to the center point in each cluster. The smaller the DP value, the higher the compactness of the subcluster and the better the clustering effect. By selecting the cluster with the smallest DP value in each category cluster, the most representative subcluster in the category cluster can be obtained. By analyzing each representative cluster, it is not necessary to analyze each feature set in the category cluster, thereby reducing the workload of actual data analysis and improving work efficiency. At the same time, the representative cluster is calculated for the mean of any axis coordinates of the feature points corresponding to the representative cluster, the mean of the horizontal axis coordinate is calibrated to the standard gas temperature data, and the mean of the vertical axis coordinate is calibrated to the standard pipeline pressure data. The optimal standard reference conditions for each category cluster can be determined, thereby providing a basis for subsequent analysis.

[0068] In another preferred embodiment of the present invention, in S3, the specific expression of the fitting function is:

[0069] The point map is fitted using the least squares method to obtain the fitting line equation: F = k × T + b, where k represents the slope of the fitting line, T is the gas temperature, b represents the intercept of the fitting line, and k and b are constants.

[0070] In another preferred embodiment of the present invention, the method further includes:

[0071] The reference outside temperature is determined to be H0. The outside temperature data corresponding to the feature points in any category cluster is obtained as the feature points of H0 and marked as undetermined feature points. The product of the standard gas temperature data and the standard pipeline pressure data is calculated to obtain the target parameter. The relationship between the gas flow data and the target parameter at the same outside temperature is linearly fitted to obtain the fitting function F(G).

[0072] In another preferred embodiment of the present invention, the specific process of correcting the gas flow data in S4 is as follows:

[0073] S11, extracting gas temperature data T and pipeline pressure data N from the current IoT ultrasonic gas meter monitoring data, obtaining standard gas temperature data T'i and standard pipeline pressure data N'i corresponding to any category cluster, and calculating the similarity Xi between the current IoT ultrasonic gas meter monitoring data and any category cluster according to the calculation formula Xi = α(T-T'i)+β(N-N'i);

[0074] S12: Select the category cluster corresponding to the minimum similarity MINHi and mark it as the target category cluster. Obtain the fitting function F(T) corresponding to the target category cluster. Obtain the current outside temperature data H1 and the reference outside temperature H0. Calculate the difference ΔH between H1 and H0. Substitute ΔH into the fitting function F(T) to calculate a first correction score. Sum the current gas flow data and the first correction score to obtain the first gas flow data.

[0075] S13: Determine reference gas temperature data and reference pipeline pressure data, calculate the product of the reference gas temperature data and the reference pipeline pressure data to obtain a reference target parameter, extract gas temperature data and pipeline pressure data from the monitoring data, calculate the product of the gas temperature data and the pipeline pressure data to obtain a current target parameter, calculate the difference between the current target parameter and the reference target parameter, substitute the difference into the fitting function F(G), calculate a second correction score, sum the first gas flow data and the second correction score to obtain final gas flow data.

[0076] The gas leakage temperature compensation system based on IoT gas appliances includes:

[0077] The data acquisition module is used to set the monitoring period and obtain the monitoring data of the IoT ultrasonic gas meter in real time during the monitoring period; the monitoring data includes gas flow data, external temperature data, gas temperature data and pipeline pressure data;

[0078] The data analysis module is used to construct a two-dimensional coordinate system with the gas temperature as the horizontal coordinate and the pipeline pressure as the vertical coordinate, generate feature points corresponding to all monitoring data, select any feature point as the center, set the clustering control radius R, obtain the feature point density P within the control radius R of each feature point, and calculate the feature point density mean VagP. If there is any feature point with a feature point density P greater than VagP within the radius R, then the feature point is used as the core point and a category cluster is generated to generate several category clusters.

[0079] Select any category cluster, obtain the ambient temperature data and gas flow data corresponding to all feature points in the category cluster, construct a point map with the ambient temperature data as the horizontal coordinate and the gas flow data as the vertical coordinate, and fit the point map to obtain the fitting function F(T). The fitting function F(T) is used to fit the relationship between the gas flow data and the ambient temperature.

[0080] The result generation module is used to obtain the monitoring data of the current IoT ultrasonic gas meter, correct the gas flow data according to the fitting function, and obtain the final gas flow data.

[0081] The above is a detailed description of an embodiment of the present invention. However, the content described is only a preferred embodiment of the present invention and should not be considered to limit the scope of the present invention. All equivalent changes and improvements made within the scope of the present invention should still fall within the scope of the patent coverage of the present invention.

Claims

1. A gas leakage temperature compensation method based on IoT gas appliances, characterized in that: The following steps are involved: S1, set a monitoring period, and obtain monitoring data of the IoT ultrasonic gas meter in real time during the monitoring period; the monitoring data includes gas flow data, external temperature data, gas temperature data, and pipeline pressure data; S2, with gas temperature as the horizontal coordinate and pipeline pressure as the vertical coordinate, construct a two-dimensional coordinate system to generate feature points corresponding to all monitoring data. Select any feature point as the center, set the clustering control radius R, obtain the feature point density P within the control radius R of each feature point, and calculate the mean feature point density VagP. If there is any feature point with a feature point density P greater than VagP within the radius R, then use this feature point as the core point and generate a category cluster to generate several category clusters. S3: Select any cluster, obtain the ambient temperature data and gas flow data corresponding to all feature points in the cluster, construct a point map with the ambient temperature data as the horizontal coordinate and the gas flow data as the vertical coordinate, and fit the point map to obtain a fitting function F(T). The fitting function F(T) is used to fit the relationship between the gas flow data and the ambient temperature. S4, obtaining monitoring data of the current IoT ultrasonic gas meter, and correcting the gas flow data according to the fitting function to obtain final gas flow data; In S4, the specific process of correcting the gas flow data is as follows: S11, extract the gas temperature data T and pipeline pressure data N from the monitoring data of the current IoT ultrasonic gas meter, obtain the standard gas temperature data T'i and standard pipeline pressure data N'i corresponding to any category cluster, and calculate according to the formula Calculate the similarity Xi between the monitoring data of the current IoT ultrasonic gas meter and any category cluster; S12: Select the category cluster corresponding to the minimum similarity MINHi and mark it as the target category cluster. Obtain the fitting function F(T) corresponding to the target category cluster. Obtain the current outside temperature data H1 and the reference outside temperature H0. Calculate the difference ΔH between H1 and H0. Substitute ΔH into the fitting function F(T) to calculate a first correction score. Sum the current gas flow data and the first correction score to obtain the first gas flow data. S13: Determine reference gas temperature data and reference pipeline pressure data, calculate the product of the reference gas temperature data and the reference pipeline pressure data to obtain a reference target parameter, extract gas temperature data and pipeline pressure data from the monitoring data, calculate the product of the gas temperature data and the pipeline pressure data to obtain a current target parameter, calculate the difference between the current target parameter and the reference target parameter, substitute the difference into the fitting function F(G), calculate a second correction score, sum the first gas flow data and the second correction score to obtain final gas flow data.

2. The gas leakage temperature compensation method based on the Internet of Things gas appliance according to claim 1 is characterized in that: In S2, the specific process of setting the cluster control radius R is: Taking any feature point as the center, calculate the Euclidean distance d between the feature point and any other feature point, sum each Euclidean distance to get u, and get the control radius R based on the value u. The calculation formula is as follows: ; ; Among them, n is the number of all feature points, u is the sum of the Euclidean distances between any feature point and all other feature points, and d is the Euclidean distance between any feature points.

3. The gas leakage temperature compensation method based on the Internet of Things gas appliance according to claim 1 is characterized in that: In S2, the specific calculation process of the feature point density mean VagP is: P=a / (πR 2 ); ; Among them, a is the number of feature points within the control radius R, and n is the number of all feature points.

4. The gas leakage temperature compensation method based on IoT gas appliances according to claim 1, characterized in that: The S2 further includes merging the category cluster generated by the non-core point with the original category cluster to generate several category clusters if the density P of the non-core point within the control radius R is also greater than VagP in any category cluster.

5. The gas leakage temperature compensation method based on IoT gas appliance according to claim 1, characterized in that: Said S3 further includes: Taking any characteristic point in the cluster as the center and R as the radius, several subclusters are generated. The degree of aggregation of each subcluster is calculated and marked as DP. The subcluster with the highest DP value is selected as the representative cluster. The mean of each axis coordinate of the characteristic point corresponding to the representative cluster is calculated. The mean of the horizontal axis coordinate is calibrated to the standard gas temperature data, and the mean of the vertical axis coordinate is calibrated to the standard pipeline pressure data. The standard gas temperature data and standard pipeline pressure data of all clusters are obtained. The calculation formula of DP is: ; Among them, z is the number of feature points in any sub-cluster, z0 is the central feature point, and v0 is the other feature points in the sub-cluster.

6. The gas leakage temperature compensation method based on IoT gas appliances according to claim 1, characterized in that: In S3, the specific expression of the fitting function is: The point map is fitted using the least squares method to obtain the fitting line equation: F = k × T + b, where k represents the slope of the fitting line, T is the gas temperature, b represents the intercept of the fitting line, and k and b are constants.

7. The gas leakage temperature compensation method based on the Internet of Things gas appliance according to claim 5 is characterized in that: Also includes: The reference outside temperature is determined to be H0. The outside temperature data corresponding to the feature points in any category cluster is obtained as the feature points of H0 and marked as undetermined feature points. The product of the standard gas temperature data and the standard pipeline pressure data is calculated to obtain the target parameter. The relationship between the gas flow data and the target parameter at the same outside temperature is linearly fitted to obtain the fitting function F(G).

8. The system of the gas leakage temperature compensation method based on the Internet of Things gas appliance according to claim 1 is characterized in that: include: The data acquisition module is used to set the monitoring period and obtain the monitoring data of the IoT ultrasonic gas meter in real time during the monitoring period; the monitoring data includes gas flow data, external temperature data, gas temperature data and pipeline pressure data; The data analysis module is used to construct a two-dimensional coordinate system with the gas temperature as the horizontal coordinate and the pipeline pressure as the vertical coordinate, generate feature points corresponding to all monitoring data, select any feature point as the center, set the clustering control radius R, obtain the feature point density P within the control radius R of each feature point, and calculate the feature point density mean VagP. If there is any feature point with a feature point density P greater than VagP within the radius R, then the feature point is used as the core point and a category cluster is generated to generate several category clusters. Select any category cluster, obtain the ambient temperature data and gas flow data corresponding to all feature points in the category cluster, construct a point map with the ambient temperature data as the horizontal coordinate and the gas flow data as the vertical coordinate, and fit the point map to obtain the fitting function F(T). The fitting function F(T) is used to fit the relationship between the gas flow data and the ambient temperature. The result generation module is used to obtain the monitoring data of the current IoT ultrasonic gas meter, correct the gas flow data according to the fitting function, and obtain the final gas flow data.

Citation Information

Patent Citations

  • Ultrasonic gas meter measurement data adjustment method

    CN109696217A

  • Gas meter correction method and system, electronic equipment and medium

    CN117433615A