A high-precision electromagnetic water meter measurement method using intelligent sensors

By collecting quantum tunneling current signals through intelligent sensors, generating partitioned compensated excitation magnetic fields, and combining them with dynamic temperature compensation, the shortcomings of traditional electromagnetic water meters in terms of magnetic field inhomogeneity and temperature compensation are solved, thereby improving measurement accuracy and stability.

CN120668226BActive Publication Date: 2026-06-12ZHEJIANG PRECISION CONTROL INSTR CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
ZHEJIANG PRECISION CONTROL INSTR CO LTD
Filing Date
2025-05-31
Publication Date
2026-06-12

AI Technical Summary

Technical Problem

Traditional electromagnetic water meters have shortcomings in terms of uneven spatial distribution of magnetic field and nonlinear temperature compensation, which leads to a decrease in signal-to-noise ratio and affects accuracy, especially with large measurement errors under dynamic interference.

Method used

By employing intelligent sensors to collect quantum tunneling current signals and extract magnetic field distortion characteristics, a partitioned compensation excitation magnetic field is generated. Combined with a space vector pulse width modulation algorithm and a joint correlation prediction model, dynamic temperature compensation and zero-point calibration are performed to improve signal purity and measurement stability.

🎯Benefits of technology

It effectively eliminates magnetic field inhomogeneity and temperature drift, improving the measurement accuracy and stability of electromagnetic water meters and enabling high-confidence flow measurement.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120668226B_ABST
    Figure CN120668226B_ABST
Patent Text Reader

Abstract

The application discloses a kind of high-precision measurement methods of electromagnetic water meter using intelligent sensor, it is related to fluid metering cross technical field, including, based on the electrode original signal generated by excitation magnetic field, obtain the uniformity index of partition compensation excitation magnetic field, and dynamically configure the gate voltage of ion channel, generate the voltage signal after purification;Joint correlation prediction model is constructed, and the voltage signal after purification and mechanical vibration data are fused and analyzed, to obtain initial water flow estimate value;Through dynamic temperature compensation and zero point online calibration, error correction is carried out to initial water flow estimate value, to generate high confidence water flow value.The application calculates the magnetic field uniformity index of each sector region in real time by space-time differential-spectrum joint analysis method, and dynamically adjusts the gate voltage of ion channel according to the magnetic field uniformity index, to realize adaptive suppression to harmonic interference and timing error in electrode signal, to improve signal purity and measurement stability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of fluid metering technology, and in particular to a high-precision measurement method for electromagnetic water meters using intelligent sensors. Background Technology

[0002] Electromagnetic water meters, as important devices in the field of flow measurement, are based on Faraday's law of electromagnetic induction. They calculate flow rate by measuring the induced electromotive force generated when a conductive fluid cuts magnetic field lines. Traditional techniques typically employ a scheme combining a uniform excitation magnetic field with electrode signal detection. The excitation system often consists of a Helmholtz coil or segmented excitation windings to generate a relatively stable working magnetic field. For signal processing, conventional methods extract the fundamental component of the electrode signal using Fourier transform and filter out high-frequency harmonic interference using a fixed threshold. Furthermore, temperature compensation often relies on a pre-calibrated linear temperature-flow curve, while zero-point calibration is achieved through periodic static calibration. Such methods can meet basic metering requirements under stable operating conditions.

[0003] While traditional methods offer advantages such as simple structure and controllable cost, their performance is limited by insufficient magnetic field spatial uniformity and the bottleneck of dynamic interference suppression capabilities. Specifically, fixed excitation modes struggle to adapt to magnetic field distortions in the pipe cross-section (such as edge effects or interference from ferromagnetic materials), leading to a decrease in the signal-to-noise ratio of the electrode signals. Furthermore, static temperature compensation curves cannot adequately fit the nonlinear characteristics of material thermal expansion, especially under transient temperature change conditions, easily introducing additional errors. In addition, the coupling interference between mechanical vibration and electromagnetic harmonics further affects signal resolution accuracy, and the adaptability of existing frequency domain filtering methods to time-varying interference needs improvement. Summary of the Invention

[0004] In view of the aforementioned existing problems, the present invention is proposed.

[0005] Therefore, this invention provides a high-precision measurement method for electromagnetic water meters using intelligent sensors to solve the problems of uneven spatial distribution of magnetic fields and inaccurate compensation for nonlinear temperature drift.

[0006] To solve the above-mentioned technical problems, the present invention provides the following technical solution:

[0007] In a first aspect, the present invention provides a high-precision measurement method for electromagnetic water meters using intelligent sensors, comprising: acquiring quantum tunneling current signals in the circumferential direction of the pipeline and extracting magnetic field distortion features; based on the magnetic field distortion features, calculating the compensation current intensity of each pipeline region using a compensation engine, and generating a partitioned compensation excitation magnetic field by combining the spatial distribution of the magnetic field distortion features and using a spatial vector pulse width modulation algorithm; obtaining the uniformity index of the partitioned compensation excitation magnetic field based on the original electrode signals generated by the excitation magnetic field, and dynamically configuring the gate voltage of the ion channel to generate a purified voltage signal; constructing a joint correlation prediction model, and performing fusion analysis on the purified voltage signal and mechanical vibration data to obtain an initial water flow estimate; and correcting the initial water flow estimate through dynamic temperature compensation and zero-point online calibration to generate a high-confidence water flow value.

[0008] As a preferred embodiment of the high-precision measurement method for electromagnetic water meters using intelligent sensors described in this invention, the calculation of the compensation current intensity of each pipeline region using a compensation engine refers to defining a magnetic field gradient compensation threshold and identifying magnetic field distortion regions on the pipeline interface where the rate of change of magnetic field intensity exceeds the magnetic field gradient compensation threshold. Simultaneously, through the compensation engine, the compensation current intensity of the magnetic field distortion region is generated according to the ratio of the spatial distribution gradient of magnetic field intensity to the magnetic field gradient compensation threshold.

[0009] As a preferred embodiment of the high-precision measurement method for electromagnetic water meters using intelligent sensors described in this invention, the step of generating a partitioned compensated excitation magnetic field by combining the spatial distribution of magnetic field distortion characteristics and using a spatial vector pulse width modulation algorithm is as follows:

[0010] Real-time acquisition of excitation coil drive signals along the circumference of the pipeline;

[0011] Based on the amplitude of the interference harmonics, reverse harmonic components are injected into the excitation coil drive signal, and combined with the spatial distribution of the magnetic field distortion characteristics, the phase lag and phase angle are compensated by partition weighting to generate a spatially modulated excitation current waveform.

[0012] Based on the compensation current intensity and spatially modulated excitation current waveform in the magnetic field distortion region, a three-phase current vector synthesis is performed using a spatial vector pulse width modulation algorithm to generate a partitioned compensation excitation magnetic field.

[0013] As a preferred embodiment of the high-precision measurement method for electromagnetic water meters using intelligent sensors described in this invention, the method of obtaining the uniformity index of the partitioned compensation excitation magnetic field refers to collecting the original electrode signal after the partitioned compensation excitation magnetic field is applied, extracting the magnetic field intensity distribution characteristics of each sector region through STPA, and calculating the uniformity index of the partitioned compensation excitation magnetic field through the spatiotemporal differential-spectrum joint analysis method.

[0014] As a preferred embodiment of the high-precision measurement method for electromagnetic water meters using intelligent sensors described in this invention, the steps for dynamically configuring the gate voltage of the ion channel to generate the purified voltage signal are as follows:

[0015] Define low uniformity threshold and high uniformity threshold, and compare them with the uniformity index of the excitation magnetic field of each partition. Based on the comparison results, dynamically configure the gate voltage of the ion channel.

[0016] By adjusting the ion channel gating voltage, harmonic filtering and timing calibration are performed on the original voltage signal to generate a purified voltage signal.

[0017] As a preferred embodiment of the high-precision measurement method for electromagnetic water meters using intelligent sensors described in this invention, the steps of constructing a joint correlation prediction model and fusing and analyzing the purified voltage signal and mechanical vibration data to obtain an initial water flow estimate are as follows:

[0018] Based on the purified voltage signal and mechanical vibration data, state variables and observation variables are defined, and a state-space model is established using a particle filter algorithm.

[0019] By combining the state-space model with the extended Kalman filter algorithm using variational Bayesian inference, a joint correlation prediction model is generated.

[0020] By using a joint correlation prediction model, the purified voltage signal and mechanical vibration data are fused and analyzed to obtain an initial water flow estimate.

[0021] As a preferred embodiment of the high-precision measurement method for electromagnetic water meters using intelligent sensors described in this invention, the steps for correcting errors in the initial water flow estimate and generating a high-confidence water flow value through dynamic temperature compensation and online zero-point calibration are as follows:

[0022] Real-time pipe wall temperature data is collected, and the initial water flow estimate is compensated for temperature drift using a linear interpolation method to generate a temperature-compensated water flow estimate.

[0023] In a stagnant state, based on the temperature-compensated water flow estimate, a baseline drift correction algorithm is used to identify the zero-point offset, which is then corrected by exponentially weighted dynamic decay to generate a high-confidence water flow value.

[0024] In a second aspect, the present invention provides a computer device, including a memory and a processor, wherein the memory stores a computer program, wherein when the computer program is executed by the processor, it implements any step of the high-precision measurement method for electromagnetic water meters using intelligent sensors as described in the first aspect of the present invention.

[0025] Thirdly, the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein: when the computer program is executed by a processor, it implements any step of the high-precision measurement method for electromagnetic water meters using smart sensors as described in the first aspect of the present invention.

[0026] The beneficial effects of this invention are as follows: By employing a compensation engine combined with a space vector pulse width modulation algorithm, a partitioned compensation excitation magnetic field that matches the magnetic field distortion characteristics is dynamically generated, thereby achieving precise control of the magnetic field distribution across the pipe cross section and effectively eliminating the problem of magnetic field inhomogeneity caused by edge effects and interference from ferromagnetic materials; by using a spatiotemporal differential-spectrum joint analysis method to calculate the magnetic field uniformity index of each sector region in real time, and dynamically adjusting the ion channel gate voltage accordingly, the invention achieves adaptive suppression of harmonic interference and timing errors in the electrode signal, thereby improving signal purity and measurement stability. Attached Figure Description

[0027] To more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the following description of the embodiments will be briefly introduced. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0028] Figure 1 This is a flowchart of a high-precision measurement method for electromagnetic water meters using intelligent sensors.

[0029] Figure 2 This is a flowchart for generating the current intensity to compensate for the magnetic field gradient.

[0030] Figure 3 This is a flowchart for the synthesis of spatially modulated excitation magnetic fields.

[0031] Figure 4 A flowchart for the dynamic configuration of ion channel gating voltage. Detailed Implementation

[0032] To make the above-mentioned objects, features and advantages of the present invention more apparent and understandable, the specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings.

[0033] Many specific details are set forth in the following description in order to provide a full understanding of the invention. However, the invention may also be practiced in other ways different from those described herein, and those skilled in the art can make similar extensions without departing from the spirit of the invention. Therefore, the invention is not limited to the specific embodiments disclosed below.

[0034] Secondly, the term "one embodiment" or "embodiment" as used herein refers to a specific feature, structure, or characteristic that may be included in at least one implementation of the present invention. The phrase "in one embodiment" appearing in different places in this specification does not necessarily refer to the same embodiment, nor is it a single or selective embodiment that is mutually exclusive with other embodiments.

[0035] Reference Figures 1-4 This is one embodiment of the present invention, which provides a high-precision measurement method for electromagnetic water meters using smart sensors, comprising the following steps:

[0036] S1. Collect the quantum tunneling current signal in the circumferential direction of the pipeline and extract the magnetic field distortion characteristics;

[0037] The quantum tunneling current signal in the circumferential direction of the pipeline includes time-varying current data (including amplitude, phase and frequency components) that are detected in real time by an InAs quantum dot array and reflect the distribution of magnetic field strength in all directions on the cross-section of the pipeline.

[0038] Magnetic field distortion features include the spatial distribution gradient of magnetic field strength within the pipe, the amplitude of interference harmonics, and the phase lag. The extraction process is as follows:

[0039] The spatial distribution gradient of magnetic field strength is extracted based on the quantum tunneling current signal through spatial difference operation.

[0040] Furthermore, the quantum tunneling current signal contains information on the magnetic field strength distribution in all directions across the pipe cross-section. By performing spatial difference operations on the quantum tunneling current signals collected from adjacent measurement points, the rate of change of the current difference between adjacent points is calculated. The rate of change of the current difference is positively correlated with the magnetic field strength gradient. Based on a preset spatial difference algorithm, the radial and tangential changes in magnetic field strength in the pipe are calculated, establishing a magnetic field strength gradient distribution map on the pipe cross-section. The spatial difference operation uses the central difference method to ensure the accuracy and stability of the gradient calculation, ultimately outputting a quantized spatial distribution gradient of the magnetic field strength.

[0041] Fast Fourier transform is performed on the quantum tunneling current signal to extract the amplitude of interference harmonics;

[0042] Furthermore, the time-domain waveform of the quantum tunneling current signal contains a fundamental component and various harmonic interference components. A Fast Fourier Transform (FFT) is used to convert the time-domain signal into a frequency-domain spectrum. In the spectrum analysis, the main peak corresponding to the fundamental frequency is first identified, and then the amplitudes of other frequency components in the spectrum are detected. A harmonic detection threshold is set based on the percentage of the fundamental amplitude, and harmonic components with amplitudes exceeding the threshold are filtered out. The frequency and corresponding amplitude of each harmonic are recorded. The FFT employs windowing to reduce spectral leakage and improve harmonic detection accuracy, ultimately outputting the amplitude data of each interfering harmonic.

[0043] Phase lag is extracted by cross-correlation analysis of the time-domain waveform of the quantum tunneling current signal.

[0044] Furthermore, since there is a time delay between the quantum tunneling current signal at different measurement points, a cross-correlation algorithm is used to calculate the similarity of the signal waveforms. First, the signal waveform at a reference point is used as the baseline for the quantum tunneling current signal waveform at that reference point. The cross-correlation function between the signals at other measurement points and the baseline signal is calculated, and the time offset is determined by finding the peak value of the cross-correlation function. Using the ratio of the signal period to the sampling frequency, the time offset is converted into a phase angle difference, and combined with the location of the normalized cross-correlation peak, the phase lag at each measurement point is finally output.

[0045] The cross-section of the pipe is divided into several equiangular sector regions according to polar coordinates. Then, the magnetic field distortion characteristics in each region are identified by quantum tunneling current signal analysis, and finally the spatial distribution of magnetic field distortion characteristics is generated.

[0046] Furthermore, the pipe cross-section is divided into several equiangular sector regions according to the polar coordinate system, with each sector containing multiple measurement points. A multi-parameter spatial correlation analysis method is used to comprehensively analyze the quantum tunneling current signals within each sector region, extracting the magnetic field distortion characteristics of the current sector. Then, a spatial interpolation algorithm is used to extend the magnetic field distortion characteristics of the discrete measurement points into a continuous regional distribution, establishing a magnetic field distortion characteristic distribution map for each sector region. Finally, the magnetic field distortion characteristics of each sector region are integrated to generate a complete spatial distribution of the magnetic field distortion characteristics of the pipe cross-section.

[0047] S2. Based on the magnetic field distortion characteristics, a compensation engine is used to calculate the compensation current intensity of each pipeline area. Combined with the spatial distribution of the magnetic field distortion characteristics, a spatial vector pulse width modulation algorithm is used to generate a partitioned compensation excitation magnetic field.

[0048] Based on historical magnetic field gradient distribution data statistics, a magnetic field gradient compensation threshold is defined, and magnetic field distortion regions on the pipeline interface where the rate of change of magnetic field intensity exceeds the magnetic field gradient compensation threshold are identified.

[0049] Furthermore, based on the magnetic field gradient distribution data accumulated during historical operation, statistical analysis methods are used to calculate the typical distribution range of the magnetic field strength change rate. The central tendency and dispersion of the magnetic field gradient distribution are determined by fitting a probability density function, and a specific percentile value is selected as the magnetic field gradient compensation threshold. The magnetic field strength change rate at each location on the pipeline interface is monitored in real time, and the measured values ​​are compared point-by-point with the magnetic field gradient compensation threshold. Regions with a change rate exceeding the magnetic field gradient compensation threshold are marked as magnetic field distortion regions.

[0050] The excitation coil drive signal in the circumferential direction of the pipeline is acquired in real time by a Hall sensor array;

[0051] It should be noted that the excitation coil drive signal in the circumferential direction of the pipeline includes a time-varying electrical signal with current amplitude, phase angle, and harmonic components.

[0052] The compensation engine generates the compensation current intensity for the magnetic field distortion region based on the ratio of the spatial distribution gradient of the magnetic field intensity to the magnetic field gradient compensation threshold.

[0053] Furthermore, the compensation engine receives the spatial distribution gradient data of the magnetic field intensity and the magnetic field gradient compensation threshold. By comparing the magnetic field gradient compensation threshold, it calculates the gradient overshoot factor for each magnetic field distortion region. A compensation coefficient mapping relationship is set according to the linear interpolation method, and based on this relationship, a linear proportional transformation is used to convert the gradient overshoot factor into the corresponding compensation current intensity value.

[0054] Based on the amplitude of the interference harmonics, reverse harmonic components are injected into the excitation coil drive signal, and combined with the spatial distribution of the magnetic field distortion characteristics, the phase lag and phase angle are compensated by partition weighting to generate a spatially modulated excitation current waveform.

[0055] Furthermore, the acquired excitation coil drive signal is first subjected to spectral analysis to accurately identify the amplitude and phase information of each interference harmonic component. For each detected interference harmonic component, a reverse harmonic signal with equal amplitude but 180-degree phase difference is generated. After precise amplitude matching and phase calibration by a digital signal processor, the reverse harmonic signal is superimposed on the original excitation coil drive signal in real time to achieve effective cancellation of harmonic components. Simultaneously, based on the spatial distribution data of magnetic field distortion characteristics, the phase lag and phase angle data of each sector region divided by the pipe cross-section are independently measured. Based on the phase lag and phase angle data measured in each sector region, a phase compensation weighting coefficient is defined. The phase compensation weighting coefficient reflects the severity of magnetic field distortion in different regions and is used to determine the required phase compensation amount for each region. Using multi-channel digital signal synthesis technology, the precisely calibrated reverse harmonic components are integrated with the zone-weighted phase compensation amount, and precise synchronization and superposition with the basic excitation signal are achieved through programmable logic devices. The resulting spatially modulated excitation current waveform has dynamically adjustable spatial distribution characteristics, which can provide precise matching harmonic cancellation and phase compensation effects for specific magnetic field distortion characteristics in different regions of the pipeline.

[0056] Based on the compensation current intensity and spatially modulated excitation current waveform in the magnetic field distortion region, a three-phase current vector synthesis is performed using a spatial vector pulse width modulation algorithm to generate a partitioned compensation excitation magnetic field.

[0057] Furthermore, the compensation current intensity data and the spatially modulated excitation current waveform are input into a space vector pulse width modulation (SVM) algorithm. The SVM algorithm establishes the three-phase current vector relationship through coordinate transformation and calculates the target current parameters and conduction time of each phase winding. Power electronic switching devices precisely switch according to the PWM control signal, synthesizing three-phase currents with specific amplitudes and phases in the excitation coil. The three-phase currents generate differentiated magnetic field distributions in the pipe space, with their intensity and phase independently configured according to the distortion characteristics of each sector. The compensation magnetic field forms a precise mirror image of the original magnetic field distortion, neutralizing non-uniform components through vector superposition. The final generated partitioned compensation excitation magnetic field is then obtained.

[0058] S3. Based on the original electrode signal generated by the excitation magnetic field, obtain the uniformity index of the partitioned compensation excitation magnetic field, and dynamically configure the gate voltage of the ion channel to generate the purified voltage signal.

[0059] The original electrode signals after the application of the partitioned compensated excitation magnetic field were collected by quantum dot array, and the magnetic field intensity distribution characteristics of each sector region were extracted by STPA.

[0060] Furthermore, after preprocessing, the electrode signals acquired by the quantum dot array under the influence of the partitioned compensated excitation magnetic field are used to extract time-frequency domain features from the original electrode signals of each sector using a short-time phase analysis algorithm. First, the electrode signals are windowed and segmented, and the instantaneous phase information within each time window is calculated. The rate of change of magnetic field strength is obtained through phase differentiation. Simultaneously, the spectral characteristics of each frequency band are analyzed using Fast Fourier Transform to extract the amplitude and phase relationship of the fundamental and harmonic components. Spatiotemporal correlation analysis is then performed on the instantaneous phase features and spectral features to calculate the spatial gradient of magnetic field strength amplitude, phase difference, and harmonic spectral density of each sector, ultimately constituting the magnetic field strength distribution characteristics of each sector.

[0061] It should be noted that the preprocessing includes noise filtering, baseline correction and signal normalization of the electrode signals acquired by the quantum dot array. The specific process is as follows: first, a digital filter is used to eliminate high-frequency noise and power frequency interference; then, a moving average algorithm is used to remove signal baseline drift; and finally, the amplitude of each channel signal is normalized and calibrated according to a unified benchmark.

[0062] The characteristics of magnetic field intensity distribution include the spatial gradient of magnetic field intensity amplitude, phase difference, and harmonic spectral density;

[0063] Based on the magnetic field intensity distribution characteristics of each sector, the uniformity index of the compensation excitation magnetic field in each zone is calculated using the spatiotemporal differential-spectrum joint analysis method. The expression is as follows:

[0064]

[0065] Among them, Γ iIt is the uniformity index of the excitation magnetic field of the i-th sector region. is the spatial gradient of the magnetic field intensity amplitude in the i-th sector, A is the average magnetic field intensity amplitude of all sector regions, N is the total number of sector regions divided by the pipe cross-section, α is the weighting coefficient of the phase difference (range: 0.1-0.5), β is the weighting coefficient of the harmonic spectral density (range: 0.2-0.8), and Δφ ij H is the phase lag between the i-th and j-th sector regions. i H(f1) is the density of frequency f1 in the harmonic spectrum of the i-th sector, and H(f1) is the density reference of frequency f1 in the harmonic spectrum (the value range is 0.01-1.0). f1 represents the frequency in the harmonic spectrum.

[0066] Furthermore, the spatial gradient of the magnetic field intensity amplitude in each sector region is first obtained. Calculate the normalized gradient squared term based on the average magnitude A. Then determine the maximum phase lag between each sector region: max(|Δφ) ij |, multiplied by the phase difference weighting coefficient α; then the harmonic spectral density H of each region at the characteristic frequency f1 is extracted. i (f1) and the baseline density H i The normalized deviation of (f1) is multiplied by the harmonic weighting coefficient β; the sum of the three results is divided by the total number of sector regions N, and the square root is taken to obtain Γ. i The calculation process employs vector operations to process spatial gradient data, determines the maximum phase difference through extremum search, calculates the spectral density deviation using the L2 norm, and finally outputs the uniformity index of the compensated excitation magnetic field for each partition.

[0067] Based on the statistical distribution of historical magnetic field distortion data, low uniformity threshold Γ1 and high uniformity threshold Γ2 are defined.

[0068] When Γ i When Γ1 ≤ Γ1, decrease the current ion channel gate voltage; when Γ1 < Γ i When Γ ≤ Γ2, maintain the current ion channel gate voltage; when Γ i When ≥Γ2, increase the current ion channel gate voltage.

[0069] It should be noted that the process of defining the low uniformity threshold Γ1 and the high uniformity threshold Γ2 is as follows: The uniformity index Γ of each sector region accumulated during historical operation is... i The data were statistically analyzed, and the probability density distribution fitting method was used to determine Γ. iThe typical range of values ​​is determined by calculating the cumulative distribution function. The 30th percentile value is selected as the uniformity threshold Γ1, and the 80th percentile value is selected as the high uniformity threshold Γ2. The value range of the low uniformity threshold Γ1 is 0.15-0.35, and the value range of the high uniformity threshold Γ2 is 0.45-0.75.

[0070] By adjusting the ion channel gating voltage, harmonic filtering and timing calibration are performed on the original voltage signal to generate a purified voltage signal.

[0071] Furthermore, based on the uniformity index Γ i The judgment result dynamically adjusts the ion channel gate voltage, and an adaptive filtering algorithm is used to perform harmonic elimination and timing calibration on the original voltage signal. First, based on the adjusted gate voltage, bandpass filter parameters are set, and harmonic interference components in the specified frequency band are eliminated through a digital filter bank. Then, a timing calibration circuit is used to perform phase compensation on the filtered signal to correct the signal delay caused by magnetic field inhomogeneity. Finally, the processed multi-channel data is integrated into a continuous voltage waveform through a signal reconstruction unit, and the purified voltage signal is output.

[0072] S4. Construct a joint correlation prediction model and perform fusion analysis on the purified voltage signal and mechanical vibration data to obtain the initial water flow estimate.

[0073] Mechanical vibration data is collected using an accelerometer; the mechanical vibration data includes the time-domain waveform of the pipe surface vibration and the vibration energy intensity of each frequency band.

[0074] Based on the purified voltage signal and mechanical vibration data, state variables and observation variables are defined;

[0075] Furthermore, the amplitude parameters of the purified voltage signal after normalization are used as the main observation variables, including two sub-items: fundamental voltage amplitude and third harmonic voltage amplitude ratio. Mechanical vibration data, after feature extraction, forms vibration energy observation variables, including two sub-items: low-frequency band (0-100Hz) integral energy and resonant band (100-300Hz) peak energy. State variables are defined as dynamic parameters related to water flow velocity, including instantaneous flow velocity, rate of change of flow velocity, and fluid-structure interaction coefficient. A mapping relationship is established between the observation variables and state variables through measurement equations.

[0076] A state-space model is established based on state variables and observed variables using a particle filter algorithm.

[0077] Furthermore, a nonlinear state-space model is constructed using a particle filtering algorithm, initializing 300-600 particles to characterize the probability distribution of state variables. The state transition equation is established based on a simplified form of the Navier-Stokes equation, describing the coupling relationship between fluid inertia effects and pipe damping characteristics through a second-order differential equation. The specific expression includes the time derivative term and spatial gradient term of the flow velocity. In the observation update phase, the predicted values ​​of the observed variables corresponding to each particle are first calculated, including the fundamental amplitude of the purified voltage signal and the predicted values ​​of vibration energy intensity in each frequency band. The predicted values ​​are then matched with the time-domain waveform of pipe surface vibration measured by the accelerometer and the vibration energy intensity in each frequency band extracted by the fast Fourier transform. A system resampling strategy is used to update the particle weight distribution, retaining high-weight particles and discarding low-weight particles. The output of the state-space model includes the mean vector and covariance matrix of the estimated state variables, where the mean vector is obtained by the arithmetic mean of the weighted particle set, and the covariance matrix is ​​calculated through the particle dispersion. The entire process iteratively approximates the true state distribution of the particle set, ultimately forming a complete state-space model.

[0078] By combining the state-space model with the extended Kalman filter algorithm using variational Bayesian inference, a joint correlation prediction model is generated.

[0079] Furthermore, the state-space model output of the particle filter algorithm is used as the input to the extended Kalman filter algorithm, and the two algorithms are coupled through variational Bayesian inference. Within the variational Bayesian framework, the posterior distribution of the state variables is approximately decomposed into multiple independent factors, and state estimation and parameter estimation are alternately optimized. The extended Kalman filter algorithm handles the Gaussian part of the state variables, while the particle filter algorithm handles the non-Gaussian part. Joint optimization of the model parameters is achieved through maximizing the variational lower bound, ultimately generating a jointly correlated prediction model.

[0080] It should be noted that state estimation targets the dynamic characteristics of water flow velocity, including real-time numerical calculations of three dimensions: instantaneous velocity, rate of change of velocity, and fluid-structure interaction coefficient. Parameter estimation targets the fixed characteristic parameters in the state-space model, including the elements of the measurement equation coefficient matrix, the values ​​of the fluid inertia coefficient and pipe damping coefficient in the state transition equation, and the values ​​of each component in the process noise covariance matrix and the observation noise covariance matrix. The two types of estimation are iteratively optimized alternately within a variational Bayesian inference framework, together forming the complete parameter system of the joint correlation prediction model.

[0081] By using a joint correlation prediction model, the purified voltage signal and mechanical vibration data are fused and analyzed to obtain the initial water flow rate estimate, expressed as:

[0082] Q=g1·V+g2·∫E(f2)df+γ;

[0083] Where Q is the estimated initial water flow rate in the pipeline, g1 is the voltage signal weighting coefficient (range: 0.5-1.2), V is the purified voltage signal, g2 is the vibration energy intensity weighting coefficient (range: 0.1-0.5), E(f2) is the vibration energy spectral density value at frequency f2, and γ is the water flow rate deviation compensation constant (range: 0.3 to +0.3, unit: m). 3 / h)).

[0084] Furthermore, the purified voltage signal V output by the joint correlation prediction model is first acquired, and amplitude demodulation is performed on the voltage signal to obtain standardized voltage parameters. Simultaneously, mechanical vibration data collected by the accelerometer is extracted, and the integral value of the vibration energy spectral density E(f2) at the characteristic frequency f2 within a specified frequency band is calculated through frequency domain integration. The voltage component is obtained by multiplying the voltage signal weighting coefficient g1 with the purified voltage signal V, and the vibration component is obtained by multiplying the vibration energy intensity weighting coefficient g2 with the vibration energy integral value. The two components are added together, along with the water flow deviation compensation constant γ, to form the initial water flow estimate Q. During the calculation, the voltage signal weighting coefficient g1 and the vibration energy intensity weighting coefficient g2 are obtained by training the joint correlation prediction model based on historical data, and the water flow deviation compensation constant γ is determined through zero-point calibration under no-flow conditions. The final output initial water flow estimate Q contains fused information from the voltage signal and mechanical vibration data, achieving collaborative measurement of multiple physical quantities.

[0085] S5. Through dynamic temperature compensation and zero-point online calibration, the initial water flow estimate is corrected for error, and a high-confidence water flow value is generated.

[0086] Real-time pipe wall temperature data is collected using a PT100 temperature sensor, and the initial water flow estimate is compensated for temperature drift using a linear interpolation compensation method to generate a temperature-compensated water flow estimate.

[0087] Furthermore, the PT100 temperature sensor collects pipe outer wall temperature data at a fixed sampling period, which is then converted into digital temperature values ​​by a signal conditioning circuit. Based on a pre-stored standard temperature-flow characteristic curve, a linear interpolation compensation method is used to calculate the flow compensation amount corresponding to the current temperature. The initial estimated water flow rate Q is added to the temperature compensation amount to obtain the temperature-compensated estimated water flow rate. The linear interpolation compensation method establishes a local linear relationship based on adjacent temperature calibration points, and calculates the flow rate reading deviation caused by temperature changes in real time. The temperature compensation process considers the sensor's thermal response time constant and uses digital filtering to eliminate temperature measurement noise, ensuring compensation accuracy. The final output temperature-compensated estimated water flow rate eliminates the influence of ambient temperature changes on the measurement results.

[0088] In a stagnant state (where the water flow in the pipe is completely still), based on the estimated water flow rate after temperature compensation, a baseline drift correction algorithm is used to identify the zero-point offset, and then corrected by exponential weighted dynamic decay to generate a high-confidence water flow rate value.

[0089] Furthermore, with the water flow completely still in the pipe, the estimated water flow rate after temperature compensation is recorded as the zero-point offset. The baseline drift correction algorithm establishes a dynamic benchmark for the drift by statistically analyzing the average and standard deviation of the zero-point offset using a sliding time window. An exponentially weighted dynamic decay method is used to process historical drift data, assigning higher weights to recent data to calculate the real-time drift correction value. Subtracting the drift correction value from the temperature-compensated estimated water flow rate yields a high-confidence water flow rate value with zero-point offset eliminated. During the correction process, the exponential weighting coefficient is adaptively adjusted according to the drift change rate, ensuring rapid response to sudden drifts while maintaining long-term stability. The final output high-confidence water flow rate value exhibits optimized zero-point stability and measurement repeatability.

[0090] This embodiment also provides a computer device applicable to the high-precision measurement method of electromagnetic water meters using intelligent sensors, including: a memory and a processor; the memory is used to store computer-executable instructions, and the processor is used to execute the computer-executable instructions to realize the high-precision measurement method of electromagnetic water meters using intelligent sensors as proposed in the above embodiment.

[0091] The computer device can be a terminal, comprising a processor, memory, communication interface, display screen, and input devices connected via a system bus. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, carrier networks, NFC (Near Field Communication), or other technologies. The display screen can be an LCD screen or an e-ink screen. The input devices can be a touch layer covering the display screen, buttons, a trackball, or a touchpad on the computer device's casing, or an external keyboard, touchpad, or mouse.

[0092] This embodiment also provides a storage medium storing a computer program. When executed by a processor, the program implements the high-precision measurement method for electromagnetic water meters using smart sensors as proposed in the above embodiments. The storage medium can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as Static Random Access Memory (SRAM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Erasable Programmable Read Only Memory (EPROM), Programmable Red-Only Memory (PROM), Read-Only Memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.

[0093] In summary, this invention achieves precise control of the magnetic field distribution across the pipe cross section by employing a compensation engine combined with a space vector pulse width modulation algorithm to dynamically generate a partitioned compensated excitation magnetic field that matches the characteristics of magnetic field distortion. This effectively eliminates the problem of magnetic field inhomogeneity caused by edge effects and interference from ferromagnetic materials. Furthermore, it calculates the magnetic field uniformity index of each sector region in real time using a spatiotemporal differential-spectrum joint analysis method, and dynamically adjusts the ion channel gate voltage accordingly. This enables adaptive suppression of harmonic interference and timing errors in the electrode signal, improving signal purity and measurement stability.

[0094] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.

Claims

1. A high-precision measurement method of an electromagnetic water meter using a smart sensor, characterized in that: include, The quantum tunneling current signal in the circumferential direction of the pipeline was collected, and the magnetic field distortion characteristics were extracted. The magnetic field distortion characteristics include the spatial distribution gradient of the magnetic field intensity within the pipe, the amplitude of interference harmonics, and the phase lag. Based on the characteristics of magnetic field distortion, a compensation engine is used to calculate the compensation current intensity of each pipeline area. Combined with the spatial distribution of magnetic field distortion characteristics, a spatial vector pulse width modulation algorithm is used to generate a partitioned compensation excitation magnetic field. The calculation of the compensation current intensity of each pipeline region using the compensation engine refers to defining the magnetic field gradient compensation threshold, identifying the magnetic field distortion region on the pipeline interface where the rate of change of magnetic field intensity exceeds the magnetic field gradient compensation threshold, and generating the compensation current intensity of the magnetic field distortion region by means of the compensation engine according to the ratio of the spatial distribution gradient of magnetic field intensity to the magnetic field gradient compensation threshold. The spatial distribution of magnetic field distortion characteristics is used to generate a partitioned compensation excitation magnetic field through a spatial vector pulse width modulation algorithm. The steps are as follows: Real-time acquisition of excitation coil drive signals along the circumference of the pipeline; Based on the amplitude of the interference harmonics, reverse harmonic components are injected into the excitation coil drive signal, and combined with the spatial distribution of magnetic field distortion characteristics, the phase lag and phase angle are compensated by partition weighting to generate a spatially modulated excitation current waveform. Based on the compensation current intensity and spatial modulation excitation current waveform in the magnetic field distortion region, three-phase current vector synthesis is performed using a spatial vector pulse width modulation algorithm to generate a partitioned compensation excitation magnetic field. Based on the original electrode signal generated by the excitation magnetic field, the uniformity index of the partitioned compensation excitation magnetic field is obtained, and the gate voltage of the ion channel is dynamically configured to generate the purified voltage signal. A joint correlation prediction model was constructed, and the purified voltage signal and mechanical vibration data were fused and analyzed to obtain the initial water flow estimate. By using dynamic temperature compensation and online zero-point calibration, the initial water flow estimate is corrected for errors, generating a high-confidence water flow value.

2. The electromagnetic water meter high-precision measurement method with intelligent sensors according to claim 1, characterized in that: The acquisition of the uniformity index of the partitioned compensation excitation magnetic field refers to collecting the original electrode signal after the partitioned compensation excitation magnetic field is applied, extracting the magnetic field intensity distribution characteristics of each sector region through STPA, and calculating the uniformity index of the partitioned compensation excitation magnetic field through the spatiotemporal differential-spectrum joint analysis method.

3. The high-precision measurement method for electromagnetic water meters using intelligent sensors as described in claim 2, characterized in that: The steps for dynamically configuring the gate voltage of the ion channel to generate the purified voltage signal are as follows. Define low uniformity threshold and high uniformity threshold, and compare them with the uniformity index of the excitation magnetic field of each partition. Based on the comparison results, dynamically configure the gate voltage of the ion channel. By adjusting the ion channel gating voltage, harmonic filtering and timing calibration are performed on the original voltage signal to generate a purified voltage signal.

4. The high-precision measurement method for electromagnetic water meters using intelligent sensors as described in claim 1, characterized in that: The steps for constructing a joint correlation prediction model and fusing and analyzing the purified voltage signal and mechanical vibration data to obtain an initial water flow estimate are as follows. Based on the purified voltage signal and mechanical vibration data, state variables and observation variables are defined, and a state-space model is established using a particle filter algorithm. By combining the state-space model with the extended Kalman filter algorithm using variational Bayesian inference, a joint correlation prediction model is generated. By using a joint correlation prediction model, the purified voltage signal and mechanical vibration data are fused and analyzed to obtain an initial water flow estimate.

5. The high-precision measurement method for electromagnetic water meters using intelligent sensors as described in claim 1, characterized in that: The process involves correcting errors in the initial water flow estimate through dynamic temperature compensation and online zero-point calibration to generate a high-confidence water flow value. The steps are as follows: Real-time pipe wall temperature data is collected, and the initial water flow estimate is compensated for temperature drift using a linear interpolation method to generate a temperature-compensated water flow estimate. In a stagnant state, based on the temperature-compensated water flow estimate, a baseline drift correction algorithm is used to identify the zero-point offset, which is then corrected by exponentially weighted dynamic decay to generate a high-confidence water flow value.

6. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, it implements the steps of the high-precision measurement method for electromagnetic water meters using intelligent sensors as described in any one of claims 1 to 5.

7. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by the processor, it implements the steps of the high-precision measurement method for electromagnetic water meters using intelligent sensors as described in any one of claims 1 to 5.