Security and protection type intelligent diaphragm gas meter

Through the combination of flow monitoring module, pressure ladder module, spectrum shift module, absorption judgment module and joint control module, air backflow and multi-point leakage in the process of gas meter valve closing are dynamically identified and controlled, which solves the hidden dangers of traditional gas meters when the valve is closed quickly, realizes accurate judgment of fluid transient effects and active risk control, and improves the safety of gas meters.

CN120845694AActive Publication Date: 2025-10-28FATO GAS EQUIP (HEBEI) LTD
View PDF 10 Cites 0 Cited by

Patent Information

Application Number
CN202511349204.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-09-22
Publication Date
2025-10-28
Estimated Expiration
2045-09-22

AI Technical Summary

Technical Problem

Existing security gas meters are unable to effectively identify and respond to air backdrafts and coordinated backdrafts from multiple leaks caused by fluid dynamics during rapid valve closing operations, creating hidden combustible gas risks. Traditional sensors are unable to directly detect such hidden dangers.

Method used

The system employs a flow monitoring module to monitor flow rate in real time, a pressure gradient module to generate a pressure gradient vector, a spectrum shift module to analyze pressure values ​​through Hilbert-Huang transform, a backflow detection module to determine the risk of backflow, a leak detection module to identify multiple leak points, and a control module to switch between two-stage valve shut-off modes and trigger linkage ventilation commands. It dynamically senses transient fluid effects to achieve real-time detection and risk control of backflow and multi-point leaks.

Benefits of technology

It accurately captures the characteristics of gas composition changes, identifies air backflow and multi-point leakage induced by valve closure, and actively dilutes residual gas in the pipeline through a two-stage valve closure mode, significantly improving the safety level of the closed pipeline system and preventing the generation of combustible gas mixtures.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120845694A_ABST
    Figure CN120845694A_ABST
Patent Text Reader

Abstract

The invention discloses a security and protection type intelligent diaphragm gas meter, particularly relates to the technical field of safety protection of gas meters, and is used for solving the problem that combustible mixed gas is formed due to air suck-back caused by negative pressure when a valve of an existing gas meter is rapidly closed and cannot be detected. The flow monitoring module monitors the flow in real time and triggers valve closing; the pressure gradient module collects multi-position pressure values in the valve closing process to generate a pressure gradient vector; the spectrum shift module analyzes the pressure value through Hilbert-Huang transform to extract marginal spectrum energy gravity center offset; the suction judging module judges the air suck-back risk based on the included angle between the pressure gradient direction angle and the leakage signal maximum intensity direction and the spectrum offset; the leakage analysis module calculates local curvature distribution before pressure wave propagation through the pressure oscillation waveform, and recognizes a plurality of discrete curvature maximum value points to judge multi-leakage-point collaborative suck-back; and the joint control module switches a two-stage valve closing mode according to the risk judgment result and triggers a linkage ventilation instruction, so that the hidden danger of combustible mixed gas in the pipeline is eliminated.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of gas meter safety protection technology, and in particular to a security-type intelligent diaphragm gas meter. Background Art

[0002] Existing security-type gas meters are generally equipped with automatic valve shut-off function. When a gas leak or abnormal flow is detected, the gas source is quickly cut off to achieve risk control. The valve response mechanism is usually designed according to international standards, with a focus on optimizing valve shut-off speed and sealing performance to ensure that gas output is blocked in the shortest possible time. In the industry's technical understanding, valve shut-off action is regarded as the terminal measure of safety protection, and its design principles focus on improving shut-off efficiency and reliability.

[0003] However, existing technologies overlook the fluid dynamics effects caused by valve closure: during the rapid cut-off of the gas source, the sudden cessation of gas flow in the downstream pipeline can lead to a sudden change in local pressure, which may cause a significant negative pressure to form in the pipeline. This can cause external air to be drawn back into the closed pipeline network through the leak point. The mixture of air and residual gas will form a flammable gas, and this mixture is distributed inside the pipeline. Traditional leak sensors installed at the meter cannot directly detect such hidden risks. There is a lack of effective response mechanisms to new safety hazards induced by the transient fluid process after valve closure, forming a break in the protection chain. Summary of the Invention

[0004] This invention addresses the technical problems existing in the prior art by providing a security-type intelligent diaphragm gas meter.

[0005] The technical solution of the present invention to solve the above-mentioned technical problems is as follows: This invention provides the following technical solution: A security-type smart diaphragm gas meter includes: The flow monitoring module is used to monitor the gas flow rate in real time. When the gas flow rate exceeds the preset leakage threshold, it generates a valve closing signal. The pressure gradient module is used to initiate valve closing operation in response to valve closing action signals. During the valve closing operation, it collects pressure values ​​at different locations in the pipeline and generates a pressure gradient vector based on the spatial distribution of the pressure values; it also simultaneously acquires leakage detection signals. The spectral shift module is used to analyze pressure values ​​through Hilbert-Huang transform and extract the centroid shift of marginal spectral energy. The backflow detection module is used to determine the risk of air backflow when the angle between the direction angle of the pressure gradient vector and the maximum intensity direction of the leak detection signal is less than the critical angle and the centroid offset of the marginal spectrum energy is greater than the frequency shift threshold. The leak detection module is used to calculate the local curvature distribution of the pressure wave propagation wavefront through the oscillation waveform of the pressure value. When there are at least two discrete maximum points in the local curvature distribution, it is determined that multiple leak points are co-currently drawing back. The joint control module is used to switch the valve closing action to a two-stage mode and trigger a joint ventilation command based on the judgment results of the risk of backflow of air and the coordinated backflow of multiple leak points.

[0006] Furthermore, the gas flow rate is monitored in real time, and a valve closing signal is generated when the gas flow rate exceeds a preset leakage threshold, including: The gas flow rate is obtained in real time through a diaphragm metering device; Compare the gas flow rate value with the preset leakage threshold; When the gas flow rate exceeds the preset leakage threshold, a valve shut-off signal is generated.

[0007] Furthermore, if the gas flow rate exceeds the preset leakage threshold for a preset duration, an operation to generate a valve-closing signal will be executed.

[0008] Furthermore, in response to the valve closing action signal, the valve closing operation is initiated. During the valve closing operation, pressure values ​​at different locations in the pipeline are collected, and a pressure gradient vector is generated based on the spatial distribution of the pressure values. Simultaneously, leakage detection signals are acquired, including: The valve closing action is initiated in response to the valve closing signal; During the continuous valve closing action, pressure values ​​at different locations in the pipeline are collected by pressure sensors installed at the beginning, middle and end of the pipeline. Calculate the pressure gradient vector based on the spatial distribution of pressure values ​​at the beginning, middle, and end of the pipeline; Leak detection signals are acquired synchronously through a distributed gas sensor array.

[0009] Furthermore, by analyzing the pressure values ​​using the Hilbert-Huang transform, the marginal spectral energy centroid shift is extracted, including: Empirical mode decomposition of the pressure value generates multiple intrinsic mode function components; Perform a Hilbert transform on each intrinsic mode function component to obtain the instantaneous frequency and instantaneous amplitude; Hilbert marginal spectrum is constructed based on instantaneous frequency and instantaneous amplitude; Calculate the energy centroid frequency of the Hilbert marginal spectrum; The energy centroid frequency is compared with the reference centroid frequency to obtain the marginal spectrum energy centroid offset.

[0010] Furthermore, a Hilbert transform is performed on each intrinsic mode function component to obtain the instantaneous frequency and instantaneous amplitude, including: Construct analytical signals from the intrinsic mode function components; Extract the phase angle function of the analytical signal, calculate the first derivative of the phase angle function with respect to time, and divide the value of the first derivative of the phase angle function with respect to time by twice pi to obtain the instantaneous frequency; Calculate the sum of squares of the real and imaginary parts of the analytic signal, and perform an arithmetic square root operation on the sum of squares to obtain the instantaneous amplitude.

[0011] Furthermore, when the angle between the direction angle of the pressure gradient vector and the maximum intensity orientation of the leak detection signal is less than a critical angle and the centroid shift of the marginal spectral energy is greater than the frequency shift threshold, a risk of backdraft is determined, including: Calculate the direction angle of the pressure gradient vector; Determine the location of the maximum intensity of the leak detection signal; Calculate the angle between the direction angle and the azimuth of maximum intensity; Obtain the centroid offset of the marginal spectral energy; Compare the included angle with the critical angle, and compare the marginal spectral energy centroid shift with the frequency shift threshold; When the included angle is less than the critical angle and the centroid shift of the marginal spectral energy is greater than the frequency shift threshold, an air backflow risk assessment result is generated.

[0012] Furthermore, by calculating the local curvature distribution of the pressure wave propagation front using the oscillating waveform of the pressure value, when at least two discrete maxima exist in the local curvature distribution, it is determined that multiple leakage points are co-currently drawing back, including: Obtain the oscillation waveform of pressure values ​​at different locations in the pipeline; Reconstructing the propagation process of pressure waves in the pipeline based on oscillating waveforms; Identify the morphological changes of the propagation wavefront of pressure waves; Quantify the degree of local bending of the wavefront based on morphological change characteristics; Scan the distribution of localized curvature within the spatial range of the pipeline; Mark the locations where the degree of local curvature is prominent; Analyze the spatial distribution relationship of the marked location points; When there are at least two mutually isolated marker locations, multiple leak point collaborative backflow determination results are generated.

[0013] Furthermore, based on the assessment of the risk of backdraft and the coordinated backdraft from multiple leak points, the valve closing action is switched to a two-stage mode and a linked ventilation command is triggered, including: Receive the results of the air backflow risk assessment and the results of the coordinated backflow assessment from multiple leak points; When there is a risk of backdraft, a coordinated ventilation command is generated to dilute the residual gas in the duct. When there is a risk of backflow of air and backflow from multiple leak points, the valve closing action is switched to a two-stage mode.

[0014] Furthermore, the two-stage mode is as follows: in the first stage, the valve is closed to the first opening degree at a first speed, and the first opening degree maintains the gas flow rate value below the lower explosive limit of the mixed gas; in the second stage, the valve is closed to the fully closed state at a second speed lower than the first speed.

[0015] The beneficial effects of the present invention are: 1. By dynamically sensing the transient fluid effects during valve closure, an air backflow risk identification system was constructed. Unlike traditional gas meters that rely solely on end flow and leakage sensors for monitoring, this system simultaneously collects pressure values ​​at multiple locations in the pipeline during valve closure, generating a pressure gradient vector to characterize the direction of negative pressure propagation. Combined with the marginal spectrum energy centroid shift extracted by Hilbert-Huang transform, it accurately captures the characteristics of gas composition changes. Simultaneously, by utilizing the local curvature distribution analysis of the pressure wave propagation wavefront, it identifies the wavefront distortion effect caused by multiple discrete leakage points, achieving real-time determination of the air backflow risk induced by valve closure and the synergistic effect of multi-point leakage. This solves the problem of hidden flammable gases formed by external air backflow due to rapid valve closure.

[0016] 2. The valve shut-off operation is upgraded from a terminal safety measure to a dynamic risk control process. Based on the risk assessment of backdraft air, the joint control module intelligently switches between two-stage valve shut-off modes: the first stage is to reduce the valve speed and close it to maintain the gas flow rate below the lower explosive limit, blocking the path of negative pressure surge; the second stage is to trigger ventilation commands simultaneously during the low-speed closure process, actively diluting the residual gas in the pipeline, suppressing the formation conditions of combustible gas mixture from the source, transforming the traditional gas meter's "passive shutdown" into "active elimination of hidden dangers", and significantly improving the inherent safety level of the closed pipeline system. Attached Figure Description

[0017] Figure 1 This is a schematic diagram of the structure of a security-type intelligent diaphragm gas meter according to the present invention; Figure 2 This is a flowchart illustrating the collaborative backflow determination of multiple leakage points according to the present invention. Detailed Implementation

[0018] 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 creative efforts are within the scope of protection of the present invention.

[0019] Example: Figure 1 A structural schematic diagram of a security-type smart diaphragm gas meter according to the present invention is provided. The security-type smart diaphragm gas meter includes: The flow monitoring module is used to monitor the gas flow rate in real time. When the gas flow rate exceeds the preset leakage threshold, it generates a valve closing signal. The pressure gradient module is used to initiate valve closing operation in response to valve closing action signals. During the valve closing operation, it collects pressure values ​​at different locations in the pipeline and generates a pressure gradient vector based on the spatial distribution of the pressure values; it also simultaneously acquires leakage detection signals. The spectral shift module is used to analyze pressure values ​​through Hilbert-Huang transform and extract the centroid shift of marginal spectral energy. The backflow detection module is used to determine the risk of air backflow when the angle between the direction angle of the pressure gradient vector and the maximum intensity direction of the leak detection signal is less than the critical angle and the centroid offset of the marginal spectrum energy is greater than the frequency shift threshold. The leak detection module is used to calculate the local curvature distribution of the pressure wave propagation wavefront through the oscillation waveform of the pressure value. When there are at least two discrete maximum points in the local curvature distribution, it is determined that multiple leak points are co-currently drawing back. The joint control module is used to switch the valve closing action to a two-stage mode and trigger a joint ventilation command based on the judgment results of the risk of backflow of air and the coordinated backflow of multiple leak points.

[0020] Real-time monitoring of gas flow rate; when the gas flow rate exceeds a preset leakage threshold, a valve closing signal is generated. Specifically: The diaphragm metering mechanism consists of a metering chamber, a flexible diaphragm, and a crank-connecting rod assembly. The metering chamber is connected to the user's gas equipment via a gas inlet pipe. The flexible diaphragm divides the metering chamber into two periodically changing volume chambers. When gas flows through the metering chamber, the flexible diaphragm reciprocates under the pressure difference, driving the crank-connecting rod assembly to convert the diaphragm displacement into rotational motion. This rotational motion is transmitted to the flow metering turntable via a transmission gear set. Each fixed angle of rotation of the flow metering turntable corresponds to a fixed volume of gas passing through. A photoelectric encoder is installed at the shaft of the flow metering turntable. The photoelectric encoder detects the number of light-transmitting grids on the turntable and outputs a real-time pulse signal sequence. The control unit receives the pulse signal sequence and calculates the current gas flow rate value using arithmetic multiplication based on the number of pulses and a calibration coefficient corresponding to the gas volume per unit pulse. The gas flow rate value is expressed in cubic meters per hour.

[0021] The preset leakage threshold is set as follows: First, the basic flow fluctuation range of the gas meter under leak-free conditions is obtained. This range is acquired by continuously monitoring typical user gas usage behavior for 30 days, including stove ignition and water heater start-stop scenarios. Twice the maximum value of the basic flow fluctuation range is taken as the leakage judgment benchmark value. The leakage judgment benchmark value is multiplied by a safety margin coefficient to obtain the preset leakage threshold. The safety margin coefficient ranges from 1.2 to 1.5, determined based on the statistical characteristics of gas pipeline pressure fluctuations. For example, for a gas meter with a capacity of 6 cubic meters per hour, the maximum basic flow fluctuation range is 0.02 cubic meters per hour, the leakage judgment benchmark value is 0.04 cubic meters per hour, and the safety margin coefficient is 1.3; therefore, the preset leakage threshold is 0.052 cubic meters per hour.

[0022] The control unit continuously compares the real-time gas flow rate with a preset leakage threshold. This comparison is achieved using a digital comparator circuit. The first input of the digital comparator circuit is connected to the output of an analog-to-digital converter (ADC), which converts the gas flow rate into a digital signal. The second input of the digital comparator circuit is connected to the output of a memory that stores the digital code of the preset leakage threshold. A high-level output from the digital comparator circuit indicates that the gas flow rate exceeds the preset leakage threshold.

[0023] When the digital comparator circuit outputs a high level, it triggers the timer to start accumulating the count. The timer uses a crystal oscillator as its clock source, with a timing accuracy of 0.1 seconds. The preset duration is determined as follows: The time required for the complete removal of residual gas from the gas pipeline is analyzed, calculated based on the quotient of the pipeline volume and the flow velocity; 0.8 times the time required for complete removal of residual gas is taken as the baseline value for the preset duration; the baseline value is adjusted according to the pipeline length, with an adjustment factor equal to the pipeline length divided by 10 meters (pipeline length ≥ 1 meter). For example, for a 5-meter-long pipeline, if the residual gas removal takes 20 seconds, the baseline value for the preset duration is 16 seconds, the adjustment factor is 0.5, and the final preset duration is 8 seconds.

[0024] When the timer accumulates to the preset duration, the control unit generates a valve-closing signal. This signal is a 12-volt DC pulse with a pulse width of 100 milliseconds. This signal is generated by converting a 5-volt logic level signal through a drive circuit. The enable terminal of the drive circuit is connected to the timer output. When the enable terminal receives a high-level signal that lasts for the specified duration, the drive circuit outputs a 12-volt pulse.

[0025] The duration determination mechanism is used to eliminate instantaneous flow interference. During the timer's accumulation process, if the gas flow value drops below the preset leakage threshold and remains below it for 0.5 seconds, the timer is immediately reset. Instantaneous flow interference scenarios include: flow spikes caused by gas pressure fluctuations during the initial ignition of the stove (duration < 2 seconds) and pipe pressure transients caused by water hammer (duration < 0.3 seconds).

[0026] The valve closing operation is initiated in response to the valve closing signal. During the valve closing operation, pressure values ​​at different locations in the pipeline are collected, and a pressure gradient vector is generated based on the spatial distribution of the pressure values. Simultaneously, a leak detection signal is acquired. Specifically, the implementation is as follows: After receiving the valve closing signal, the control unit sends a start command to the valve drive mechanism. The valve drive mechanism consists of a stepper motor, a reduction gear set, and a valve core position sensor. Upon receiving the start command, the stepper motor converts its rotational motion into linear displacement of the valve stem via the reduction gear set, pushing the valve core towards the closing direction. The valve core position sensor detects the valve core displacement in real time and feeds it back to the control unit, forming a closed-loop control. The valve closing action is defined as the entire time from the start of the valve core's movement to reaching the fully closed position. This time varies depending on the valve type; for example, for a 20mm diameter ball valve, the full stroke time is typically 3 to 5 seconds.

[0027] During the continuous valve closing process, pressure values ​​are synchronously collected by pressure sensors installed at the beginning, middle, and end of the pipeline. The beginning of the pipeline refers to the section of pipe closest to the valve, within 0.5 meters of the valve outlet; the middle refers to the section of pipe within ±10% of the midpoint of the total pipeline length; and the end refers to the section of pipe furthest from the valve, within 1 meter of the user terminal equipment. The pressure sensors use piezoresistive sensing elements with a range covering -10 kPa to +50 kPa and a sampling frequency of 100 Hz. The sensors at the three locations are synchronized using a unified clock source, achieving a synchronization accuracy of 0.1 milliseconds. During the data acquisition process, the control unit reads and stores the pressure data at 10-millisecond intervals, with the pressure value unit being kPa.

[0028] When calculating the pressure gradient vector based on the spatial distribution of pressure values ​​at the beginning, middle, and end of a pipeline, a spatial coordinate system for the pipeline is first established: with the beginning of the pipeline as the origin and the pipeline axis as the positive X-axis. The coordinates of the beginning of the pipeline are (0,0,0), the middle of the pipeline are (L / 2,0,0), and the end of the pipeline are (L,0,0), where L is the total length of the pipeline. The calculation process includes the following steps: The difference between the pressure value at the middle end and the pressure value at the beginning end is calculated as the first pressure change; the difference between the pressure value at the end end and the pressure value at the middle end is calculated as the second pressure change; the second pressure change is multiplied by the value 2; the result of the multiplication is divided by the total length L of the pipeline to obtain the component value of the pressure gradient vector in the pipeline direction; the other directional components of the pressure gradient vector are set to zero.

[0029] For example, when the pipe length L is 10 meters and the pressure at the end is 1 kPa higher than the pressure at the middle, the component of the pressure gradient vector in the pipe direction is 0.2 kPa per meter.

[0030] Synchronous acquisition of leak detection signals is achieved through a distributed gas sensor array. The gas sensor array consists of multiple gas concentration detection units distributed at equal intervals along the pipeline direction; the spacing is determined by the pipeline length, typically one detection unit every 2 meters. Each detection unit includes a methane sensor and a signal conditioning circuit. The methane sensor uses the catalytic combustion principle and has a detection range of 0 to 100% LEL. The signal conditioning circuit amplifies the millivolt-level voltage signal output by the sensor and converts it into a standard current signal of 4 mA to 20 mA. The control unit uses a multiplexer to cyclically acquire signals from each detection unit. The cyclic acquisition period is synchronized with the pressure value acquisition period and set to 10 milliseconds. The leak detection signal is defined as the spatial orientation corresponding to the largest amplitude of the output signal from each detection unit. This orientation is determined by the location number of the detection unit. For example, when the output signal amplitude of detection unit number 3 is the largest and this unit is located 6 meters from the beginning of the pipeline, the location of the maximum intensity of the leak detection signal is recorded as 6 meters along the pipeline axis.

[0031] The pressure gradient vector calculation process includes data validity verification: if any pressure value at any of the three locations exceeds the measurement range (e.g., below -10 kPa or above +50 kPa), the acquired data is invalidated and re-acquired; if the absolute value of the pressure difference between the beginning and end points is less than 0.5 kPa, it is considered an invalid gradient and a zero vector is output. During leak detection signal acquisition, if the outputs of all detection units are below the detection threshold (e.g., 2% LEL), it is considered that there is no leak signal and an empty orientation marker is output.

[0032] Spatial location calibration is achieved using pipeline mapping data. The total pipeline length L is obtained through actual measurement during installation, achieving centimeter-level accuracy. The position coordinates of each sensor are entered during control system initialization; for example, the first-end sensor is entered as (0,0,0), the middle-end sensor as (5.0,0,0), and the last-end sensor as (10.0,0,0). The gas detection unit locations are entered according to their actual installation distances, with database numbers mapping to spatial locations.

[0033] The pressure values ​​were analyzed using the Hilbert-Huang transform to extract the centroid shift of the marginal spectral energy. The specific implementation was as follows: When performing empirical mode decomposition on the pressure values ​​collected by the pressure sensor, an adaptive iterative sieving algorithm is used to process the discrete time series data. The pressure value data is stored in a circular buffer with a sampling interval of 10 milliseconds, and 1024 consecutive sampling points are taken to form the analysis window for each processing. The empirical mode decomposition process includes the following steps: First, identify local maxima and local minima in the pressure value time series. Local maxima are defined as data points greater than the two adjacent sampling points, and local minima are defined as data points less than the two adjacent sampling points. Connect all local maxima using cubic spline interpolation to form an upper envelope, and connect all local minima to form a lower envelope. Calculate the arithmetic mean of the upper and lower envelopes at each sampling point to obtain the average envelope. Subtract the average envelope from the original pressure value series to obtain the intermediate component. Repeat the above process until the intermediate component satisfies the two criteria of the intrinsic mode function: 1) the number of zero-crossing points differs from the number of extreme points by no more than one across the entire data range; 2) the difference between the mean of the upper and lower envelopes and zero is less than 0.01 kPa at any given time. When the conditions are met, output the intrinsic mode function component. Subtract this component from the original series and continue decomposing the remaining series until the remaining series is a monotonic function. For example, after decomposing a segment of pressure fluctuation data containing 1024 sampling points, three intrinsic mode function components and one residual component may be obtained. The decomposition process typically involves 5 to 10 iterations.

[0034] When performing a Hilbert transform on each intrinsic mode function component, the following operations are implemented in the digital signal processor: The discrete data point sequence of the intrinsic mode function component is read, and a Fast Fourier Transform (FFT) is performed on the sequence to obtain its frequency domain representation; the negative frequency portion of the frequency domain representation is set to zero, the positive frequency portion is multiplied by a coefficient of 2, and the zero-frequency component remains unchanged; an Inverse Fourier Transform is performed on the processed frequency domain data to obtain a complex signal sequence, which is the analytic signal. The real part of the analytic signal is equal to the original intrinsic mode function component, and the imaginary part is its Hilbert transform result. This process must satisfy the sampling theorem requirement; a sampling frequency of 100 Hz corresponds to a maximum analysis frequency of 50 Hz.

[0035] When extracting the instantaneous frequency from an analytic signal, the following calculation steps are performed: Read the real and imaginary parts of the analytic signal; calculate the ratio of the imaginary to the real part for each sampling point; perform a four-quadrant arctangent operation on this ratio to obtain the phase angle function value, which ranges from negative to positive pi; calculate the difference between the phase angle function values ​​of two adjacent sampling points (adjacent sampling points are those consecutive in time); divide this difference by the sampling time interval of 0.01 seconds to obtain the rate of change of the phase angle; divide the rate of change of the phase angle by 2 and multiply by pi to obtain the instantaneous frequency value, measured in Hertz (Hz). For example, when the phase angle difference between adjacent sampling points is 0.314 radians, the rate of change of the phase angle is 31.4 radians per second, and the instantaneous frequency is 5 Hertz.

[0036] When extracting the instantaneous amplitude from an analytic signal, the following calculation steps are performed: read the real part sequence and the imaginary part sequence of the analytic signal; square the real part value at each sampling point; square the imaginary part value; add the squared real part value and the squared imaginary part value to obtain the sum of squares; perform an arithmetic square root operation on the sum of squares to obtain the instantaneous amplitude, with the unit of instantaneous amplitude being kilopascals (kPa). For example, when the real part at a sampling point is 0.8 kPa and the imaginary part is 0.6 kPa, the square of the real part is 0.64, the square of the imaginary part is 0.36, the sum of squares is 1.0, and the arithmetic square root is 1.0 kPa.

[0037] When constructing the Hilbert marginal spectrum based on the instantaneous frequency and instantaneous amplitude of all sampling points, the following process is followed: The frequency analysis range is set to 0 Hz to 50 Hz, with the upper frequency limit determined according to the Nyquist sampling theorem; the frequency range is divided into 500 equally spaced frequency bands, each with a width of 0.1 Hz; for each frequency band, all sampling points whose instantaneous frequencies fall within the band's range are counted, with the instantaneous frequency falling within the band's range defined as an instantaneous frequency value greater than or equal to the lower limit and less than the upper limit; the instantaneous amplitudes corresponding to these sampling points are summed to obtain the cumulative amplitude of the frequency band; the sum of the cumulative amplitudes of all frequency bands is calculated; the cumulative amplitude of each frequency band is divided by the sum to obtain the normalized cumulative amplitude; the distribution of the normalized cumulative amplitudes of all frequency bands constitutes the Hilbert marginal spectrum. For example, if there are 20 sampling points in the 10.0 Hz to 10.1 Hz frequency band, the sum of their instantaneous amplitudes is 15.0 kPa, and the total cumulative amplitude is 3000 kPa, then the normalized cumulative amplitude of this frequency band is 0.005.

[0038] When calculating the energy centroid frequency of the Hilbert marginal spectrum, a weighted average algorithm is used: The center frequency value of each frequency band is taken, equal to the lower limit of the band plus 0.05 Hz; the center frequency value is multiplied by the normalized cumulative amplitude of the corresponding frequency band to obtain a weighted value; the weighted values ​​of all frequency bands are summed to obtain a weighted sum; the weighted sum is the energy centroid frequency, in Hz. For example, when the main energy is concentrated around 10 Hz, if the center frequency of 10.05 Hz corresponds to an amplitude of 0.01, and 10.15 Hz corresponds to 0.008, then the weighted sum is 10.05 × 0.01 + 10.15 × 0.008 + ... = 10.5 Hz.

[0039] The reference centroid frequency was determined as follows: Thirty consecutive pressure value samples were collected under normal operating conditions of the gas system, each sample containing 1024 sampling points; the Hilbert marginal spectrum analysis procedure described above was performed on each sample to calculate the energy centroid frequency; the arithmetic mean of the 30 energy centroid frequency values ​​was taken as the reference centroid frequency, calculated by summing and dividing by 30. The reference centroid frequency is stored in non-volatile memory and updated every three months, with the update cycle set according to the seasonal variation characteristics of the gas system.

[0040] When comparing the current energy centroid frequency with the reference centroid frequency, the algebraic difference between the two is calculated to obtain the marginal spectral energy centroid offset. The algebraic difference equals the current energy centroid frequency minus the reference centroid frequency, and the offset is measured in Hertz (Hz). A positive offset indicates a shift in energy distribution towards higher frequencies, while a negative offset indicates a shift towards lower frequencies. For example, if the reference centroid frequency is 25.0 Hz and the current energy centroid frequency is 28.0 Hz, the offset is +3.0 Hz.

[0041] During implementation, data validity checks are implemented as follows: When the instantaneous frequency calculation results in a negative value, the data point is discarded, as negative frequencies have no physical meaning; when the instantaneous amplitude exceeds the sensor's range of +50 kPa or falls below -10 kPa, it is marked as invalid data; when the energy centroid frequency exceeds the 0-50 Hz range, empirical mode decomposition is performed again. Invalid data is handled by discarding abnormal sampling points and replacing them with the value of the previous valid sampling point. All calculations are performed in a digital signal processor, and the processing delay from data input to output offset is measured to be less than 100 milliseconds.

[0042] When the angle between the direction angle of the pressure gradient vector and the maximum intensity direction of the leak detection signal is less than the critical angle and the centroid shift of the marginal spectral energy is greater than the frequency shift threshold, an air backflow risk is determined to have occurred. Specifically, this is implemented as follows: The direction angle of the pressure gradient vector is calculated within the pipe's spatial coordinate system. The pressure gradient vector is a three-dimensional vector, and its direction angle is defined as the angle between this vector and the positive axial direction of the pipe. Since the pressure gradient vector only has a pipe-direction component, the direction angle is calculated as follows: when the pipe-direction component of the pressure gradient vector is positive, the direction angle is 0 degrees; when the component is negative, the direction angle is 180 degrees. The calculation is performed in the microcontroller. For example, when the pipe-direction component of the pressure gradient vector is 0.2 kPa / m, the direction angle is 0 degrees; when the component is -0.2 kPa / m, the direction angle is 180 degrees. The angle values ​​are stored as single-precision floating-point numbers, retaining one decimal place.

[0043] To determine the location of the maximum intensity of the leak detection signal, the output signal of the distributed gas sensor array is processed. The maximum intensity location is defined as the spatial position corresponding to the detection unit with the largest output signal amplitude, obtained through the following steps: current signals from each detection unit are collected in a cyclic manner, ranging from 4 mA to 20 mA; the current signals are converted into digital amplitude values; the amplitude values ​​of all detection units are compared; the detection unit number corresponding to the largest amplitude value is recorded; and the spatial coordinates are determined based on a pre-stored mapping relationship between the numbers and positions. For example, when detection unit number 3 has the largest amplitude and its position coordinates are 6 meters along the pipe axis, the maximum intensity location is recorded as 6 meters. When multiple detection units have the same amplitude, the unit with the largest position coordinate value is selected as the maximum intensity location.

[0044] When calculating the angle between the azimuth and the azimuth of maximum intensity, the spatial location needs to be converted into an angle. The azimuth conversion method is as follows: divide the axial distance corresponding to the azimuth of maximum intensity by the total pipe length L, and multiply the result by 180 to obtain the angle value. For example, if the pipe length is 10 meters and the leak point is 6 meters away, the azimuth is 108 degrees. The angle is calculated using the absolute value of the difference between the azimuth and the azimuth; for example, if the azimuth is 0 degrees and the azimuth is 108 degrees, the angle is 108 degrees. The calculation result is stored as an unsigned integer in degrees.

[0045] When acquiring the marginal spectral energy centroid offset, the output value of the spectral shift module is read via the data bus. The offset unit is Hertz, expressed as a signed single-precision floating-point number, with a value range limited to -50.0 Hertz to +50.0 Hertz. The reading cycle is synchronized with the pressure acquisition cycle at 10 milliseconds, and data is transmitted via the SPI interface.

[0046] The critical angle is set as follows: The angular deviation data between the pressure gradient direction and the leak point location under different leakage conditions are obtained through fluid dynamics simulation. The minimum angular deviation value is multiplied by a safety factor of 0.8 to obtain the baseline critical angle. This is then adjusted according to the pipe material: the baseline value is used for metal pipes, and an increase of 5 degrees is made for non-metallic pipes. For example, when the minimum simulated angle is 15 degrees, the baseline critical angle is 12 degrees; for plastic pipes, it is 17 degrees. The critical angle is stored in EEPROM and updated every six months.

[0047] The frequency shift threshold is determined as follows: Record the marginal spectral energy centroid shift data under normal operating conditions for 30 consecutive days, calculate the standard deviation of these data, multiply the standard deviation by a coefficient of three to obtain the base threshold, and then add a 10% safety margin. For example, if the standard deviation is 0.5 Hz, the base threshold is 1.5 Hz, and the final frequency shift threshold is 1.65 Hz. The threshold is automatically updated monthly.

[0048] The comparison operation is implemented through a hardware comparison circuit: the first comparator receives the included angle value and the critical angle, and outputs a high level when the included angle is less than the critical angle; the second comparator receives the offset and the frequency shift threshold, and outputs a high level when the offset is greater than the frequency shift threshold; the outputs of the two comparators are connected to an AND gate circuit. For example, if the critical angle is set to 12 degrees, the first comparator outputs a high level when the included angle is 10 degrees; if the frequency shift threshold is set to 1.65 Hz, the second comparator outputs a high level when the offset is 2.0 Hz, and the AND gate outputs a high level.

[0049] When generating the air backflow risk assessment result, the AND gate output signal is converted into a data packet. A high-level AND gate output generates a risk presence flag (0xAA), and a low-level output generates a risk-free flag (0x55). The data packet contains a timestamp and a checksum, and is transmitted to the control module via the CAN bus at a rate of 500kbps. For example, the generated data packet format is [0xAA, timestamp, CRC8].

[0050] An anomaly handling mechanism is configured as follows: When the maximum intensity azimuth is marked as empty (i.e., all detection unit signals are below 2% LEL), a risk-free judgment is directly output; when the offset exceeds the effective range, the arithmetic mean of the three most recent effective offsets is used instead; when the pipe length is less than 1 meter, the included angle is fixed at 0 degrees. Anomalies are recorded in the system log.

[0051] The judgment result employs a three-level verification mechanism: After the initial judgment, a second judgment is performed after a 100-millisecond delay. If the two results match, the final result is confirmed. If the two results do not match, a third judgment is performed, and the result that matches both is taken as the final output. For example, if the initial judgment indicates risk but the second judgment indicates no risk, the third judgment is initiated, and the result that matches is taken. The maximum verification process takes 300 milliseconds.

[0052] Dynamic adjustment of critical angle and frequency shift threshold: False alarm rate and false negative rate are calculated every 24 hours. False alarm rate is defined as the ratio of risk-free events mistakenly identified as risky, and false negative rate is defined as the ratio of risky events not detected. When the false alarm rate exceeds 5%, the critical angle increases by 1 degree; when the false negative rate exceeds 2%, the frequency shift threshold increases by 0.1 Hz. The adjustment range does not exceed ±20% of the initial value. For example, if the initial critical angle is 12 degrees, it is adjusted to 13 degrees when the false alarm rate is 6%.

[0053] The physical meaning of the angle between the pressure gradient vector direction angle and the leakage azimuth angle: When the angle is less than the critical angle, it indicates that the leakage point is located in the direction of the negative pressure wave propagation caused by the valve closing. When the offset is greater than the frequency shift threshold, it indicates that the change in the gas composition in the pipeline leads to a change in the sound speed. When both occur simultaneously, it indicates that air is being drawn back into the pipeline.

[0054] Figure 2 A flowchart for determining the coordinated backflow of multiple leak points according to this invention is provided. The local curvature distribution of the pressure wave propagation front is calculated using the oscillating waveform of the pressure value. When at least two discrete maxima exist in the local curvature distribution, coordinated backflow of multiple leak points is determined to have occurred. The specific implementation is as follows: When acquiring the oscillating waveforms of pressure values ​​at different locations in the pipeline, the historical data buffers of the pressure sensors at the beginning, middle, and end of the pipeline are accessed. The oscillating waveform refers to the dynamic pressure change curve recorded during valve closure, spanning from 100 milliseconds before valve closure begins to 500 milliseconds after complete closure, with a sampling frequency of 100 Hz. 600 sampling points are stored at each location, in timestamped single-precision floating-point number format, in kilopascals. The waveform data is transmitted to the signal processor via a direct memory access channel, without consuming central processing unit resources during transmission.

[0055] When reconstructing the pressure wave propagation process based on oscillating waveforms, a time-space interpolation algorithm is employed. First, a spatial model of the pipeline is established: with the pipeline's inlet as the zero point and its outlet as the endpoint, the total length L is divided into 100 equally divided grid points. For each time point (10 millisecond intervals), the following operations are performed: pressure values ​​at three locations are read; the pressure values ​​at the 100 grid points are calculated using cubic spline interpolation; and all grid point pressure values ​​are arranged spatially to form an instantaneous pressure distribution. All instantaneous distributions are then combined in temporal order to construct a three-dimensional matrix of pressure wave propagation (time × location × pressure value). For example, 200 milliseconds after the valve closes, the pressure value at a distance of 3.5 meters from the inlet can be obtained through interpolation using the standard cubic spline interpolation method.

[0056] When identifying the morphological changes of the pressure wavefront, the wavefront position is first defined: in each time series, the point at which the pressure value first drops by more than 0.5 kPa is found; this threshold is set based on twice the noise level of the pressure sensor. The position corresponding to this point is the wavefront position. All grid points are scanned along the pipe axis, and the curve of the wavefront position changing over time is recorded. Morphological changes include: the concavity / convexity of the wavefront curve, the number of inflection points, and the rate of change of curvature. Specific identification methods include: calculating the wavefront time difference between adjacent grid points; when the change in time difference exceeds 10%, it is marked as an inflection point; the 10% threshold is determined statistically based on waveform smoothness. Concavity / convexity is judged by the angle between the lines connecting three adjacent points; an angle less than 170 degrees is considered a concave feature.

[0057] To quantify the local curvature of the wavefront, a discrete curvature algorithm is used. For each grid point on the wavefront position curve, two adjacent grid points (two to the left and two to the right, for a total of five points) are selected, and a second-order polynomial function is fitted. The curvature calculation process is as follows: First, calculate the wavefront time difference between the center point and the second point to the left; calculate the wavefront time difference between the center point and the second point to the right; calculate the wavefront time difference between the first point to the left and the first point to the right; add the left difference to the right difference and subtract twice the center difference to obtain the numerator; divide the absolute value of the numerator by the square of the grid spacing to obtain the curvature value.

[0058] When scanning the local curvature distribution within the pipe's spatial range, all grid points are traversed along the pipe's axis. Each grid point corresponds to a curvature value, forming a curvature distribution array. The scanning process employs a sliding window mechanism: the window width is five grid points (0.5 meters), and the step size is one grid point. For each window location, the curvature value at the window's center point is calculated and recorded. Finally, a curvature distribution map is generated covering the entire length of the pipe, with the horizontal axis representing the pipe's location and the vertical axis representing the curvature value. For example, a 10-meter-long pipe generates 100 curvature data points.

[0059] When marking locations with significant local curvature, a dynamic threshold mechanism is implemented. First, the average curvature distribution of the entire pipe is calculated. This average is then multiplied by a coefficient of 1.5 to create a base threshold. The coefficient 1.5 is determined statistically based on typical leakage scenarios. Simultaneously, the gradient change in the curvature distribution is detected. When the gradient change rate exceeds 5% per meter, the base threshold is reduced by 20%. The marking condition is: the curvature value exceeds the dynamic threshold and is a local maximum (greater than the curvature values ​​of the two adjacent grid points). For example, with an average curvature of 150 milliseconds per square meter and a base threshold of 225 milliseconds per square meter, a point with a curvature of 250 milliseconds per square meter that is greater than its neighbors is marked. The marked point's location coordinates and curvature value are recorded.

[0060] When analyzing the spatial distribution of marker points, clustering isolation detection is performed. All marker points are sorted according to their axial position on the pipe, and the distance between adjacent marker points is calculated. Isolation criteria: adjacent marker points are considered isolated when the distance is greater than 0.3 meters (the 0.3-meter threshold is three times the typical pipe diameter of 0.1 meters); collaborative detection is triggered when at least two independent isolation groups exist. An isolation group is defined as follows: the distance between points within a group is less than 0.3 meters, and the minimum distance between groups is greater than 0.3 meters. For example, if three marker points are located at 1.2 meters, 1.5 meters, and 3.0 meters, then 1.2 meters and 1.5 meters form one group (0.3-meter distance), and 3.0 meters is an independent point, forming two isolation groups.

[0061] When generating multiple leak point collaborative backflow detection results, a confidence level verification is set. When two or more isolation groups are detected, each group must contain at least one marker point and the minimum distance between groups must be greater than 0.3 meters. The detection result is a binary flag: a high level (5 volts) is output when the condition is met, and a low level (0 volts) is output otherwise. The result signal is transmitted to the control module through an optocoupler isolation circuit, with a response time of less than 10 milliseconds. For example, a 5-volt signal is output when two isolation groups are detected.

[0062] The implementation process includes a data verification mechanism: when the wavefront position curve is discontinuous (with gaps of more than 5 grid points), linear interpolation is initiated to fill the gaps; when the curvature calculation results in a negative value, it is forcibly reset to zero; when the pipe length is less than 3 meters, the isolation distance threshold is adjusted to 10% of the pipe length. All calculations are completed within 200 milliseconds, synchronized with the valve closing action.

[0063] Dynamic threshold adjustment rule: The distribution of the number of marked points is statistically analyzed every 24 hours. When the number of marked points exceeds 5 for 80% of the time period, the coefficient is increased from 1.5 to 1.7; when the number of marked points is consistently less than 2, the coefficient is decreased to 1.3. The adjustment result is written to non-volatile memory, which uses ferroelectric random access memory technology.

[0064] The physical principle of wavefront detection: Multiple leak points cause multiple depressions on the pressure wavefront. The location of the depression corresponds to the leak point, and the depth of the depression is proportional to the leakage rate. The curvature maxima correspond to the locations of abrupt changes in the wavefront shape. Spatially isolated maxima indicate the existence of multiple independent leak sources.

[0065] Pressure oscillation waveform acquisition synchronization mechanism: The pressure sensors at three locations use the same clock source with a clock synchronization accuracy of 0.1 milliseconds to ensure time alignment. The data buffer adopts a double buffer structure to ensure that continuous acquisition does not lose data.

[0066] Based on the assessment of the risk of backflow of air and the coordinated backflow from multiple leak points, the valve closing action is switched to a two-stage mode and a linkage ventilation command is triggered. The specific implementation is as follows: When receiving the results of the air backflow risk assessment and the results of the coordinated backflow assessment from multiple leak points, two signals are acquired through the digital input interface. The air backflow risk assessment result is represented by a 5V high level indicating the presence of risk, and a 0V low level indicating no risk. Similarly, the coordinated backflow assessment result from multiple leak points is represented by a 5V high level indicating the presence of coordinated leakage, and a 0V low level indicating no coordinated leakage. The signals are input to the control unit through an opto-isolation circuit, with a signal sampling period of 10 milliseconds. A valid signal is determined when the input signal level remains stable for more than 20 milliseconds; this stabilization time threshold is set based on the maximum duration of the electrical interference pulse.

[0067] When the air backflow risk assessment result is high, a linked ventilation command is generated. The linked ventilation command is a 24V DC pulse signal with a pulse width of 500 milliseconds, determined by the minimum relay engagement time; the repetition period is 5 seconds, set based on the ventilation system's response characteristics. This command is sent to the ventilation system controller, triggering the following actions: starting the explosion-proof axial flow fan, with fan power calculated based on the duct volume, matching 50 watts per cubic meter of duct volume; opening the ventilation duct solenoid valve, setting the valve opening to 100%; and fixing the ventilation duration to 120 seconds, calculated based on the time required for complete gas replacement within the duct. For example, a 10-cubic-meter duct matched with a 500-watt fan maintains an airflow of 12 cubic meters per minute during ventilation.

[0068] When both a high level of air backflow risk and a high level of combined backflow risk from multiple leak points are detected simultaneously, the valve closing action is switched to a two-stage mode. The first stage control process: The stepper motor is controlled to drive the valve stem at a speed of 30 revolutions per minute, which is 80% of the normal closing speed; the valve is closed from the fully open position to the first opening position. The first opening position is determined through a flow feedback closed loop: the output value of the gas flow sensor is monitored in real time, and the closing action stops when the flow value drops to 5% of the lower explosive limit. The lower explosive limit is preset according to the gas composition: 5% by volume for natural gas and 2% by volume for liquefied petroleum gas. For example, if the lower explosive limit in a natural gas pipeline is 5%, the target flow value is 0.25% (5% multiplied by 5%).

[0069] The first opening maintenance phase: The valve position remains unchanged for 60 seconds, a duration determined based on a gas diffusion model. During this period, the gas flow rate is continuously monitored. If the flow rate rises above 6% of the lower explosive limit, the closing action is restarted until it returns to below 5% of the lower explosive limit. A ventilation command is simultaneously triggered during the maintenance phase, increasing the ventilation intensity to 1.5 times that of the normal mode, achieved by increasing the fan speed.

[0070] The second stage of control involves controlling the stepper motor to operate in a deceleration mode after the maintenance phase, reducing its speed to 10 revolutions per minute (RPM), one-third of the speed in the first stage. The closing process utilizes a position-speed curve: the initial 10% of the stroke maintains 10 RPM; the middle 80% of the stroke decreases to 8 RPM; and the final 10% of the stroke decreases to 5 RPM. The total closing time is controlled within the range of 15 to 25 seconds, adjusted using a preset parameter table based on the valve type. For example, a 20 mm diameter ball valve takes 20 seconds to close from its initial opening position.

[0071] The implementation process includes a safety interlock mechanism: if the flow rate fails to drop below 10% of the lower explosion limit within 5 seconds during the first-stage shutdown process, it is determined to be a regulation failure, and the system is immediately switched to emergency shutdown mode to shut down at full speed of 45 revolutions per minute; when the ventilation system fault feedback signal is valid, the two-stage mode is prohibited; when the pipeline pressure is below 5 kPa, the maintenance stage is automatically shortened to 30 seconds.

[0072] The parameters for the two-stage mode are set as follows: the first speed of 30 revolutions per minute is set at 80% of the conventional valve closing speed, and this ratio is determined through a water hammer effect simulation test; the second speed of 10 revolutions per minute is taken as one-third of the first speed, and this ratio is determined through a negative pressure surge suppression test; the first opening duration of 60 seconds is determined based on the gas turbulence diffusion equation.

[0073] Ventilation system linkage control: Regular ventilation commands trigger single-fan operation; two-stage mode triggers parallel operation of dual fans. Airflow calibration method: An airflow sensor is installed at the ventilation duct outlet, and the fan speed is adjusted in real time to stabilize the airflow at 5 meters per second. For example, if an airflow speed of 4.5 meters per second is detected, the fan speed is increased by 10% until it reaches 5 meters per second.

[0074] Valve position feedback calibration: Closed-loop control is achieved through the voltage signal from the valve core position sensor, with a 0.1-volt voltage change corresponding to every 5-degree valve core rotation. The control unit reads the voltage value every 10 milliseconds and calculates the opening degree through linear interpolation, with an accuracy error of less than 1%. For example, if the target opening degree of 30% corresponds to a voltage of 1.5 volts, and the actual detected voltage is 1.48 volts, the valve will continue to close by 0.6 degrees.

[0075] Dynamic parameter adjustment mechanism: Valve closing process data is statistically analyzed every 24 hours. When the frequency of first-stage closing time exceeding 8 seconds exceeds 50%, the first speed is increased to 35 revolutions per minute; when the frequency of second-stage pressure fluctuations exceeding 10 kPa exceeds 20%, the second speed is reduced to 8 revolutions per minute. Adjusted parameters are written to the ferroelectric memory, which has a write / erase cycle life of 1 million times.

[0076] Explosive lower limit (LEL) tolerance: A 0.1% buffer zone is set, and flow rates within the LLE range of 4.9% to 5.1% are considered compliant. For example, if the LLE of a natural gas pipeline is 5%, the actual flow rate corresponding to a concentration between 4.95% and 5.05% will trigger the opening maintenance.

[0077] Ventilation command priority setting: When both regular ventilation commands and two-stage mode ventilation commands exist simultaneously, the high-intensity ventilation of the two-stage mode is executed first. Ventilation system status feedback is transmitted via a 4 mA to 20 mA current signal; a fault alarm is triggered when the current value is below 6 mA.

[0078] All calculations involved in the embodiments are dimensionless numerical calculations, and the preset parameters and thresholds in the calculations are set by those skilled in the art according to the actual situation.

[0079] It should be noted that this invention can be deployed on the device itself to realize embedded applications, or it can run on a PC or other terminal with a user interface, thereby meeting various hardware environments and usage requirements.

[0080] 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 wireless or wired transmission; wired transmission methods include optical fiber, twisted pair, coaxial cable, etc.; wireless transmission includes infrared, microwave, etc. 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 containing one or more sets of available media. The available medium can be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium. A semiconductor medium can be a solid-state drive.

[0081] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and modules described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.

[0082] 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 modules is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple modules 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 modules may be electrical, mechanical, or other forms.

[0083] The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical modules; they may be located in one place or distributed across multiple network modules. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.

[0084] In addition, the functional modules in the various embodiments of this application can be integrated into one processing module, or each module can exist physically separately, or two or more modules can be integrated into one module.

[0085] If the aforementioned functions are implemented as software functional modules 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 hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0086] 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.

[0087] In conclusion, the above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

Claims

1. A security-type intelligent diaphragm gas meter, characterized in that, include: The flow monitoring module is used to monitor the gas flow rate in real time. When the gas flow rate exceeds the preset leakage threshold, it generates a valve closing signal. The pressure gradient module is used to initiate valve closing operation in response to valve closing action signals. During the valve closing operation, it collects pressure values ​​at different locations in the pipeline and generates a pressure gradient vector based on the spatial distribution of the pressure values; it also simultaneously acquires leakage detection signals. The spectral shift module is used to analyze pressure values ​​through Hilbert-Huang transform and extract the centroid shift of marginal spectral energy. The backflow detection module is used to determine the risk of air backflow when the angle between the direction angle of the pressure gradient vector and the maximum intensity direction of the leak detection signal is less than the critical angle and the centroid offset of the marginal spectrum energy is greater than the frequency shift threshold. The leak detection module is used to calculate the local curvature distribution of the pressure wave propagation wavefront through the oscillation waveform of the pressure value. When there are at least two discrete maximum points in the local curvature distribution, it is determined that multiple leak points are co-currently drawing back. The joint control module is used to switch the valve closing action to a two-stage mode and trigger a joint ventilation command based on the judgment results of the risk of backflow of air and the coordinated backflow of multiple leak points.

2. The security-type intelligent diaphragm gas meter according to claim 1, characterized in that, Real-time monitoring of gas flow rate; when the gas flow rate exceeds a preset leakage threshold, a valve shut-off signal is generated, including: The gas flow rate is obtained in real time through a diaphragm metering device; Compare the gas flow rate value with the preset leakage threshold; When the gas flow rate exceeds the preset leakage threshold, a valve shut-off signal is generated.

3. A security-type intelligent diaphragm gas meter according to claim 2, characterized in that, in, If the gas flow rate exceeds the preset leakage threshold for a preset duration, an operation to generate a valve closing signal will be executed.

4. A security-type intelligent diaphragm gas meter according to claim 1, characterized in that, The valve closing operation is initiated in response to a valve closing signal. During the valve closing operation, pressure values ​​at different locations in the pipeline are collected, and a pressure gradient vector is generated based on the spatial distribution of the pressure values. Simultaneously, leakage detection signals are acquired, including: The valve closing action is initiated in response to the valve closing signal; During the continuous valve closing action, pressure values ​​at different locations in the pipeline are collected by pressure sensors installed at the beginning, middle and end of the pipeline. Calculate the pressure gradient vector based on the spatial distribution of pressure values ​​at the beginning, middle, and end of the pipeline; Leak detection signals are acquired synchronously through a distributed gas sensor array.

5. A security-type intelligent diaphragm gas meter according to claim 1, characterized in that, The pressure values ​​were analyzed using the Hilbert-Huang transform to extract the marginal spectral energy centroid shift, including: Empirical mode decomposition of the pressure value generates multiple intrinsic mode function components; Perform a Hilbert transform on each intrinsic mode function component to obtain the instantaneous frequency and instantaneous amplitude; Hilbert marginal spectrum is constructed based on instantaneous frequency and instantaneous amplitude; Calculate the energy centroid frequency of the Hilbert marginal spectrum; The marginal spectrum energy centroid offset is obtained by comparing the energy centroid frequency with the reference centroid frequency.

6. A security-type intelligent diaphragm gas meter according to claim 5, characterized in that, Perform a Hilbert transform on each intrinsic mode function component to obtain the instantaneous frequency and instantaneous amplitude, including: Construct analytical signals from the intrinsic mode function components; Extract the phase angle function of the analytical signal, calculate the first derivative of the phase angle function with respect to time, and divide the value of the first derivative of the phase angle function with respect to time by twice pi to obtain the instantaneous frequency; Calculate the sum of squares of the real and imaginary parts of the analytic signal, and perform an arithmetic square root operation on the sum of squares to obtain the instantaneous amplitude.

7. A security-type intelligent diaphragm gas meter according to claim 1, characterized in that, When the angle between the direction angle of the pressure gradient vector and the maximum intensity orientation of the leak detection signal is less than the critical angle and the centroid shift of the marginal spectral energy is greater than the frequency shift threshold, an air backflow risk is determined, including: Calculate the direction angle of the pressure gradient vector; Determine the location of the maximum intensity of the leak detection signal; Calculate the angle between the direction angle and the azimuth of maximum intensity; Obtain the centroid offset of the marginal spectral energy; Compare the included angle with the critical angle, and compare the marginal spectral energy centroid shift with the frequency shift threshold; When the included angle is less than the critical angle and the centroid shift of the marginal spectral energy is greater than the frequency shift threshold, an air backflow risk assessment result is generated.

8. A security-type intelligent diaphragm gas meter according to claim 1, characterized in that, The local curvature distribution of the pressure wave propagation front is calculated by analyzing the oscillating waveform of the pressure value. When there are at least two discrete maxima in the local curvature distribution, it is determined that multiple leakage points are co-currently drawing back, including: Obtain the oscillation waveform of pressure values ​​at different locations in the pipeline; Reconstructing the propagation process of pressure waves in the pipeline based on oscillating waveforms; Identify the morphological changes of the propagation wavefront of pressure waves; Quantify the degree of local bending of the wavefront based on morphological change characteristics; Scan the distribution of localized curvature within the spatial range of the pipeline; Mark the locations where the degree of local curvature is prominent; Analyze the spatial distribution relationship of the marked location points; When there are at least two mutually isolated marker locations, multiple leak point collaborative backflow determination results are generated.

9. A security-type intelligent diaphragm gas meter according to claim 1, characterized in that, Based on the assessment of the risk of backdraft and the coordinated backdraft from multiple leak points, the valve closing action is switched to a two-stage mode and a linked ventilation command is triggered, including: Receive the results of the air backflow risk assessment and the results of the coordinated backflow assessment from multiple leak points; When there is a risk of backdraft, a coordinated ventilation command is generated to dilute the residual gas in the duct. When there is a risk of backflow of air and backflow from multiple leak points, the valve closing action is switched to a two-stage mode.

10. A security-type intelligent diaphragm gas meter according to claim 9, characterized in that, The two-stage mode is as follows: in the first stage, the valve is closed to the first opening degree at the first speed, and the first opening degree maintains the gas flow rate value below the lower explosive limit of the mixed gas; in the second stage, the valve is closed to the fully closed state at the second speed, which is lower than the first speed.

Citation Information

Patent Citations

  • Hilbert-Huang transform-based speech feature coefficient extraction method and related equipment

    CN111899724A

  • Gas meter

    CN112601940A

  • Valve state detection method of Internet of Things intelligent gas meter based on safety monitoring function

    CN113050522A

  • Gas meter

    CN114608673A

  • Diaphragm gas meter and diaphragm gas meter control system

    CN116182974A