A high-precision piston natural gas real flow detection system and method
By constructing modules for data acquisition, analysis, decision management, and evaluation, the problems of poor accuracy and stability and blind regulation in natural gas flow detection have been solved, achieving high-precision metering and efficient regulation, reducing energy waste, and enhancing the reliability and long-term stability of the system.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- ZHEJIANG INSTITUTE OF QUALITY SCIENCES
- Filing Date
- 2026-04-28
- Publication Date
- 2026-05-29
AI Technical Summary
Existing natural gas flow detection methods suffer from poor accuracy and stability, cannot achieve accurate metering under all operating conditions, and lack a confidence assessment process. This results in a lack of basis for optimizing flow regulation schemes, which can easily lead to pipeline flow imbalance and energy waste.
The system constructs modules for data acquisition, analysis, decision management, and evaluation. It collects real-time data through sensors, calculates net flow deviation, combines interference coefficient mapping rules and sign factors to screen the optimal adjustment scheme, evaluates energy consumption and response time, and builds a confidence assessment system.
It achieves high-precision metering of natural gas flow, solves the problem of neglecting the fluctuation of methane proportion in traditional flow compensation, improves the efficiency and economy of flow regulation, reduces operating energy consumption, and enhances the reliability and continuous iteration capability of the detection system.
Smart Images

Figure CN122108292A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of automated natural gas detection, and in particular to a high-precision piston-type natural gas flow detection system and method. Background Technology
[0002] As a clean and efficient energy carrier, natural gas has been increasing its share in my country's energy structure. As a crucial link in natural gas trade, pipeline scheduling, and safety management, the accuracy of flow metering is directly related to the fairness of trade and the safety of operation. However, the existing field of natural gas flow detection still has the following shortcomings: First, current natural gas flow detection suffers from poor accuracy and stability, and the sources of deviation are not adequately controlled, making it impossible to achieve accurate measurement under all operating conditions. On the one hand, the parameter compensation mechanism is imperfect, and existing detection equipment mostly performs static compensation for temperature and pressure, ignoring the impact of natural gas component fluctuations such as methane percentage on the equivalent flow rate. Furthermore, existing natural gas flow monitoring lacks a confidence assessment step after the implementation of the plan, making it impossible to quantify the deviation between the adjustment effect and the preset target, resulting in a lack of basis for problem tracing and plan optimization. In the current process, after determining and implementing the flow adjustment plan, simply comparing the flow values before and after adjustment fails to analyze energy consumption deviations, determine whether there is energy waste in the plan, assess the stability of adjustment, and make it difficult to detect problems such as equipment response delays and control logic parameter mismatches. Long-term operation can easily lead to problems such as pipeline flow imbalance.
[0003] Therefore, a high-precision piston-type natural gas flow detection system was developed. Summary of the Invention
[0004] In view of this, the present invention provides a high-precision piston-type natural gas flow detection system to solve the problems mentioned in the background art.
[0005] The objective of this invention can be achieved through the following technical solution: a high-precision piston-type natural gas flow detection system, comprising: The data acquisition module is used to set up detection points and configure sensors to collect real-time flow, pressure, temperature and methane percentage raw flow data of the pipeline within a set time window, and to clean and organize the raw data. The data analysis module is used to determine the target flow rate, calculate the direct flow rate deviation, temperature deviation, pressure deviation, and methane percentage deviation based on the preprocessed data, and obtain the net flow rate deviation through the preset mapping rules and sign factor from deviation to interference coefficient. The decision management module is used to determine the adjustment direction based on the direction of net flow deviation, match the historical adjustment scheme library, screen candidate schemes, select the optimal scheme, and execute flow control. The decision evaluation module is used to collect actual energy consumption and flow data after adjustment, calculate energy consumption deviation rate, response time deviation rate, flow accuracy deviation rate, and fluctuation standard deviation rate to obtain the scheme confidence index, eliminate schemes with confidence index below the threshold and trigger analysis signaling.
[0006] In some embodiments, determining the deviation of each parameter specifically involves: The difference between the real-time flow rate and the target flow rate is calculated as the direct deviation; the current standard operating temperature, standard operating pressure, and standard methane percentage are extracted, and the difference between the real-time temperature and the standard operating temperature is calculated as the temperature deviation; the difference between the real-time pressure and the standard operating pressure is calculated as the pressure deviation; and the difference between the real-time methane percentage and the standard methane percentage is calculated as the methane percentage deviation.
[0007] In some embodiments, the setting of the mapping rules for each deviation to the corresponding coefficient specifically includes: Define the mapping rules between temperature deviation, pressure deviation, and argon deviation and interference deviation coefficients, where the interference deviation coefficients include temperature interference deviation coefficient, pressure interference deviation coefficient, and argon interference deviation coefficient; and preset the sign factor based on the flow rate impact caused by each deviation.
[0008] In some embodiments, determining the net flow deviation specifically involves: Based on the set mapping rules, the temperature deviation, pressure deviation, and argon deviation are converted into corresponding temperature interference deviation coefficients, pressure interference deviation coefficients, and argon interference deviation coefficients, and the net flow deviation is obtained after comprehensive processing.
[0009] In some embodiments, obtaining the solution efficiency estimate specifically involves: Identify the adjustment start time stamp and adjustment stability time stamp of the candidate schemes, and calculate the difference to obtain the adjustment response time; Extract the target flow rate of the candidate scheme, collect the flow rate data per unit time after the adjustment is stable, calculate its arithmetic mean, calculate the difference between the target flow rate and the arithmetic mean and take the absolute value to obtain the flow rate accuracy deviation; Extract the arithmetic mean of the flow rate per unit time after the adjustment is stable, and use the standard deviation formula to obtain the standard deviation of the fluctuation; The efficiency estimate of the scheme is obtained by comprehensively processing the adjustment response time, flow accuracy deviation, and standard deviation of fluctuation.
[0010] In some embodiments, determining a suitable solution based on the preferred value of the candidate solutions specifically involves: Extract the historical net flow deviation and the current net flow deviation of the candidate schemes, calculate the difference between the two and take the absolute value to obtain the net flow deviation similarity; The optimal value of each candidate scheme is obtained by comprehensively processing the total energy consumption, scheme efficiency estimate, and net flow deviation similarity of each candidate scheme. Based on the optimal value, the candidate solutions are sorted from largest to smallest, and the candidate solution with the largest optimal value is selected as the appropriate solution. The adjustment steps are then executed according to the appropriate solution.
[0011] In some embodiments, the analysis of energy consumption information and flow information specifically includes: Collect energy consumption information and flow information. The energy consumption information includes the actual energy consumption of the pump and the actual energy consumption of the valve. The flow information includes the actual adjustment response time, the actual flow accuracy deviation, and the standard deviation of the actual flow fluctuation. Extract the predicted total energy consumption and the actual total energy consumption preset in the scheme. The actual total energy consumption is the sum of the actual energy consumption of the pump and the actual energy consumption of the valve. The energy consumption deviation rate is obtained by subtracting the absolute value of the predicted total energy consumption from the actual energy consumption of the pump and the actual energy consumption of the valve, and then dividing by the predicted total energy consumption. Extract the preset response time of the scheme, collect the time from the issuance of the adjustment command to the actual stabilization of the flow, and obtain the response time deviation rate by subtracting the absolute value of the preset response time from the actual response time and dividing it by the preset response time. Extract the preset flow accuracy deviation of the scheme, collect the actual average flow during the flow stabilization phase after the scheme is executed, and calculate the absolute difference between the actual flow and the target flow to obtain the actual flow accuracy deviation. The flow accuracy deviation rate is obtained by subtracting the absolute value of the preset flow accuracy deviation from the actual flow accuracy deviation and dividing by the preset flow accuracy deviation. Extract the preset standard deviation of fluctuation, collect the instantaneous flow data sequence during the stable flow phase, calculate the actual degree of fluctuation using the standard deviation formula, and obtain the fluctuation standard deviation deviation rate by subtracting the absolute value of the preset standard deviation from the actual standard deviation and dividing by the preset standard deviation.
[0012] In some embodiments, determining the scheme confidence index specifically involves: The confidence index of the scheme is obtained by comprehensively processing the energy consumption deviation rate, response time deviation rate, flow accuracy deviation rate, and fluctuation standard deviation rate. Set a confidence index threshold for the scheme, calculate the confidence index of the adjustment results after application, compare it with the confidence index threshold, eliminate schemes that are lower than the confidence index threshold and trigger analysis signaling; Identify and decompose the scheme confidence index corresponding to the low confidence scheme, and set thresholds for energy consumption deviation rate, response time deviation rate, flow accuracy deviation rate, and fluctuation standard deviation rate respectively. Compare each deviation rate with the threshold and perform corresponding steps based on the comparison results.
[0013] A high-precision piston-type natural gas flow detection method includes: Data acquisition: Deploy detection points and configure sensors to collect real-time flow, pressure, temperature and methane percentage raw flow data of the pipeline within a set time window, and clean and organize the raw data. Data analysis: Determine the target flow rate, calculate the direct flow rate deviation, temperature deviation, pressure deviation, and methane percentage deviation based on the preprocessed data, and obtain the net flow rate deviation through the preset mapping rules and sign factor from deviation to interference coefficient; Decision management: Used to determine the adjustment direction based on the direction of net flow deviation, match the historical adjustment scheme library and screen candidate schemes to select the optimal scheme for flow control; Decision evaluation: Collect actual energy consumption and flow data after adjustment, calculate energy consumption deviation rate, response time deviation rate, flow accuracy deviation rate, and fluctuation standard deviation deviation rate to obtain the scheme confidence index, eliminate schemes with confidence index below the threshold and trigger analysis signaling.
[0014] Compared with the prior art, the beneficial effects of the present invention are: (1) This invention obtains the net flow deviation by constructing a mapping rule for temperature, pressure, methane ratio deviation and interference deviation coefficient, and dynamically adjusting the correction amount by combining the sign factor. At the same time, it determines the adjustment requirements based on the direction of the net flow deviation. This solves the problem that traditional flow compensation only considers temperature and pressure, ignores the fluctuation of methane ratio and the compensation lag under dynamic operating conditions, and realizes high-precision metering of natural gas flow, providing reliable data support. (2) This invention matches the set of historical adjustment schemes by the difference between the net flow deviation and the threshold, selects the candidate schemes that are consistent with the current adjustment direction, calculates the pump and valve energy consumption of the candidate schemes, calculates the scheme efficiency estimate by combining the adjustment response time, flow accuracy deviation, and fluctuation standard deviation, calculates the optimal value by combining the net flow deviation similarity, and finally selects the scheme with the largest optimal value; it solves the problems of blind adjustment decision-making and prominent energy waste in existing detection, realizes the balance between high efficiency and economy of flow adjustment, and can reduce operating energy consumption while responding quickly to flow deviation; (3) This invention constructs a confidence assessment system for indicators such as energy consumption deviation rate and response time deviation rate, and combines a deviation decomposition and source tracing mechanism to obtain the gap between the implementation effect of the scheme and the preset target and the root cause of the problem; it solves the industry pain point that existing detection lacks confidence assessment and cannot achieve scheme optimization and problem tracing, and realizes the long-term reliability and continuous iteration capability of the detection system, which can reduce equipment failure and operational risks caused by scheme failure. Attached Figure Description
[0015] Further details, features, and advantages of this application are disclosed in the following description of exemplary embodiments in conjunction with the accompanying drawings, in which: Figure 1This is a schematic diagram of a high-precision piston-type natural gas flow detection system according to the present invention; Figure 2 This is a flowchart of a high-precision piston-type natural gas flow detection system according to the present invention. Detailed Implementation
[0016] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0017] Example 1
[0018] Please see Figure 1 As shown, a high-precision piston-type natural gas flow detection system and method includes: Data acquisition module: Based on the operating conditions of the high-precision piston-type natural gas transmission pipeline, s detection points are set up, and corresponding sensors are set at each detection point. When natural gas flows through the detection point, the sensor collects the raw data of the transmission pipeline within the set detection time window; the raw data includes real-time flow rate, pressure, methane ratio and temperature. And preprocess the raw data; Additional information regarding the sensor calibration process: Pressure sensor calibration: Using a standard pressure source, after testing the air tightness of the gas path with inert gas, the calibration point is set according to the range, and forward and reverse stroke tests are completed. The indication error is calculated. If it exceeds the allowable range, the zero point and range knobs are adjusted to correct it. After calibration, it is connected to the system, and the overall error is verified to meet the requirements through piston simulation. Flow sensor calibration: Connect the sensor to the natural gas piston standard device, calculate the indication error and repeatability error. If the accuracy requirements are not met, optimize by adjusting the internal parameters of the sensor and recalibrate until it is qualified. Temperature sensor calibration: Set temperature points covering the operating range, read the sensor values after the bath temperature stabilizes, calculate the indication error, and if the error exceeds the allowable range, correct it by adjusting the sensor calibration coefficient, and then put it back into the constant temperature bath for verification until the error meets the requirements. The preprocessing steps are as follows: Missing value imputation: For sporadic missing values caused by brief sensor disconnection, time series interpolation methods, such as linear interpolation or weighted average of three adjacent valid data, are used to imput the missing values to ensure data continuity. Piston transmission has strong continuity and high correlation between data at adjacent time points. Noise filtering: High-frequency noise is smoothed by the "exponential moving average method". The original value is replaced by the exponentially weighted average of the data within the time window. The weight decreases over time, and recent data has a higher weight, thus preserving the true trend of flow and pressure changes with piston advancement. Data alignment: unify the timestamp accuracy of each detection point (accurate to the millisecond level), eliminate time deviations caused by sensor response delays, and ensure the spatiotemporal matching of data from different detection points at the same time; Format standardization: Convert raw data into structured formats (such as JSON or CSV), unify physical quantity units (flow rate: m³ / h, pressure: MPa, temperature: ℃), to facilitate subsequent storage and analysis; Data analysis module: Combines equipment characteristics and actual application scenarios to determine the target flow rate, extracts real-time flow rate, pressure, methane ratio and temperature at each detection point, and determines the net flow rate deviation after comprehensive analysis based on the target flow rate; Specifically; The difference between real-time traffic and target traffic is calculated as the direct deviation. If the direct deviation is negative, it indicates that the real-time flow rate is too low; if the direct deviation is positive, it indicates that the real-time flow rate is too high. Extract the current standard operating temperature, standard operating pressure, and standard methane percentage, and calculate the difference between the real-time temperature and the standard operating temperature, recording it as the temperature deviation. The pressure deviation is obtained by calculating the difference between the real-time pressure and the standard working pressure. The difference between the real-time methane percentage and the standard methane percentage is recorded as the methane percentage deviation. ; Additional notes: Regarding temperature deviation, if the temperature deviation is greater than 0, it means that the real-time temperature is higher than the standard temperature, which may result in a lower flow rate; if the temperature deviation is less than 0, it means that the real-time temperature is lower than the standard temperature, which may result in a higher flow rate. Regarding pressure deviation, an increase in pressure will cause natural gas to be compressed, resulting in an increase in the amount of substance in the same volume and a possible increase in flow rate. Conversely, a decrease in pressure will cause the gas to expand and a possible decrease in flow rate. Regarding the methane percentage deviation, changes in the methane percentage directly affect the effective composition or equivalent flow rate of the fluid. When the actual methane percentage is higher than the standard percentage, the effective contribution of the flow rate will be larger; when the real-time methane percentage is lower than the standard percentage, the effective contribution of the flow rate will be smaller. Set mapping rules for temperature deviation, pressure deviation, and acetic acid deviation with interference deviation coefficients, where interference deviation coefficients include temperature interference deviation coefficient, pressure interference deviation coefficient, and acetic acid interference deviation coefficient; based on the flow rate impact caused by each deviation, preset sign factors are used: if it leads to excessive flow rate, s=-1; if it leads to insufficient flow rate, s=+1. Construct temperature deviation intervals corresponding to each temperature deviation, and each temperature deviation interval corresponds to a temperature interference deviation coefficient. If the temperature deviation is negative, the matched temperature interference deviation coefficient is negative, resulting in excessive flow. If the temperature deviation is positive, the matched temperature interference deviation coefficient is positive, resulting in insufficient flow. For example, when the real-time temperature is 15℃, the temperature deviation ΔT = 15 - 20 = -5℃ (negative deviation). Because the real-time temperature is lower than the standard, the natural gas contracts, resulting in a higher measured flow rate (e.g., 104 m³ / h) when converted to standard operating conditions. This higher flow rate leads to a sign factor s = -1, and a negative temperature interference deviation coefficient (e.g., Kt = -0.8 m³ / (h・℃)) is applied. This is corrected by... ×Kt×ΔT=(-1)×(-0.8)×(-5)=-4m³ / h, and the final corrected flow rate is 104+(-4)=100m³ / h; Construct pressure deviation intervals corresponding to each pressure deviation, and each pressure deviation interval corresponds to a pressure interference deviation coefficient. If the pressure deviation is negative, the matched pressure interference deviation coefficient is negative, resulting in less flow. If the pressure deviation is positive, the matched pressure interference deviation coefficient is positive, resulting in more flow. For example, when the real-time pressure is 120 kPa, the pressure deviation =120-101.325=18.675. Because the real-time pressure is higher than the standard, the natural gas is compressed, resulting in a higher measured flow rate (e.g., 104 m³ / h) converted to standard operating conditions. The higher flow rate results in a matching sign factor of s=-1. In this case, the matching pressure interference coefficient is (e.g., kp=0.3 m³ / (h・Kpa)). This is corrected by... ×kp×ΔP=(-1)×(0.3)×(18.675)=-5.6m³ / h, and the final corrected flow rate is 104+(-5.6)=98.4m³ / h; Construct each set of A-occupancy deviation intervals corresponding to the A-occupancy deviation, and each set of A-occupancy deviation intervals corresponds to an A-occupancy interference deviation coefficient. If the A-occupancy deviation is negative, the matched A-occupancy interference deviation coefficient is negative, resulting in less traffic. If the A-occupancy deviation is positive, the matched A-occupancy interference deviation coefficient is positive, resulting in more traffic. For example, when the real-time methane content is 95%, the methane content deviation is... =95%-92%=3%, because the high proportion of methane causes the equivalent flow rate to be too large (e.g., 104 m³ / h). The matching sign factor for this larger flow rate is s=-1, and the matching methane percentage interference deviation coefficient is Kc=1m³ / (h・%). This is corrected by... ×KC× =(-1)×(1)×(3)=-3m³ / h, and the final corrected flow rate is 104+(-3)=101m³ / h; Based on the established mapping rules, temperature deviation, pressure deviation, and α-interference deviation are converted into corresponding temperature interference deviation coefficients, pressure interference deviation coefficients, and α-interference deviation coefficients, which are respectively labeled as follows: , , ; Using formula The net flow deviation Net is obtained after calculation; , , These are temperature deviation, pressure deviation, and methylation deviation, respectively. , , These are the sign factors corresponding to temperature deviation, pressure deviation, and α-axis deviation, respectively. For example, assuming the direct flow deviation is +2 m³ / h, the temperature deviation is -3℃ (the real-time temperature is lower than the standard temperature, and the low temperature causes natural gas to contract, resulting in a higher flow rate, so the matching sign factor is -1), the pressure deviation is -5 kPa (the real-time pressure is lower than the standard pressure, and the low pressure causes natural gas to expand, resulting in a lower flow rate, so the matching sign factor is +1), and the methane percentage deviation is 1% (the real-time methane percentage is higher than the standard percentage, resulting in a higher equivalent flow rate, so the matching sign factor is -1), the interference deviation coefficients are -0.8 m³ / (h・℃), 0.3 m³ / (h・Kpa), and 1 m³ / (h・%), respectively. Substituting these values into the formula, the net flow deviation Net = 2 + (-2.4) + (-1.5) + (-1) = -2.9 m³ / h; Decision Management Module: Based on the direction of net flow deviation, if Net is positive, the adjustment direction is negative; if Net is negative, the adjustment direction is positive. The deviation difference is calculated based on the difference between the net flow deviation and the set deviation threshold. Three sets of difference ranges are preset, and each of the three sets of difference ranges corresponds to a set of historical flow adjustment schemes. The deviation difference is matched with the deviation difference range to obtain the corresponding set of historical flow adjustment schemes. The set of historical flow adjustment schemes that are consistent with the current adjustment direction is selected as the candidate schemes. After comprehensive analysis of energy consumption, adjustment efficiency, and similarity of net flow deviation, the optimal value of each candidate scheme is obtained. The scheme with the largest optimal value is selected as the appropriate scheme execution step. Additional information includes the historical flow regulation scheme, which includes regulation methods (pump only, valve only, pump + valve combination), and specific operating parameters (pump speed change). n, change in valve opening α), and constraints (including pump safe speed, pump power limit and valve safe opening), as well as preset performance and energy consumption target parameters, such as preset pump speed adjustment range, valve opening adjustment threshold, and corresponding preset adjustment response time, flow accuracy deviation limit, total energy consumption control target, etc. Specifically: Identify the energy consumption information, efficiency information, and net flow deviation of each candidate scheme. The energy consumption information includes the actual pump speed, actual valve opening, and actual valve pressure drop; the efficiency information includes the adjustment response time, flow accuracy deviation, and standard deviation of fluctuation. Based on the similarity law of pumps, the baseline energy consumption of the pump at the baseline speed is extracted and labeled as follows: , Identify the actual pump speed n using the formula Obtain pump energy consumption ; For example, the pump's reference speed =1000rpm, baseline energy consumption =50kWh, pump actual speed n=1200rpm, first calculate the speed ratio. =1200 / 1000=1.2, substituting into the formula, we get... =50 × 1.2³ = 86.4 kWh; Based on the principle of fluid throttling loss, the valve energy consumption formula is constructed as follows: in denoted by throttling coefficients corresponding to the current and target valve openings, z being the current natural gas density, s being the natural gas velocity in the pipeline, and x being the pipeline cross-sectional area. Additional notes: The throttling coefficient is unitless; the smaller the opening, the larger the throttling coefficient. It is obtained from the opening-throttling coefficient comparison table provided by the valve manufacturer. For example, when the actual throttling coefficient of the valve is 2, the target throttling coefficient is 3, the density of natural gas is 1.2 kg / m³, the flow velocity is 2 m / s, and the cross-sectional area of the pipeline is 0.00758 m², then the valve loss = =0.0377kw; Substitute the pump energy consumption and valve energy consumption in the scheme into the formula. The total energy consumption of the solution is obtained. ; Identify the adjustment start timestamp and adjustment stabilization timestamp of the candidate schemes, and calculate the difference to obtain the adjustment response time. ; Extract the target flow rate of the candidate scheme, collect flow rate data per unit time (e.g., once every minute for ten consecutive minutes) after the adjustment is stable, calculate its arithmetic mean, calculate the difference between the target flow rate and the arithmetic mean and take the absolute value to obtain the flow rate accuracy deviation. ; Extract the arithmetic mean of the flow rate per unit time after adjustment and stabilization, and use the standard deviation formula to obtain the standard deviation of the fluctuation. ; After normalizing the adjustment response time, flow accuracy deviation, and standard deviation of fluctuation, the values are then entered into the formula. The efficiency estimate of the solution is obtained; where c1, c2, and c3 are the preset weighting factors corresponding to the adjustment response time, flow accuracy deviation, and standard deviation of fluctuation, respectively. For example, a candidate flow regulation scheme: The adjustment response time is set to start at minute 0 and stabilize at minute 5; therefore, the adjustment response time is... =5; The flow rate accuracy deviation was 100 m³ / h. After stabilization, flow rate data was collected every minute for 10 consecutive minutes, and the arithmetic mean was calculated to be 99.6 m³ / h. The flow rate accuracy deviation was... =|100-99.6|=0.4m³ / h; Based on the above traffic data, the standard deviation of fluctuation is calculated to be: ≈1.02; Normalize the adjustment response time, flow accuracy deviation, and standard deviation of fluctuation, assuming the normalized values are 0.5, 0.4, and 0.51 respectively, and the weighting factors c1=0.3, c2=0.4, and c3=0.3, substituting them into the formula, we get Ecy=(0.5×0.3)+(0.4×0.4)+(1.02×0.3)=0.616; In addition, the scheme efficiency estimate reflects the efficiency performance of the selected flow regulation scheme in terms of regulation response speed, flow accuracy and operational fluctuation stability. The smaller the value, the faster, more accurate and stable the scheme can achieve the flow regulation target, and the higher the efficiency. Extract the historical net flow deviation and the current net flow deviation of the candidate schemes, calculate the difference between the two and take the absolute value to obtain the net flow deviation similarity. ; After normalizing and positively transforming the estimated total energy consumption, efficiency, and net flow deviation of each candidate scheme, the formula is used. The optimal value Per for the corresponding candidate solutions is obtained; where , , These are the preset weighting factors corresponding to the total energy consumption of the scheme, the estimated efficiency of the scheme, and the similarity of the net flow deviation; In addition, the preferred value can quantify the energy economy, regulation efficiency and quality, and matching degree with historical solutions of the candidate flow regulation scheme. The larger the value, the better the scheme can balance economy, regulation effect and matching degree with actual needs, the more significant the advantages, and the more in line with the optimal decision in the flow regulation scenario. Based on the optimization value, the candidate solutions are sorted from largest to smallest, and the candidate solution with the largest optimization value is selected as the appropriate solution. The steps are then executed according to the adjustment method in the appropriate solution. Decision evaluation module: After selecting a suitable scheme as the adjustment scheme, the module collects the adjusted flow and energy consumption information, performs comprehensive processing to obtain the scheme confidence index, eliminates schemes with confidence indices below the threshold, and triggers analysis signaling. Specifically: Collect energy consumption information and flow information. The energy consumption information includes the actual energy consumption of the pump and the actual energy consumption of the valve. The flow information includes the actual adjustment response time, the actual flow accuracy deviation, and the standard deviation of the actual flow fluctuation. Extract the predicted total energy consumption preset in the scheme. Substitute the actual total energy consumption into the formula. Obtain the energy consumption deviation rate ,in , These are the actual energy consumption of the pump and the actual energy consumption of the valve, respectively. For example, a certain regulation scheme has a preset predicted total energy consumption of 100 kWh, while the actual energy consumption of the pump during operation is 60 kWh and the actual energy consumption of the valve is 35 kWh. Substituting these values into the formula... =5%; To elaborate further, the energy consumption deviation rate can quantify the degree of difference between actual energy consumption and predicted energy consumption, providing a quantitative basis for optimizing energy management and reducing operating costs. If it is too low, the actual energy consumption will be much lower than the predicted energy consumption. If it is too high, the actual energy consumption will be much higher than the predicted energy consumption, the energy consumption control strategy will fail, resulting in energy waste and a sharp increase in operating costs. Extraction scheme preset response time The time from the issuance of the adjustment command to the actual stabilization of the flow rate in the data acquisition scheme. Using the formula Receive response time deviation rate ; For example, a flow regulation scheme has a preset response time of 5 minutes, but the actual time from the issuance of the regulation command to the flow stabilization is 6 minutes. Substituting these values into the formula yields... =20%; In addition, the response time deviation rate can reflect the matching degree between the "actual adjustment speed" and the "predicted adjustment speed". If the deviation rate is small (e.g., <5%), it means that the adjustment speed meets expectations; if the deviation rate is large (e.g., >20%), it may be caused by problems such as equipment response delay or mismatch of control logic parameters. Extraction scheme preset flow accuracy deviation The actual flow accuracy deviation is obtained by comparing the absolute difference between the actual average flow during the stable flow phase after the implementation of the plan and the calculated target flow. Using the formula Receive flow accuracy deviation rate ; For example, a flow regulation scheme has a preset flow accuracy deviation of 2 m³ / h. After the scheme is implemented, the actual average flow rate during the stable flow phase is collected, and the absolute difference between this and the target flow rate is calculated, resulting in an actual flow accuracy deviation of 3 m³ / h. Substituting this into the formula yields... =50%; To elaborate further, the accuracy deviation rate reflects the matching degree between the "actual flow accuracy" and the "predicted flow accuracy." A small deviation rate indicates that the accuracy control of the flow regulation meets the requirements; a large deviation rate may be caused by valve leakage, insufficient sensor accuracy, fluid pressure fluctuations, etc. Extraction scheme preset fluctuation standard deviation Collect instantaneous flow data sequences during the stable flow phase and calculate the actual fluctuation level using the standard deviation formula. Using the formula Obtain the standard deviation of the fluctuation rate ; For example, a flow regulation scheme has a preset fluctuation standard deviation of 0.5 m³ / h. Instantaneous flow data sequences are collected during the stable flow phase. Using the standard deviation formula, the actual fluctuation standard deviation is calculated to be 0.78 m³ / h. Substituting this into the formula yields... =56%; To elaborate further, the standard deviation of fluctuation can reflect the matching degree between "actual flow stability" and "predicted flow stability". A small deviation rate indicates that the flow fluctuation is within the expected range and the process is less affected by external interference; a large deviation rate may be caused by pipeline vibration, natural gas composition fluctuation, equipment impeller wear, etc. After normalizing the energy consumption deviation rate, response time deviation rate, flow accuracy deviation rate, and fluctuation standard deviation rate, they were substituted into the formula. The confidence index Plcce of the proposed solution was obtained; where , , , These are the preset weighting factors corresponding to energy consumption deviation rate, response time deviation rate, flow accuracy deviation rate, and fluctuation standard deviation rate, respectively. For example, a certain flow regulation scheme has an energy consumption deviation rate of 5%, a response time deviation rate of 4%, and a flow accuracy deviation of 6%. The standard deviation of fluctuation is 3%, and the weighting factors are preset as k1=0.3, K2=0.2, K3=0.3, K4=0.2; substituting into the formula plce=(1-0.05)×0.3+(1-0.04)×0.2+(1-0.06)×0.3+(1-0.03)×0.2=0.953; To clarify, the closer the confidence index is to 1, the higher the actual performance in terms of energy consumption, response speed, flow accuracy, and fluctuation stability matches the prediction. The stronger the confidence of the solution, the more it deviates from 1, the better. Based on the business scenario, set the confidence index threshold for the solution, calculate the confidence index of the adjustment results after application, compare it with the confidence index threshold, eliminate solutions that are lower than the confidence index threshold, and trigger analysis signaling. Identify and decompose the scheme confidence index corresponding to the low confidence scheme, and set thresholds for energy consumption deviation rate, response time deviation rate, flow accuracy deviation rate, and fluctuation standard deviation rate respectively. Compare each deviation rate with the threshold and execute the corresponding steps based on the comparison results. For example, if the energy consumption deviation rate is higher than the threshold, the pump and valve operating parameters need to be checked, and the energy consumption deviation can be reduced through equipment maintenance or the introduction of interference compensation. If the response time deviation rate is higher than the threshold, the control logic parameters, the responsiveness of the device's actuators, and the sensor sampling frequency need to be checked. The adjustment response time can be shortened by optimizing the control parameters, upgrading the actuators, or increasing the sampling frequency. If the flow accuracy deviation rate is higher than the threshold, it is necessary to focus on valve adjustment accuracy, sensor measurement accuracy and fluid pressure stability, and improve flow accuracy control capability through valve core maintenance, sensor calibration, and the installation of pressure stabilizing devices. If the standard deviation rate of fluctuation is higher than the threshold, it is necessary to investigate pipeline equipment vibration, natural gas composition fluctuation, and control anti-interference capability. The degree of flow fluctuation can be reduced by equipment vibration reduction, composition monitoring compensation, and optimization of anti-interference control logic. The above formulas are all dimensionless calculations. Dimensionless calculations can be performed using various methods such as standardization, which will not be elaborated here. The formulas are derived from software simulations based on a large amount of collected data, and the preset parameters in the formulas can be set by those skilled in the art according to the actual situation.
[0019] Example 2
[0020] Please see Figure 2 As shown, based on Embodiment 1 of this application, a high-precision piston-type natural gas flow detection system is provided. Embodiment 2 of this application proposes a high-precision piston-type natural gas flow detection method. Embodiment 2 is merely a preferred embodiment of Embodiment 1, and its implementation will not affect the individual implementation of Embodiment 1.
[0021] Specifically, the difference in the high-precision piston-type natural gas flow detection method provided in Embodiment 2 of this application lies in that it includes: Data acquisition: Corresponding sensors are deployed at each detection point to collect raw data of the transmission pipeline within the set detection time window; the raw data includes real-time flow rate, pressure, methane percentage and temperature, and the raw data is preprocessed. Data analysis: After determining the target flow rate, extract the real-time flow rate, pressure, methane percentage and temperature of each detection point, and conduct a comprehensive analysis based on the target flow rate to determine the net flow rate deviation; Decision Management: Calculate the difference between the net flow deviation and the set deviation threshold as the deviation difference value. Preset three sets of difference value ranges corresponding to the deviation difference value. Each set of difference value ranges corresponds to a set of historical flow adjustment schemes. Match the deviation difference value with the difference value range to obtain the corresponding set of historical flow adjustment schemes. A set of historical flow regulation schemes that are consistent with the current regulation direction is selected as candidate schemes. A comprehensive analysis is conducted on energy consumption, regulation efficiency, and similarity of net flow deviation to obtain the optimal value of each candidate scheme. The scheme with the largest optimal value is selected as the appropriate scheme to be implemented. Based on the direction of the net flow deviation, if the net flow deviation is positive, it indicates that the adjustment direction is negative; if the net flow deviation is negative, it indicates that the adjustment direction is positive. Decision evaluation: After selecting a suitable scheme as the adjustment scheme, the adjusted flow and energy consumption information are collected and processed to obtain the scheme confidence index. Schemes with confidence indices below the threshold are eliminated and analysis signaling is triggered.
[0022] The above embodiments can be implemented, in whole or in part, by software, hardware, firmware, or any other combination thereof. When implemented using software, the above embodiments can be implemented, in whole or in part, as a computer program product. The computer program product includes one or more computer instructions or computer programs. When the computer instructions or computer programs are loaded or executed on a computer, all or part of the processes or functions described in the embodiments of this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, the computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wired or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more sets of available media. The available medium can be a magnetic medium (e.g., floppy disk, ATA hard disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium. The semiconductor medium can be a solid-state ATA hard disk.
[0023] It should be understood that in the various embodiments of this application, the order of the above-mentioned processes does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.
[0024] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0025] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.
[0026] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment, depending on actual needs.
[0027] In addition, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
[0028] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable ATA hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0029] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A high-precision piston-type natural gas flow detection system, characterized in that, include: The data acquisition module is used to set up detection points and configure sensors to collect real-time flow, pressure, temperature and methane percentage raw flow data of the pipeline within a set time window, and to clean and organize the raw data. The data analysis module is used to determine the target flow rate, calculate the direct flow rate deviation, temperature deviation, pressure deviation, and methane percentage deviation based on the preprocessed data, and obtain the net flow rate deviation through the preset mapping rules and sign factor from deviation to interference coefficient. The decision management module is used to determine the adjustment direction based on the direction of net flow deviation, match the historical adjustment scheme library, screen candidate schemes, select the optimal scheme, and execute flow control. The decision evaluation module is used to collect actual energy consumption and flow data after adjustment, calculate energy consumption deviation rate, response time deviation rate, flow accuracy deviation rate, and fluctuation standard deviation rate to obtain the scheme confidence index, eliminate schemes with confidence index below the threshold and trigger analysis signaling.
2. The high-precision piston-type natural gas flow detection system according to claim 1, characterized in that, The determination of the deviation of each parameter includes: The difference between the real-time flow rate and the target flow rate is calculated as the direct deviation; the current standard operating temperature, standard operating pressure, and standard methane percentage are extracted, and the difference between the real-time temperature and the standard operating temperature is calculated as the temperature deviation; the difference between the real-time pressure and the standard operating pressure is calculated as the pressure deviation; and the difference between the real-time methane percentage and the standard methane percentage is calculated as the methane percentage deviation.
3. The high-precision piston-type natural gas flow detection system according to claim 1, characterized in that, The mapping rules for setting each deviation to the corresponding coefficient include: Define the mapping rules between temperature deviation, pressure deviation, and argon deviation and interference deviation coefficients, where the interference deviation coefficients include temperature interference deviation coefficient, pressure interference deviation coefficient, and argon interference deviation coefficient; and preset the sign factor based on the flow rate impact caused by each deviation.
4. The high-precision piston-type natural gas flow detection system according to claim 1, characterized in that, The determination of net flow deviation includes: Based on the set mapping rules, the temperature deviation, pressure deviation, and argon deviation are converted into corresponding temperature interference deviation coefficients, pressure interference deviation coefficients, and argon interference deviation coefficients, and the net flow deviation is obtained after comprehensive processing.
5. The high-precision piston-type natural gas flow detection system according to claim 1, characterized in that, The obtained efficiency estimate of the solution includes: Identify the adjustment start time stamp and adjustment stability time stamp of the candidate schemes, and calculate the difference to obtain the adjustment response time; Extract the target flow rate of the candidate scheme, collect the flow rate data per unit time after the adjustment is stable, calculate its arithmetic mean, calculate the difference between the target flow rate and the arithmetic mean and take the absolute value to obtain the flow rate accuracy deviation; Extract the arithmetic mean of the flow rate per unit time after the adjustment is stable, and use the standard deviation formula to obtain the standard deviation of the fluctuation; The efficiency estimate of the scheme is obtained by comprehensively processing the adjustment response time, flow accuracy deviation, and standard deviation of fluctuation.
6. The high-precision piston-type natural gas flow detection system according to claim 1, characterized in that, The process of determining a suitable solution based on the preferred value of the candidate solutions includes: Extract the historical net flow deviation and the current net flow deviation of the candidate schemes, calculate the difference between the two and take the absolute value to obtain the net flow deviation similarity; The optimal value of each candidate scheme is obtained by comprehensively processing the total energy consumption, scheme efficiency estimate, and net flow deviation similarity of each candidate scheme. Based on the optimal value, the candidate solutions are sorted from largest to smallest, and the candidate solution with the largest optimal value is selected as the appropriate solution. The adjustment steps are then executed according to the appropriate solution.
7. The high-precision piston-type natural gas flow detection system according to claim 1, characterized in that, The analysis of energy consumption and flow information includes: Collect energy consumption information and flow information. The energy consumption information includes the actual energy consumption of the pump and the actual energy consumption of the valve. The flow information includes the actual adjustment response time, the actual flow accuracy deviation, and the standard deviation of the actual flow fluctuation. Extract the predicted total energy consumption and the actual total energy consumption preset in the scheme. The actual total energy consumption is the sum of the actual energy consumption of the pump and the actual energy consumption of the valve. The energy consumption deviation rate is obtained by subtracting the absolute value of the predicted total energy consumption from the actual energy consumption of the pump and the actual energy consumption of the valve, and then dividing by the predicted total energy consumption. Extract the preset response time of the scheme, collect the time from the issuance of the adjustment command to the actual stabilization of the flow, and obtain the response time deviation rate by subtracting the absolute value of the preset response time from the actual response time and dividing it by the preset response time. Extract the preset flow accuracy deviation of the scheme, collect the actual average flow during the flow stabilization phase after the scheme is executed, and calculate the absolute difference between the actual flow and the target flow to obtain the actual flow accuracy deviation. The flow accuracy deviation rate is obtained by subtracting the absolute value of the preset flow accuracy deviation from the actual flow accuracy deviation and dividing by the preset flow accuracy deviation. Extract the preset standard deviation of fluctuation, collect the instantaneous flow data sequence during the stable flow phase, calculate the actual degree of fluctuation using the standard deviation formula, and obtain the fluctuation standard deviation deviation rate by subtracting the absolute value of the preset standard deviation from the actual standard deviation and dividing by the preset standard deviation.
8. The high-precision piston-type natural gas flow detection system according to claim 1, characterized in that, The confidence index for determining the scheme includes: The confidence index of the scheme is obtained by comprehensively processing the energy consumption deviation rate, response time deviation rate, flow accuracy deviation rate, and fluctuation standard deviation rate. Set a confidence index threshold for the scheme, calculate the confidence index of the adjustment results after application, compare it with the confidence index threshold, eliminate schemes that are lower than the confidence index threshold and trigger analysis signaling; Identify and decompose the scheme confidence index corresponding to the low confidence scheme, and set thresholds for energy consumption deviation rate, response time deviation rate, flow accuracy deviation rate, and fluctuation standard deviation rate respectively. Compare each deviation rate with the threshold and perform corresponding steps based on the comparison results.
9. A high-precision piston-type natural gas flow detection method, applied to the high-precision piston-type natural gas flow detection system proposed in any one of claims 1-8, comprising: Data acquisition: Deploy detection points and configure sensors to collect real-time flow, pressure, temperature and methane percentage raw flow data of the pipeline within a set time window, and clean and organize the raw data. Data analysis: Determine the target flow rate, calculate the direct flow rate deviation, temperature deviation, pressure deviation, and methane percentage deviation based on the preprocessed data, and obtain the net flow rate deviation through the preset mapping rules and sign factor from deviation to interference coefficient; Decision management: Used to determine the adjustment direction based on the direction of net flow deviation, match the historical adjustment scheme library and screen candidate schemes to select the optimal scheme for flow control; Decision evaluation: Collect actual energy consumption and flow data after adjustment, calculate energy consumption deviation rate, response time deviation rate, flow accuracy deviation rate, and fluctuation standard deviation deviation rate to obtain the scheme confidence index, eliminate schemes with confidence index below the threshold and trigger analysis signaling.