A method, apparatus, device and medium for determining ultrasonic wave conduction time
Patent Information
- Application Number
- CN202610984410.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-02
- Publication Date
- 2026-09-29
AI Technical Summary
[0004]本申请实施例提供了一种超声波传导时间的确定方法、装置、设备及介质,可以解决现有超声波传导时间提取方法由于采用单一固定提取算法,导致复杂流体工况下测量精度差、稳定性不足的技术问题
本申请实施例提供一种超声波传导时间的确定方法,包括:首先,若检测超声波流量计以预设信号参数向目标流体发射多个超声波激励信号,获取多个超声波激励信号对应的组合回波信号。然后,对组合回波信号进行波形特征提取处理,得到回波特征信息,其中,回波特征信息用于指示组合回波信号的回波波形具备的回波特征,不同的回波特征对应不同的传导时间提取方式。最后,根据回波特征信息对应的传导时间提取方式,确定超声波激励信号的传导时间。通过动态分析回波波形特征并自适应选择传导时间提取方式,有效克服了传统固定阈值法在复杂工况下的误判问题,显著提升了低信噪比环境下的测量可靠性。
Smart Images

Figure CN122835501A_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of flow measurement technology, and in particular relates to a method, apparatus, equipment and medium for determining ultrasonic wave transmission time. Background Technology
[0002] Currently, time-of-flight ultrasonic flow meters are widely used and technologically mature non-contact measuring instruments in the field of industrial flow measurement. Their core principle relies on calculating flow velocity and volumetric flow rate based on the time difference between the propagation of ultrasonic waves in the fluid's upstream and downstream directions. Ultrasonic waves propagate faster and for a shorter time in the downstream direction, while they propagate slower and for a longer time in the upstream direction. Accurately obtaining this propagation time directly determines the flow meter's measurement accuracy and long-term stability.
[0003] In practical industrial applications, ultrasonic signals propagate through fluids and are reflected by multiple media interfaces. The echo signals captured by the receiving transducer often exhibit weak and complex characteristics due to environmental interference. However, existing ultrasonic propagation time extraction methods, due to their use of a single fixed extraction algorithm, suffer from poor measurement accuracy and insufficient stability under complex fluid conditions. Summary of the Invention
[0004] This application provides a method, apparatus, device, and medium for determining ultrasonic wave propagation time, which can solve the technical problem that existing ultrasonic wave propagation time extraction methods suffer from poor measurement accuracy and insufficient stability under complex fluid conditions due to the use of a single fixed extraction algorithm.
[0005] In a first aspect, embodiments of this application provide a method for determining the ultrasonic wave conduction time, the method comprising: If the ultrasonic flow meter emits multiple ultrasonic excitation signals to the target fluid with preset signal parameters, the combined echo signal corresponding to the multiple ultrasonic excitation signals is obtained. The combined echo signal is subjected to waveform feature extraction processing to obtain echo feature information, wherein the echo feature information is used to indicate the echo characteristics of the echo waveform of the combined echo signal, and different echo characteristics correspond to different conduction time extraction methods; The propagation time of the ultrasonic excitation signal is determined based on the propagation time extraction method corresponding to the echo feature information.
[0006] In one possible implementation of the first aspect, the preset signal parameters include at least one of the following: transmission frequency, pulse amplitude, signal pulse width, and number of pulses.
[0007] In one possible implementation of the first aspect, the step of detecting if the ultrasonic flow meter emits multiple ultrasonic excitation signals to the target fluid with preset signal parameters and acquiring a combined echo signal corresponding to the multiple ultrasonic excitation signals includes: When the ultrasonic flow meter is detected to emit multiple ultrasonic excitation signals toward the target fluid with preset signal parameters, the echo signal corresponding to each ultrasonic excitation signal is received. The gain coefficient of each echo signal is determined based on the echo characteristic information of each echo signal. The combined echo signal is obtained by sequentially weighting and superimposing the gain coefficients of each echo signal.
[0008] In one possible implementation of the first aspect, the waveform feature extraction processing of the combined echo signal to obtain echo feature information includes: Time-domain waveform analysis is performed on the combined echo signal to extract echo characteristic parameters from the echo waveform of the combined echo signal. The echo feature information is generated based on the extracted echo feature parameters.
[0009] In one possible implementation of the first aspect, before determining the propagation time of the ultrasonic excitation signal based on the propagation time extraction method corresponding to the echo feature information, the method includes: If the echo feature information shows that the combined echo signal has an envelope abrupt change inflection point feature, then the conduction time extraction method is determined to be the envelope abrupt change inflection point method. If the echo feature information shows that the combined echo signal contains a preset number of echo oscillation interference features, then the conduction time extraction method is determined to be the maximum kurtosis method.
[0010] In one possible implementation of the first aspect, when the conduction time extraction method is determined to be the signal maximum kurtosis method, determining the conduction time of the ultrasonic excitation signal based on the conduction time extraction method corresponding to the echo feature information includes: The combined echo signal is smoothed and filtered to obtain the processed combined echo signal; The echo waveforms of the processed combined echo signal are traversed along the time domain using a sliding window, and the statistical characteristic values of the echo waveforms of the processed combined echo signal are calculated window by window. Based on the statistical feature value corresponding to each window, a full waveform kurtosis sequence corresponding to the echo waveform of the processed combined echo signal is generated. Based on the kurtosis peak value in the full waveform kurtosis sequence, interpolation fitting is performed on the neighborhood data of the kurtosis peak value to determine the time domain point corresponding to the kurtosis peak value; The propagation time of the ultrasonic excitation signal is determined based on the time-domain point corresponding to the kurtosis peak.
[0011] In one possible implementation of the first aspect, when the conduction time extraction method is determined to be the envelope abrupt change inflection point method, determining the conduction time of the ultrasonic excitation signal based on the conduction time extraction method corresponding to the echo feature information includes: The Hilbert transform is performed on the echo waveform of the combined echo signal to obtain the envelope curve of the echo waveform; The envelope curve is smoothed by a smoothing filter to obtain a smoothed envelope curve; The smoothed envelope curve is slid-differentiated along the time domain to generate the slope sequence corresponding to the smoothed envelope curve; Based on the extreme values of the slope in the slope sequence, interpolation fitting is performed on the neighborhood data of the extreme values of the slope to determine the time-domain point corresponding to the extreme values of the slope; The propagation time of the ultrasonic excitation signal is determined based on the time-domain point corresponding to the extreme value of the slope.
[0012] Secondly, embodiments of this application provide a device for determining the ultrasonic wave conduction time, comprising: The acquisition module is used to acquire the combined echo signal corresponding to the multiple ultrasonic excitation signals if the ultrasonic flow meter emits multiple ultrasonic excitation signals to the target fluid with preset signal parameters. The extraction module is used to perform waveform feature extraction processing on the combined echo signal to obtain echo feature information, wherein the echo feature information is used to indicate the echo characteristics of the echo waveform of the combined echo signal, and different echo characteristics correspond to different conduction time extraction methods. The determination module is used to determine the propagation time of the ultrasonic excitation signal based on the propagation time extraction method corresponding to the echo feature information.
[0013] Thirdly, embodiments of this application provide a terminal device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the method for determining the ultrasonic wave conduction time described in any of the above claims.
[0014] Fourthly, embodiments of this application provide a computer-readable storage medium storing a computer program that, when executed by a processor, implements the method for determining the ultrasonic wave conduction time described in any of the preceding claims.
[0015] Fifthly, embodiments of this application provide a computer program product that, when run on a terminal device, causes the terminal device to execute the method for determining the ultrasonic wave conduction time described in any one of the first aspects.
[0016] The beneficial effects of the embodiments in this application compared with the prior art are: This application provides a method for determining the ultrasonic wave propagation time, comprising: first, detecting an ultrasonic flow meter that emits multiple ultrasonic excitation signals to a target fluid with preset signal parameters, and acquiring combined echo signals corresponding to the multiple ultrasonic excitation signals. Then, performing waveform feature extraction processing on the combined echo signals to obtain echo feature information, wherein the echo feature information indicates the echo characteristics possessed by the echo waveform of the combined echo signals, and different echo characteristics correspond to different propagation time extraction methods. Finally, determining the propagation time of the ultrasonic excitation signal based on the propagation time extraction method corresponding to the echo feature information. By dynamically analyzing the echo waveform characteristics and adaptively selecting the propagation time extraction method, the method effectively overcomes the misjudgment problem of the traditional fixed threshold method under complex working conditions, and significantly improves the measurement reliability in low signal-to-noise ratio environments. Attached Figure Description
[0017] To more clearly illustrate the technical solutions in the embodiments of this application, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0018] Figure 1 This is a schematic diagram of the structure of a system for determining ultrasonic wave conduction time according to an embodiment of this application; Figure 2 This is a flowchart illustrating a method for determining ultrasonic wave conduction time according to an embodiment of this application. Figure 3 This is a schematic flowchart of an embodiment of the present application for obtaining a combined echo signal; Figure 4 This is a waveform diagram of an echo signal provided in an embodiment of this application; Figure 5 This is a flowchart illustrating a method for determining ultrasonic wave conduction time according to another embodiment of this application; Figure 6 This is a schematic flowchart illustrating how to determine the propagation time of an ultrasonic excitation signal using the maximum kurtosis method, according to an embodiment of this application. Figure 7This is a schematic diagram of process data for determining conduction time using the maximum kurtosis method of a signal, provided in an embodiment of this application; Figure 8 This is a schematic flowchart illustrating how to determine the propagation time of an ultrasonic excitation signal using the envelope abrupt change inflection point method, according to an embodiment of this application. Figure 9 This is a schematic diagram of process data for determining conduction time using the envelope abrupt change inflection point method, provided in an embodiment of this application. Figure 10 This is a schematic diagram of the structure of a device for determining ultrasonic wave conduction time according to an embodiment of this application; Figure 11 This is a schematic diagram of the structure of a terminal device provided in an embodiment of this application. Detailed Implementation
[0019] In the following description, specific details such as particular system architectures and techniques are set forth for illustrative purposes and not for limitation, in order to provide a thorough understanding of the embodiments of this application. However, those skilled in the art will understand that this application may also be implemented in other embodiments without these specific details. In other instances, detailed descriptions of well-known systems, apparatuses, circuits, and methods have been omitted so as not to obscure the description of this application with unnecessary detail.
[0020] It should be understood that, when used in this application specification and the appended claims, the term "comprising" indicates the presence of the described features, integrals, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components and / or a collection thereof.
[0021] It should also be understood that the term “and / or” as used in this application specification and the appended claims means any combination of one or more of the associated listed items and all possible combinations, and includes such combinations.
[0022] As used in this application specification and the appended claims, the term "if" may be interpreted, depending on the context, as "when," "once," "in response to determination," or "in response to detection." Similarly, the phrase "if determined" or "if detected [the described condition or event]" may be interpreted, depending on the context, as meaning "once determined," "in response to determination," "once detected [the described condition or event]," or "in response to detection [the described condition or event]."
[0023] Furthermore, in the description of this application and the appended claims, the terms "first," "second," "third," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0024] References to "one embodiment" or "some embodiments" as described in this specification mean that one or more embodiments of this application include a specific feature, structure, or characteristic described in connection with that embodiment. Therefore, the phrases "in one embodiment," "in some embodiments," "in other embodiments," "in still other embodiments," etc., appearing in different parts of this specification do not necessarily refer to the same embodiment, but rather mean "one or more, but not all, embodiments," unless otherwise specifically emphasized. The terms "comprising," "including," "having," and variations thereof mean "including but not limited to," unless otherwise specifically emphasized.
[0025] Ultrasonic flow meters utilize the propagation characteristics of ultrasound in fluids, allowing for flow measurement without cutting pipes or contacting the fluid. The transducer is directly clamped to the outer wall of the pipe. The development of ultrasonic flow meters benefits from the maturity of piezoelectric ceramic materials, precision electronic timing technology, and digital signal processing technology. This makes it possible to accurately extract weak ultrasonic signals from complex noise backgrounds and calculate minute time differences and propagation times, thus solving problems associated with traditional flow meters, such as complex installation and maintenance, pressure loss, and wear of moving parts.
[0026] Currently, time-of-flight ultrasonic flow meters are among the most widely used and technologically mature non-contact measuring instruments in the field of industrial flow measurement. The core measurement principle of time-of-flight ultrasonic flow meters is as follows: ultrasonic signals propagate in the fluid along both the forward and reverse flow directions. Ultrasonic waves propagate faster and for a shorter time in the forward direction, and slower and for a longer time in the reverse direction. By measuring the time difference between the forward and reverse propagation directions, the fluid velocity and volumetric flow rate can be calculated. Therefore, the accurate acquisition of the ultrasonic wave propagation time directly determines the measurement accuracy and stability of the flow meter. However, in actual industrial applications, during the process of ultrasonic waves propagating in the fluid and being reflected by multiple media interfaces before being captured by the receiving transducer, the received echo signals are often very weak and accompanied by complex interference, leading to the following technical defects in existing propagation time extraction methods: (i) Single detection algorithms are ill-suited to complex and variable fluid conditions. Traditional ultrasonic flow meters typically use fixed threshold or cross-correlation methods to detect propagation time. A fixed voltage threshold is preset as the basis for feature point determination; when the echo pulse amplitude exceeds this preset threshold, the corresponding time is recorded. However, once set, the preset voltage threshold remains unchanged. In actual measurement, fluctuations in the received signal due to changes in the external environment can severely affect the accuracy of the time difference measurement. Simultaneously, ultrasonic echo signals are highly susceptible to temperature, pressure, and the transducer's own characteristics during propagation. Traditional dual-threshold methods are also prone to misjudging feature points under specific conditions. Furthermore, detection methods relying solely on amplitude characteristics have a fundamental flaw: different algorithms have varying sensitivities to waveform distortion, and a single algorithm cannot maintain optimal performance under all field conditions. When bubbles, impurities, or drastic changes in flow velocity occur in the fluid, the echo waveform may be significantly distorted, which traditional fixed algorithms struggle to adapt to, often resulting in whole-cycle jumps or large fluctuations in the propagation time measurement. It is evident that existing methods lack the ability to adaptively select the optimal algorithm based on echo characteristics, which limits the robustness of ultrasonic flow meters under harsh operating conditions.
[0027] (II) Severe attenuation of ultrasonic signals under harsh fluid conditions and excessively low signal-to-noise ratio make propagation time extraction difficult. When ultrasonic waves propagate in fluids, especially in gaseous media or two-phase fluids containing bubbles and impurities, energy attenuation is extremely severe, resulting in weak amplitude of received echo signals and extremely low signal-to-noise ratio (SNR). Furthermore, existing technologies have failed to provide systematic and effective solutions to key technical issues such as how to automatically match the optimal algorithm to the composite echo signal after reverberation interference removal, and how to accurately locate the arrival time of ultrasonic waves using higher-order statistical features (such as kurtosis).
[0028] Therefore, there is an urgent need for a propagation time acquisition method that can integrate adaptive signal enhancement and multi-algorithm fusion to overcome the shortcomings of the existing technologies.
[0029] Please see Figure 1 , Figure 1 This is a schematic diagram of a system for determining ultrasonic conduction time according to an embodiment of this application. The method for determining ultrasonic conduction time in an ultrasonic flowmeter provided in this application is applied to a system for determining ultrasonic conduction time, such as... Figure 1As shown, the ultrasonic wave propagation time determination system 1 consists of a control unit 10, a drive circuit 20, a filter circuit 30, an amplifier circuit 40, and two ultrasonic transducers A and B installed on the fluid pipeline. During the ultrasonic flowmeter measurement process, the control unit 10 first sends an ultrasonic excitation signal to the drive circuit 20, which generates a high-voltage pulse signal to excite one of the transducers (e.g., ultrasonic transducer A) to emit ultrasonic waves. After passing through the fluid, the ultrasonic wave is received by the transducer on the other side (e.g., ultrasonic transducer B). The received weak echo signal is filtered by the filter circuit 30 and amplified by the amplifier circuit 40, and finally converted into a digital signal by the analog-to-digital converter (ADC) and sent to the control unit 10 for processing. The entire transmission and reception process alternates between measurements in both the forward and reverse directions. The control unit 10 records the time difference between the emitted pulse and the received echo characteristic point, and combines this with pre-calibrated parameter compensation (e.g., the propagation time of the ultrasonic wave in the acoustic wedge, pipe wall, etc.) to accurately calculate the propagation time of the ultrasonic wave in the fluid, which is then used for calculating the flow velocity and flow rate.
[0030] Please see Figure 2 , Figure 2 This is a schematic flowchart illustrating a method for determining ultrasonic wave propagation time according to an embodiment of this application. As an example and not a limitation, this method can be applied to or operated in a control unit of an ultrasonic wave propagation time determination system. The method includes: S11. If the ultrasonic flow meter emits multiple ultrasonic excitation signals to the target fluid with preset signal parameters, the combined echo signal corresponding to the multiple ultrasonic excitation signals is obtained.
[0031] S12. Perform waveform feature extraction processing on the combined echo signal to obtain echo feature information. The echo feature information is used to indicate the echo characteristics of the echo waveform of the combined echo signal. Different echo characteristics correspond to different propagation time extraction methods.
[0032] S13. Determine the propagation time of the ultrasonic excitation signal based on the propagation time extraction method corresponding to the echo characteristic information.
[0033] The target fluid is the medium being measured, commonly including flowing media such as water, oil, and industrial gases in pipelines. The ultrasonic excitation signal refers to the signal emitted by the transducer (e.g., ultrasonic flowmeter) of the ultrasonic flowmeter. Figure 1 The ultrasonic transducer A in the image emits ultrasonic pulses into the target fluid. The ultrasonic excitation signal propagates in the target fluid and is received by the receiving transducer (e.g., [missing information]). Figure 1 The ultrasonic transducer B in the middle receives the signal.
[0034] A combined echo signal refers to a comprehensive echo signal formed by processing and combining multiple echo signals received after an ultrasonic flow meter emits multiple ultrasonic excitation signals. This combined echo signal can provide more stable and representative waveform information.
[0035] Echo feature information can be understood as data obtained by analyzing and extracting the waveforms of combined echo signals. This echo feature information is used to describe specific waveform characteristics of the combined echo signal, such as signal strength, shape, noise level, or the presence of anomalies.
[0036] Transmission time refers to the time required for an ultrasonic excitation signal to travel from transmission to reception. Accurately determining the transmission time is crucial for ultrasonic flow meters to accurately measure fluid velocity. Transmission time extraction methods refer to the specific algorithms or methods used to determine the ultrasonic transmission time from the echo signal. Different echo signal characteristics may require different extraction methods to ensure the accuracy of the transmission time determination.
[0037] This embodiment provides a method for determining ultrasonic wave propagation time, aiming to improve the measurement accuracy and stability of ultrasonic flow meters under complex and variable fluid conditions. First, if it is detected that the ultrasonic flow meter periodically emits multiple ultrasonic excitation signals to the target fluid with preset signal parameters, the combined echo signal corresponding to these multiple ultrasonic excitation signals is acquired. The preset signal parameters are configurable transmission parameters for generating the ultrasonic excitation signals, and are discrete configuration items pre-stored in the control unit. The preset signal parameters may include at least one of the following: transmission frequency, pulse amplitude, signal pulse width, and number of pulses.
[0038] In practical applications, ultrasonic flow meters can continuously or periodically emit a series of ultrasonic pulses towards the target fluid. For example, the ultrasonic flow meter can be set to emit ultrasonic excitation signals at a frequency of 100 times per second, or it can be set to emit ultrasonic excitation signals with a preset pulse amplitude. At the receiving end, these continuously received echo signals can be simply accumulated to form a combined echo signal, or each received echo signal can be simply normalized in amplitude before being superimposed to obtain the combined echo signal. By emitting multiple ultrasonic excitation signals and obtaining combined echo signals, a richer data foundation can be provided for subsequent signal processing.
[0039] After acquiring the combined echo signal, waveform feature extraction is performed to obtain echo feature information. This echo feature information indicates the echo characteristics of the combined echo signal waveform; different echo characteristics correspond to different propagation time extraction methods. For example, a preliminary analysis of the combined echo signal waveform can be performed, such as calculating the ratio of its peak amplitude to the average noise level, to roughly determine the signal strength. If this ratio is higher than a certain preset threshold, the signal strength is considered high; conversely, it is considered low. Furthermore, the integrity of the waveform or the presence of multipath effects can be preliminarily determined by observing whether the combined echo signal waveform exhibits a distinct single main peak or multiple dispersed peaks. These preliminary judgments can be used as part of the echo feature information to indicate the basic characteristics of the waveform.
[0040] Finally, the propagation time of the ultrasonic excitation signal is determined based on the propagation time extraction method corresponding to the extracted echo feature information. For example, if the echo feature information indicates a "clear waveform," a method based on signal start point detection can be selected, such as determining the propagation time when the signal amplitude first reaches 5% of its peak amplitude. If the echo feature information indicates a "distorted waveform," a method with strong robustness to waveform distortion is selected, such as determining the propagation time by calculating the energy center or centroid of the waveform. Through this adaptive selection mechanism, even if changes in fluid conditions lead to a decrease in echo waveform quality, the algorithm most suitable for the current waveform characteristics can be selected to determine the propagation time.
[0041] It should be understood that this embodiment, by extracting waveform features from the combined echo signals, can perceive the quality, integrity, or presence of interference in the echo waveform in real time, thereby obtaining echo characteristic information characterizing the waveform properties. Based on this real-time updated characteristic information, the most suitable conduction time extraction method for the current echo waveform characteristics can be intelligently selected. This strategy of dynamically adjusting the conduction time extraction method according to echo characteristic information enables the ultrasonic flowmeter to maintain high measurement accuracy and stability even under harsh fluid conditions, effectively solving the problem that single detection algorithms in existing technologies are difficult to adapt to complex and variable fluid conditions, and significantly improving the adaptability and reliability of the flowmeter.
[0042] In one possible implementation, if the ultrasonic flow meter emits multiple ultrasonic excitation signals to the target fluid with preset signal parameters, and acquires a combined echo signal corresponding to the multiple ultrasonic excitation signals, the method includes: When the ultrasonic flow meter is detected to emit multiple ultrasonic excitation signals to the target fluid with preset signal parameters, the echo signal corresponding to each ultrasonic excitation signal is received. The gain coefficient of each echo signal is determined based on the echo characteristic information of each echo signal. The combined echo signal is obtained by weighting and superimposing the gain coefficients of each echo signal sequentially.
[0043] In some examples, when an ultrasonic flow meter is detected to be emitting multiple ultrasonic excitation signals to a target fluid with preset signal parameters, the acoustic response of the ultrasonic excitation signals after propagation and reflection in the target fluid is first captured. Then, based on the echo characteristic information of each echo signal, a gain coefficient for each echo signal is determined to evaluate the quality or intensity of each echo signal, and a weighting factor is assigned to that echo signal based on the gain coefficient. For example, time-domain or frequency-domain analysis can be performed on each echo signal to extract its echo characteristics such as signal-to-noise ratio, peak amplitude, energy, waveform integrity, or distortion. Based on these echo characteristic information, preset rules or adaptive algorithms can be used to calculate the corresponding gain coefficient. For example, echo signals with high signal-to-noise ratio and complete waveforms can be assigned a larger gain coefficient, while echo signals with low signal-to-noise ratio and severe waveform distortion are assigned a smaller gain coefficient to reduce their negative impact on the final combined signal.
[0044] Finally, the combined echo signal is obtained by sequentially weighting and superimposing the gain coefficients of each echo signal. This involves effectively fusing multiple quality-assessed and weighted echo signals to generate a combined echo signal with a higher signal-to-noise ratio and a clearer waveform. In practice, each sampling point of each echo signal can be multiplied by its corresponding gain coefficient, and then all weighted echo signals can be summed point-by-point in the time domain. This weighted superposition process highlights the contribution of high-quality signals while suppressing interference from low-quality signals, thereby improving the overall quality of the combined echo signal and enabling it to more accurately reflect the propagation characteristics of ultrasound in fluids.
[0045] In some examples, such as Figure 3 As shown, Figure 3 This is a schematic flowchart illustrating the acquisition of combined echo signals according to an embodiment of this application. Figure 3This paper describes the process of obtaining a combined echo signal by periodically emitting multiple ultrasonic excitation signals with different preset signal parameters into a target fluid and then accumulating the signals. In some examples, the combined echo signal can be obtained by periodically emitting different emission frequencies and accumulating the signals, which facilitates the extraction of the propagation time. The entire process begins with a loop structure, emitting an ultrasonic excitation signal at a specific emission frequency, then changing the emission frequency of the ultrasonic excitation signal and proceeding to the next round. For each echo signal corresponding to the emitted ultrasonic excitation signal, the echo signal is processed to obtain the gain coefficient of the echo signal in the entire combined waveform, and then the echo signal is accumulated into a total composite signal. This accumulation process is controlled by a counter (i++, where i is the counter value) and a condition (whether i is greater than a preset value N) to control the loop until the accumulation of N different ultrasonic excitation signals and echo signals has been completed. The loop ends, at which point a combined echo signal after multiple accumulations is obtained.
[0046] The core objective of this cumulative processing method is to emit a series of ultrasonic excitation signals with varying transmission frequencies into the target fluid, collect the echo signals at each transmission frequency, and finally superimpose these echo signals. Compared to using a single-frequency ultrasonic excitation signal, this cumulative processing method has the following advantages: First, this accumulation processing method can effectively enhance the energy of the effective signal, while allowing random noise to be relatively weakened due to phase inconsistency during multiple accumulations, thereby significantly improving the signal-to-noise ratio of the final waveform signal. A clear waveform with a higher signal-to-noise ratio is an important prerequisite for the subsequent accurate extraction of ultrasonic wave propagation time.
[0047] Secondly, in fluids containing bubbles, the degree to which ultrasonic waves of different frequencies are affected by bubble scattering and attenuation varies significantly. At certain transmission frequencies, the echo waveform is severely distorted or even lost, while at other frequencies, it can penetrate the fluid relatively completely. Utilizing this frequency selectivity, by traversing excitation signals of different transmission frequencies, we can identify and filter out the "dominant transmission frequencies" that are less affected by bubbles. During the accumulation process, these dominant transmission frequency echo signals are given higher gain or weight, while the contribution of severely interfered echo signals is reduced. This accumulation strategy, which dynamically adjusts the gain based on the degree of influence, allows the final synthesized combined waveform signal to retain the most effective propagation information while suppressing waveform distortion caused by bubbles and the oscillation location of spurious echoes.
[0048] In some examples, combined echo signals can be obtained by periodically transmitting different pulse amplitudes and accumulating the signals, thus facilitating the extraction of propagation time. First, a loop structure is entered, transmitting an ultrasonic excitation signal with a preset pulse amplitude. Then, the pulse amplitude of the ultrasonic excitation signal is changed, and the next round of transmission begins (while other preset signal parameters such as transmission frequency and pulse width remain unchanged). For each echo signal corresponding to the transmitted ultrasonic excitation signal, the echo signal is processed, and the gain coefficient of the echo signal in the entire combined waveform is obtained. Then, the echo signal is accumulated into a total composite signal. Similar to the accumulation process described above, this accumulation process can be controlled by a counter and a conditional decision to loop until the accumulation of ultrasonic excitation signals and echo signals with multiple different pulse amplitudes is completed. The loop ends, at which point a combined echo signal after multiple accumulations is obtained.
[0049] It should be understood that by emitting a series of ultrasonic excitation signals with varying pulse amplitudes to the target fluid, collecting the echo signals at each pulse amplitude, and finally superimposing these echo signals, this accumulation processing method has the following advantages compared to using ultrasonic excitation signals with fixed pulse amplitudes: Firstly, it can adapt to differences in fluid medium attenuation and balance the energy range of the echo signal. The density, bubble concentration, and suspended particle content of the fluid medium will change the attenuation of ultrasonic transmission. When using low amplitude excitation, the overall amplitude of the echo is low in high-attenuation fluids and is easily drowned out by system noise. When using excessively high amplitude excitation, the piezoelectric transducer will enter the nonlinear saturation range, generating redundant aftershocks at the transmitting end and a large number of false tail oscillations in the received waveform. By traversing multiple different pulse amplitudes, low-amplitude echoes can supplement the effective waveform information under weak operating conditions, while high-amplitude echoes can improve the signal strength under clean fluids. Furthermore, by dynamically reducing the weight of saturated distortion echoes and appropriately retaining low-amplitude effective echoes, the synthesized waveform can cover a wide range of medium attenuation scenarios, avoiding the two extreme problems of weak signals in clean fluids and waveform distortion in high-bubble fluids with fixed pulse amplitudes.
[0050] Secondly, it can reduce the fixed system interference caused by the nonlinearity of the transducer device. Long-term excitation with the same pulse amplitude may cause fixed harmonic distortion in the piezoelectric crystal of the transducer. The distortion waveform will continue to accumulate with each superposition, forming a fixed pseudo-front interference. However, the phase and amplitude of the nonlinear distortion components of the transducer are not uniform under different pulse amplitude drives. After weighted accumulation, the amplitude-related fixed harmonic distortion will cancel each other out, further reducing the interference of the device's inherent distortion on the propagation time acquisition and improving the long-term stability of the measurement.
[0051] In some examples, combined echo signals can be obtained by periodically transmitting signals with different transmission frequencies and pulse widths, and then accumulating the signals, thus facilitating the extraction of propagation time. First, a loop structure is entered, transmitting an ultrasonic excitation signal with a preset transmission frequency and pulse width. Then, the transmission frequency and pulse width of the ultrasonic excitation signal are changed (while other preset signal parameters such as pulse amplitude and number of pulses remain unchanged), and the next round of transmission begins. For each echo signal corresponding to the transmitted ultrasonic excitation signal, the echo signal is processed, and the gain coefficient of the echo signal in the entire combined waveform is obtained. Then, the echo signal is accumulated into a total composite signal. Similar to the accumulation process described above, this accumulation process can be controlled by a counter and a conditional decision to loop until multiple ultrasonic excitation signals with different transmission frequencies and pulse amplitudes are accumulated with the echo signals. The loop ends, at which point a combined echo signal after multiple accumulations is obtained.
[0052] It should be understood that the signal pulse width represents the number of carrier pulse cycles contained in a single excitation signal. Transmitting a fixed signal pulse width has adaptation limitations, while traversing and accumulating multiple signal pulse widths has the following advantages: Firstly, by matching the transducer's resonant bandwidth, the steepness of the waveform's rising edge is enhanced. Ultrasonic transducers have an optimal resonant pulse width range. If the pulse width is too short (a few carrier cycles), the excitation energy is insufficient, resulting in a flat rise edge and blurred inflection point characteristics. If the pulse width is too long (a large number of continuous carrier cycles), the transducer's free oscillation time after transmission is significantly prolonged, leading to a large number of spurious oscillations superimposed on the echo tail, which can easily cause misjudgment of the arrival time. After traversing multiple sets of excitation signals with different pulse widths, high gain is assigned to the optimal pulse width echo within the matched resonant range, while the weight of short and excessively long pulse width echoes is reduced. The synthesized combined echo can ensure clear rising edge abrupt changes and significantly suppress spurious waveforms caused by transducer oscillations, providing a high-quality waveform base for subsequent inflection point and kurtosis methods.
[0053] Secondly, it adapts to the time-domain window requirements of fluids with high and low flow rates. At high flow rates, the time difference between upstream and downstream ultrasonic propagation is small, requiring a narrow time-domain window for accurate identification of the first wave, resulting in a more concentrated time-domain distribution of short-pulse-width echoes. At low flow rates, the propagation delay span is large, and long-pulse-width echoes have more energy and are less prone to signal loss. The combined echo after fusing multiple sets of different signal pulse widths simultaneously takes into account both wide and narrow time-domain characteristics. One waveform can be adapted to the full range of flow rate measurements without the need to switch the transmission pulse width parameters according to the flow rate.
[0054] It should be understood that in this example, by simultaneously traversing different transmission frequencies and signal pulse widths for joint excitation and signal accumulation, compared to excitation methods that only change the transmission frequency or only change the signal pulse width, this example can optimize echo quality from two dimensions: the frequency domain characteristics of sound wave propagation and the time domain excitation characteristics of the pulse. Different fluid bubble contents and impurity concentrations will produce differentiated scattering attenuation of ultrasonic waves at different frequencies. At the same time, the transducer's excitation response, oscillation mode, and after-resonance duration differ significantly to different pulse widths. This example, through dual-parameter combination traversal, can select excitation combinations that are both suitable for the current fluid propagation characteristics and match the optimal resonance state of the transducer. Combined with the contribution of dynamic gain accumulation strategy to the enhancement of high-quality combined echoes and the weighting of distortion mismatch echo suppression, it effectively overcomes the problems of poor signal adaptability, stubborn waveform distortion, and lack of effective information that exist with single transmission frequency and single signal pulse width excitation, significantly improving the overall signal-to-noise ratio and waveform fidelity of the combined echo. This synergistic optimization effect exceeds the technical gain of single parameter adjustment, and can stably output high-quality echo waveforms under harsh working conditions such as bubbles, high disturbances, and high and low flow rate switching, providing a solid signal foundation for subsequent accurate and reliable extraction of ultrasonic wave propagation time.
[0055] It should be noted that, in this embodiment, the preset signal parameters of the multiple ultrasonic excitation signals periodically emitted to the target fluid can also be duty cycle, emission power, etc., and the values of the preset signal parameters can be changed or remain unchanged. It can be that the value of one of the preset signal parameters changes, or the values of several of the preset signal parameters change. This application does not make any specific limitations in this regard.
[0056] It should be understood that in this embodiment, by dynamically adjusting the weights of the echo signals in the combination process according to the characteristics of the echo signals corresponding to each ultrasonic excitation signal, this gain coefficient determination and weighted superposition processing based on echo feature information can effectively avoid the noise and distortion that may be introduced by simple superposition, significantly improving the signal-to-noise ratio and waveform quality of the combined echo signals. Therefore, when performing waveform feature extraction processing on the combined echo signals in the subsequent process, more accurate and reliable echo feature information can be obtained, thus laying a solid foundation for selecting a suitable propagation time extraction method and finally determining the propagation time of the ultrasonic excitation signal. This greatly improves the accuracy and stability of ultrasonic propagation time determination, especially in environments with complex fluid media or interference, where its advantages are even more obvious.
[0057] In one possible implementation, waveform feature extraction processing is performed on the combined echo signal to obtain echo feature information, including: Time-domain waveform analysis was performed on the combined echo signals to extract echo characteristic parameters from the echo waveforms of the combined echo signals. Echo feature information is generated by mapping the extracted echo feature parameters.
[0058] In some examples, the combined echo signal is first analyzed in the time domain. By observing and processing the instantaneous changes in the combined echo signal along the time axis, the intrinsic structure and characteristics of the combined echo signal are revealed, thereby extracting echo characteristic parameters from the echo waveform. This time-domain waveform analysis method can intuitively reflect information such as the amplitude, phase, and duration of the combined echo signal, and is fundamental to understanding the dynamic behavior of signals. For example, the time-domain characteristics of the echo signal can be quantified by calculating statistical parameters of the waveform (such as mean, variance, peak value, and valley value). Digital signal processing techniques, such as moving average, differentiation, or integration operations, can also be used to highlight specific points of change or trends in the waveform.
[0059] Echo characteristic parameters refer to representative signal attribute values identified and quantified from combined echo signals after time-domain waveform analysis. They are the underlying data for objectively quantifying the quality of waveforms. These echo characteristic parameters can reflect the physical processes and environmental conditions experienced by ultrasound waves as they propagate in fluids. For example, peak detection algorithms can be used to identify the main pulse of the echo signal, energy integration can be used to calculate the signal energy, or zero-crossing detection can be used to analyze the frequency components of the signal.
[0060] The echo characteristic parameters include at least the signal-to-noise ratio (SNR), waveform distortion, and bubbling interference intensity. Among these, the SNR is a crucial indicator of signal quality, representing the ratio of signal power to noise power. A high SNR indicates a clear signal with minimal noise interference; a low SNR indicates the signal is overwhelmed by noise and difficult to accurately identify. The SNR can be calculated by comparing the peak amplitude of the echo signal with the root mean square (RMS) value of the background noise, or by measuring the noise power during periods without signal and then comparing it with the signal power during periods with signal.
[0061] Waveform distortion reflects the difference between the received waveform and the ideal transmitted waveform. This distortion can be caused by multipath effects, fluid medium inhomogeneities, or sensor response nonlinearities. The degree of waveform distortion can be quantified by calculating the cross-correlation coefficient between the received echo waveform and the reference waveform; a lower cross-correlation coefficient indicates a higher degree of distortion. Alternatively, it can be assessed by analyzing the waveform's symmetry and kurtosis (such as skewness and kurtosis) to evaluate its deviation from the ideal shape.
[0062] Bubble interference intensity indicates the degree to which bubbles in a fluid affect the propagation of ultrasonic waves. The presence of bubbles causes scattering, absorption, and attenuation of ultrasonic waves, thereby altering the amplitude, phase, and frequency of the echo signal. The intensity of bubble interference can be assessed by monitoring amplitude fluctuations in the echo signal; for example, greater amplitude fluctuations indicate stronger bubble interference. Alternatively, it can be achieved by analyzing the echo signal spectrum to identify the attenuation or enhancement of specific frequency components caused by bubbles.
[0063] Then, based on the extracted echo characteristic parameters such as signal-to-noise ratio, waveform distortion, and bubble interference intensity, numerical mapping is performed using a specific algorithm or rule to obtain echo characteristic information. This echo characteristic information can characterize the waveform quality, abrupt change characteristics, and interference level of the combined echo signal. For example, the signal-to-noise ratio can be directly used as an indicator of waveform quality, the waveform distortion as an indicator of abrupt change characteristics, and the bubble interference intensity as an indicator of interference level. Furthermore, weights can be assigned to these features, and a comprehensive numerical value or vector can be generated through weighted summation or fuzzy logic reasoning. This numerical value or vector can comprehensively and objectively reflect the overall characteristics of the current combined echo signal, thus providing a reliable basis for the subsequent selection of the propagation time extraction method.
[0064] like Figure 4 As shown, Figure 4 This is a waveform diagram of an echo signal provided in one embodiment of this application. Figure 4 In the graph, the horizontal axis represents the propagation time of the echo signal, and the vertical axis represents the amplitude of the echo signal. The blue line represents the echo signal collected from the ultrasonic excitation signal under different values of the preset signal parameters emitted by the ultrasonic flowmeter, and the green line represents the corresponding signal envelope curve. Figure 4 The starting position of the echo signal is clearly and prominently displayed. The first echo waveform under each preset signal parameter has a higher overlap than subsequent waveforms. This characteristic allows us to obtain a clear and distinct abrupt change inflection point to represent the starting point of the echo signal. Figure 1 The moment when the ultrasonic excitation signal emitted by transducer A "has arrived" at transducer B.
[0065] It should be understood that the meticulous feature extraction and quantization processing in this embodiment enables the system to accurately identify various complex situations encountered by ultrasound waves propagating in fluids, such as signal attenuation, multipath interference, or bubble effects.
[0066] In one possible implementation, the conduction time extraction method includes at least one of the following: envelope abrupt change in inflection point method, signal maximum kurtosis method.
[0067] Before determining the propagation time of the ultrasonic excitation signal based on the propagation time extraction method corresponding to the echo feature information, the method includes: If the echo characteristic information shows that the combined echo signal has the characteristics of an envelope abrupt change inflection point, then the propagation time extraction method is determined to be the envelope abrupt change inflection point method. If the echo characteristic information shows that the combined echo signal contains a preset number of echo oscillation interference features, then the conduction time extraction method is determined to be the maximum kurtosis method.
[0068] Propagation time extraction (PTE) can be understood as a method for accurately identifying the first arrival time of an ultrasonic wave at the receiver from an ultrasonic echo signal. This time point is a key parameter for calculating fluid velocity. The role of PTE is to convert the received complex echo signal into a physically meaningful time value. Possible implementations of PTE include, but are not limited to: threshold-based methods, such as the first zero-crossing method and the fixed threshold method; and waveform feature analysis-based methods, such as correlation methods, phase methods, and energy methods.
[0069] In this embodiment, the propagation time extraction method may include one of the following: the envelope abrupt change in inflection point method and the signal maximum kurtosis method. The envelope abrupt change in inflection point method is a method for determining propagation time by analyzing the changing trend of the echo signal envelope. When the ultrasonic signal first arrives at the receiving end, the energy of the echo signal suddenly increases, causing a significant abrupt change or inflection point in its envelope. This method identifies this abrupt change point as the starting point of the propagation time. This can be achieved by differentiating the envelope to find the extreme point of the derivative, or by analyzing the rate of change of the envelope's slope to locate the inflection point.
[0070] The maximum kurtosis method is a method for determining propagation time based on the statistical characteristic of kurtosis. Kurtosis is a statistical measure of the sharpness or peak of a signal waveform. For ultrasonic echo signals, when the ultrasonic wave first arrives, the instantaneous energy and amplitude of the signal rise sharply, causing the kurtosis value to reach its maximum at that point. This maximum kurtosis method finds the point in the echo signal with the maximum kurtosis value as the starting point of the propagation time. This can be achieved by calculating the kurtosis value of the signal using a sliding window and identifying peak points in the kurtosis sequence.
[0071] The echo characteristic information shows that the echo waveform of the combined echo signal exhibits an envelope abrupt change inflection point, indicating that the current echo signal waveform has a significant abrupt change in the envelope. This envelope abrupt change inflection point characteristic typically occurs under ideal or near-ideal conditions with high signal-to-noise ratio, low interference, and a clear echo signal start point. This envelope abrupt change inflection point characteristic can be determined by analyzing the echo signal's signal-to-noise ratio, waveform smoothness, and the presence of a significant energy rise edge.
[0072] The echo characteristic information shows that the echo waveform of the combined echo signal contains a preset number of echo initiation interference features. This indicates that, based on the echo characteristic information, the waveform of the current echo signal is judged to have a certain degree of interference in the initial stage, such as false initiation signals caused by bubbles, impurities, or multipath effects. This interference may lead to unclear starting points of the echo signal, indistinct envelope abrupt changes, or the appearance of multiple false abrupt change points. This echo initiation interference feature can be judged by analyzing the waveform distortion degree of the echo signal, the intensity of bubble interference, or the presence of multiple starting pulses with similar amplitudes. The preset number can be an empirical value; for example, when more than two obvious false initiation signals are detected, it is considered that a preset number of echo initiation interference features exist.
[0073] Specifically, when the echo signal quality is good and has clear envelope abrupt change inflection point characteristics, choosing the envelope abrupt change inflection point method for conduction time extraction can more accurately capture the true starting point of the signal because this method directly utilizes the physical characteristics of signal energy abrupt changes. When the echo signal is interfered with, such as by oscillation interference causing the envelope abrupt change to be indistinct or the presence of multiple spurious abrupt changes, choosing the signal maximum kurtosis method for conduction time extraction can more robustly identify the true starting point of the signal through statistical methods. This is because the signal maximum kurtosis method is relatively less sensitive to noise and interference and focuses more on the instantaneous impulse characteristics of the signal.
[0074] like Figure 5 As shown, Figure 5 This is a flowchart illustrating a method for determining ultrasonic wave conduction time according to another embodiment of this application. Figure 5 In this process, after acquiring the combined echo signal, feature extraction is first performed on the combined echo signal to analyze its characteristic attributes. Based on the extracted echo feature information, the optimal propagation time extraction method is adaptively selected. For example, when the waveform exhibits obvious abrupt changes, the envelope abrupt change inflection point method is used to determine the arrival time of the ultrasonic wave by detecting the inflection point on the envelope. When the echo signal has too many false echo oscillation characteristics, the maximum kurtosis method is used, with the maximum kurtosis value in the waveform as the time reference benchmark.
[0075] The core advantage of this adaptive selection of the optimal propagation time extraction method lies in the fact that different test conditions (such as the presence of air bubbles, impurities, or pipe wall materials) can cause significant changes in the echo waveform morphology, making it difficult for a single propagation time extraction method to maintain optimal accuracy under all conditions. In this embodiment, a dynamic propagation time extraction method is determined by pre-feature judgment to avoid misjudgments caused by interference, thereby achieving stable and accurate propagation time extraction in various complex environments and effectively improving the robustness and accuracy of ultrasonic flow meters under harsh conditions.
[0076] In one possible implementation, when the transmission time extraction method is determined to be the signal maximum kurtosis method, the transmission time of the ultrasonic excitation signal is determined based on the transmission time extraction method corresponding to the echo feature information, including: The combined echo signal is smoothed and filtered to obtain the processed combined echo signal; The echo waveforms of the combined echo signals after processing are processed by traversing the time domain using a sliding window, and the statistical characteristic values of the echo waveforms of the combined echo signals after processing are calculated window by window. Based on the statistical feature values corresponding to each window, a full waveform kurtosis sequence corresponding to the echo waveform of the processed combined echo signal is generated. Based on the kurtosis peak value in the full waveform kurtosis sequence, interpolation fitting is performed on the neighborhood data of the kurtosis peak value to determine the time domain point corresponding to the kurtosis peak value; The propagation time of the ultrasonic excitation signal is determined based on the time-domain point corresponding to the kurtosis peak.
[0077] like Figure 6 As shown, Figure 6 This is a schematic flowchart illustrating how to determine the propagation time of an ultrasonic excitation signal using the maximum kurtosis method, as provided in one embodiment of this application. Figure 6 This method is an enhanced implementation of the "signal maximum kurtosis method," particularly suitable for arrival time detection in noisy environments. First, the combined echo signal is smoothed and filtered to obtain the processed combined echo signal. Smoothing filtering reduces high-frequency noise components in the signal, eliminates glitches or transient interference, thus making the echo waveform smoother and providing a clearer and more stable data foundation for subsequent kurtosis calculation. This smoothing filtering can be implemented in various ways; for example, a moving average filter can be used to smooth the signal by calculating the average value within a specific time window; or a low-pass filter can be used to filter out high-frequency noise above a preset signal parameter range.
[0078] Subsequently, a sliding window is used to traverse the time domain to process the combined echo signal, and the statistical characteristic values of the processed combined echo signal are calculated window by window. That is, the counter value m is initialized, m = M0 (the initial sequence number of the sliding window is M0), and the loop processing stage begins. In each loop, three statistical characteristic values are calculated sequentially for the waveform data within the current window: the mean (i.e., the average value of the waveform data in the window), the second central moment (obtained by subtracting the mean from each sample data in the window, squaring the result, summing the results, and dividing by the sample size), and the fourth central moment (obtained by subtracting the mean to the fourth power from each sample data in the window, summing the results, and dividing by the sample size).
[0079] Then, based on the statistical characteristic values such as the mean, second-order central moment, and fourth-order central moment corresponding to each window, a full waveform kurtosis sequence corresponding to the echo waveform of the processed combined echo signal is generated. That is, by substituting the three statistical characteristic values of the mean, second-order central moment, and fourth-order central moment into the preset kurtosis formula, the kurtosis value sequence of the waveform in the current window can be obtained, and the kurtosis value is stored in the first array buf[m].
[0080] The default kurtosis formula is: ; in, Indicates the kurtosis value. This represents the mean. , The data represents sample data within the window waveform data, where M is the sample size, and i = 1, 2, ..., M. It is the fourth-order central moment. It is the second-order central moment.
[0081] The loop increments the window position by m++, repeating the above calculation process until the entire time range of the combined echo signal is covered (m>N, where N is the number of sliding windows). The size and step size of the sliding window can be adjusted according to the actual application scenario and signal characteristics to balance computational efficiency and feature extraction precision. After the loop ends, the first array buf[m] stores the kurtosis value sequence corresponding to each sliding window position, thus obtaining the full waveform kurtosis sequence.
[0082] After obtaining the full waveform kurtosis sequence, the maximum value in the first array buf[m], i.e., the kurtosis peak, is extracted. The neighborhood data of the kurtosis peak is then interpolated and fitted to obtain a more precise location of the maximum value, i.e., the time-domain point corresponding to the kurtosis peak. Since signal sampling is discrete, the kurtosis peak may not precisely fall on a specific sampling point. By interpolating and fitting the kurtosis peak and its neighborhood data, the true location of the kurtosis peak can be estimated more accurately, thereby improving the accuracy of propagation time determination.
[0083] Finally, by combining the preset sampling rate and the reference time of the ultrasonic excitation signal's emission trigger point, the time-domain point corresponding to the kurtosis peak is converted into the ultrasonic excitation signal's propagation time.
[0084] like Figure 7 As shown, Figure 7 This is a schematic diagram of process data for determining conduction time using the maximum kurtosis method of a signal, provided in an embodiment of this application. Figure 7 In the diagram, the horizontal axis represents the propagation time of the processed combined echo signal, the vertical axis represents the kurtosis value, the blue curve represents the waveform data curve of the processed combined echo signal, and the orange curve represents the kurtosis curve of the sliding window. Figure 7In the process, the waveform data curve of the combined echo signal is obtained by smoothing and filtering the combined echo signal. Then, a sliding window of size M0 is set, and the kurtosis value of the window is obtained. Sliding the window from beginning to end once yields the result. Figure 7 The kurtosis curve of the sliding window is then obtained. Next, the maximum kurtosis peak is obtained from the kurtosis curve of the sliding window. By interpolating and fitting data near the kurtosis peak, the time-domain point corresponding to the high-precision kurtosis peak can be obtained. Combined with the preset sampling rate of the analog-to-digital converter (ADC) and the reference time of the transmission trigger point, the propagation time of the ultrasonic excitation signal from transducer A to transducer B is calculated.
[0085] It should be noted that the core principle of this maximum kurtosis method lies in the fact that kurtosis is extremely sensitive to abrupt changes and transient shocks in a signal. When the sliding window is precisely aligned with the arrival front of the ultrasonic wave, the waveform within the window suddenly jumps from the noise floor to a large-amplitude oscillation. This drastic change causes the kurtosis value of this window to be significantly higher than other windows containing only noise or stationary signals. Therefore, by searching for the window position corresponding to the maximum value in the first array buf[m], and then performing interpolation fitting to obtain a higher-precision maximum kurtosis, the arrival time of the ultrasonic wave can be accurately located, and the propagation time can be calculated.
[0086] It should be understood that, compared with the traditional amplitude threshold method or simple envelope detection, the maximum kurtosis method does not require a preset threshold, is not sensitive to the absolute amplitude of the signal, and can effectively suppress background noise interference under conditions of extremely low signal-to-noise ratio. It is particularly suitable for industrial measurement environments with harsh measurement conditions, weak echoes, or bubble attenuation.
[0087] In one possible implementation, when the transmission time extraction method is determined to be the envelope abrupt change inflection point method, the transmission time of the ultrasonic excitation signal is determined based on the transmission time extraction method corresponding to the echo characteristic information, including: The Hilbert transform is applied to the echo waveform of the combined echo signal to obtain the envelope curve of the echo waveform; The envelope curve is smoothed by a smoothing filter to obtain a smoothed envelope curve. The smoothed envelope curve is differentiated along the time domain to generate the slope sequence corresponding to the smoothed envelope curve; Based on the extreme values of slope in the slope sequence, interpolation fitting is performed on the neighborhood data of the extreme values of slope to determine the time-domain points corresponding to the extreme values of slope. The propagation time of the ultrasonic excitation signal is determined based on the time-domain point corresponding to the slope extremum.
[0088] like Figure 8 As shown, Figure 8This is a flowchart illustrating an embodiment of this application regarding the determination of the propagation time of an ultrasonic excitation signal using the envelope abrupt change inflection point method. The core idea of the envelope abrupt change inflection point method is to accurately locate the arrival time of the ultrasonic excitation signal by detecting the point on the envelope of the echo signal where the slope changes most drastically (i.e., the abrupt change inflection point). Figure 8 First, a Hilbert transform is performed on the combined echo signal to extract the envelope curve of the corresponding echo waveform. The Hilbert transform is a signal processing technique used to convert a real signal into an analytic signal, thereby obtaining an envelope reflecting changes in signal energy, effectively eliminating carrier frequency components while preserving amplitude modulation information.
[0089] Subsequently, the extracted envelope curve is smoothed using a smoothing filter to obtain a smoothed envelope curve. Smoothing filtering eliminates glitches and jitter caused by noise or discrete sampling, making the envelope curve smoother and more continuous, facilitating subsequent differential operations. After obtaining the smoothed envelope curve through smoothing filtering, the process enters a loop processing stage, where the smoothed envelope curve is differentiated along the time domain (i.e., the slope between adjacent points is calculated) to obtain the slope sequence corresponding to the smoothed envelope curve at each window position. This slope sequence is then stored sequentially in the second array buf[k]. In the envelope curve of an ultrasonic echo signal, the starting point of the signal usually exhibits a significant change in slope; differentiation can amplify this change, making it easier to identify.
[0090] The loop increments the window position by k++, repeating the differentiation and storage operations until the complete envelope curve data range is traversed (k is the counter value). The loop ends when k>K (K is the number of sliding windows in the envelope abrupt change inflection point method). The maximum value, i.e., the slope extreme value, is found in the second array buf[k]. The position corresponding to this slope extreme value is the point where the slope of the envelope curve changes most drastically, which is the abrupt change inflection point where the envelope curve suddenly jumps from the noise floor when the ultrasound arrives.
[0091] Next, neighborhood data near the slope extremum is extracted, and interpolation fitting is performed on this neighborhood data to obtain a more accurate abrupt inflection point, i.e., the time-domain point corresponding to the slope extremum. The slope extremum usually corresponds to the point where the envelope curve changes most drastically, which is often the starting point of the ultrasonic signal arrival. By interpolating and fitting the slope extremum and its neighborhood data, the position of this extremum point on the time axis can be located more accurately, avoiding discrete errors caused by sampling rate limitations.
[0092] Finally, by combining the preset sampling rate and the reference time of the ultrasonic excitation signal's transmission trigger point, the time-domain points corresponding to the slope extrema are converted to obtain the ultrasonic excitation signal's propagation time. The preset sampling rate determines the time interval between each sampling point, while the reference time of the transmission trigger point provides the starting point for time measurement. By multiplying the sampling point number corresponding to the slope extrema by the sampling period and adding the reference time of the transmission trigger point, the precise propagation time of the ultrasonic signal can be obtained.
[0093] In this system, the transmission trigger point refers to the initial moment when the control unit sends the ultrasonic excitation signal to the drive circuit in determining the ultrasonic transmission time. This is the absolute zero point (t=0) at which the ultrasonic excitation signal begins to be emitted from the transducer, and the ultrasonic transmission time is counted from this moment. The sampling trigger point, on the other hand, refers to the initial moment when the analog-to-digital converter (ADC) begins to acquire the echo signal. This moment has a fixed delay relative to the transmission trigger point.
[0094] For example, taking the envelope abrupt change inflection point method as an example, assuming that the sampling point index corresponding to the extreme value of the slope on the envelope curve has been found by sliding differentiation. (i.e., time domain point position), then the propagation time of the ultrasonic excitation signal is: ; in, Indicates the propagation time of the ultrasonic excitation signal (unit: seconds). This represents the fixed offset time between the sampling trigger point and the transmission trigger point. This represents the absolute time of the envelope mutation inflection point relative to the sampling trigger point. Indicates the fixed latency of the system hardware . , This indicates the time elapsed from when the ADC starts acquiring echo signals (sampling trigger point) to when the envelope abruptly changes and becomes inflection point. The sampling period is (Unit: seconds) Sampling rate (unit: Hz). Fixed latency of the system hardware. This includes signal transmission delays introduced by drive circuits, cables, etc.
[0095] like Figure 9 As shown, Figure 9 This is a schematic diagram of process data for determining conduction time using the envelope abrupt change inflection point method, provided in an embodiment of this application. Figure 9In the diagram, the horizontal axis represents the propagation time of the combined echo signal, and the vertical axis represents the sliding derivative of the envelope. The blue curve represents the waveform data curve of the combined echo signal, and the orange curve represents the sliding derivative data curve of the envelope. The Hilbert transform is performed on the waveform data of the combined echo signal to obtain its envelope curve. Then, the extracted envelope curve is smoothed and filtered. Finally, the sliding derivative of the smoothed envelope curve is performed to obtain the final envelope curve. Figure 9 The envelope sliding derivative data curve is shown in the figure. Next, the maximum value in the envelope sliding derivative data, i.e., the slope extremum, is found. Combining the curve characteristics of the envelope sliding derivative data curve near the maximum value, the abrupt inflection point of the envelope when the ultrasonic wave arrives is obtained, i.e., the time-domain point corresponding to the slope extremum. Combined with the preset sampling rate of the analog-to-digital converter (ADC) and the reference time of the transmission trigger point, the propagation time of the ultrasonic excitation signal from transducer A to transducer B is calculated.
[0096] It should be noted that the core principle of this envelope abrupt change inflection point method lies in its insensitivity to noise and waveform distortion compared to the zero-crossing point or amplitude peak of the original signal. Even if the carrier phase of the echo signal changes or there is a certain degree of amplitude fluctuation, the starting position of the rising edge of the envelope curve remains stable. By using sliding derivatives to locate the point of maximum slope, the critical moment when the ultrasonic excitation signal transitions from "not arrived" to "arrived" can be precisely locked, effectively avoiding misjudgments of false arrival and oscillation positions caused by transducer residual vibration, reverberation, or fluid disturbance. This method is suitable for industrial measurement environments with low signal-to-noise ratios or complex and variable waveforms.
[0097] It should be understood that the sequence number of each step in the above embodiments does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.
[0098] Corresponding to the above embodiment, a method for determining ultrasonic wave conduction time, Figure 10 A schematic diagram of a device for determining ultrasonic wave conduction time according to an embodiment of this application is shown. For ease of explanation, only the parts related to the embodiment of this application are shown.
[0099] Reference Figure 10 The ultrasonic wave conduction time determination device 3 in this embodiment includes: The acquisition module 31 is used to acquire the combined echo signal corresponding to the multiple ultrasonic excitation signals if the ultrasonic flow meter emits multiple ultrasonic excitation signals to the target fluid with preset signal parameters.
[0100] The extraction module 32 is used to perform waveform feature extraction processing on the combined echo signal to obtain echo feature information. The echo feature information is used to indicate the echo characteristics of the echo waveform of the combined echo signal. Different echo characteristics correspond to different conduction time extraction methods.
[0101] The determination module 33 is used to determine the propagation time of the ultrasonic excitation signal based on the propagation time extraction method corresponding to the echo characteristic information.
[0102] Furthermore, the preset signal parameters include at least one of the following: transmission frequency, pulse amplitude, signal pulse width, and number of pulses.
[0103] Furthermore, the acquisition module 31 includes: The echo receiving submodule is used to receive the echo signal corresponding to each ultrasonic excitation signal when the ultrasonic flow meter emits multiple ultrasonic excitation signals to the target fluid with preset signal parameters.
[0104] The gain determination submodule is used to determine the gain coefficient of each echo signal based on the echo characteristic information of each echo signal.
[0105] The superposition processing submodule is used to perform weighted superposition processing on each echo signal according to the gain coefficient of each echo signal to obtain a combined echo signal.
[0106] Furthermore, the extraction module 32 includes: The feature extraction submodule is used to perform time-domain waveform analysis on the combined echo signal and extract the echo feature parameters from the echo waveform of the combined echo signal.
[0107] The feature quantization submodule is used to generate echo feature information based on the extracted echo feature parameters.
[0108] Furthermore, the ultrasonic wave propagation time determination device 3 includes: The first extraction method determination module is used to determine the conduction time extraction method as the envelope abrupt change inflection point method if the echo feature information shows that the combined echo signal has the envelope abrupt change inflection point feature.
[0109] The second extraction method determination module is used to determine the conduction time extraction method as the maximum kurtosis method if the echo feature information shows that the combined echo signal contains a preset number of echo oscillation interference features.
[0110] Furthermore, the determining module includes a first determining submodule, which includes: The first filtering unit is used to perform smoothing filtering on the combined echo signal to obtain the processed combined echo signal.
[0111] The first statistical unit is used to calculate the statistical characteristic values of the echo waveform of the processed combined echo signal by windowing along the time domain using a sliding window.
[0112] The first generation unit is used to generate a full waveform kurtosis sequence corresponding to the echo waveform of the processed combined echo signal based on the statistical feature values corresponding to each window.
[0113] The first determining unit is used to perform interpolation fitting on the neighborhood data of the kurtosis peak in the full waveform kurtosis sequence to determine the time domain point corresponding to the kurtosis peak.
[0114] The first conversion unit is used to determine the propagation time of the ultrasonic excitation signal based on the time-domain point corresponding to the kurtosis peak.
[0115] Furthermore, the determining module includes a second determining submodule, which includes: The second processing unit is used to perform Hilbert transform on the echo waveform of the combined echo signal to obtain the envelope curve of the echo waveform.
[0116] The second filtering unit is used to perform smoothing filtering on the envelope curve to obtain a smoothed envelope curve.
[0117] The second generation unit is used to perform sliding derivative calculation along the time domain on the smoothed envelope curve to generate the slope sequence corresponding to the smoothed envelope curve.
[0118] The second determining unit is used to perform interpolation fitting on the neighborhood data of the slope extreme values in the slope sequence to determine the time-domain point corresponding to the slope extreme value.
[0119] The second conversion unit is used to determine the propagation time of the ultrasonic excitation signal based on the time-domain point corresponding to the slope extremum.
[0120] It should be noted that the information interaction and execution process between the modules in the ultrasonic wave conduction time determination device 3 are based on the same concept as the method embodiment of this application. For details on their specific functions and technical effects, please refer to the method embodiment section, and they will not be repeated here.
[0121] This application also provides a terminal device, such as... Figure 11 As shown, Figure 11 This is a schematic diagram of the structure of a terminal device provided in an embodiment of this application. (Refer to...) Figure 11 The terminal device 4 in this embodiment includes a memory 41, a processor 42, and a computer program stored in the memory 41 and executable on the processor 42. When the processor 42 executes the computer program, it implements the steps in the method embodiment for determining the ultrasonic transmission time of any of the above-mentioned methods.
[0122] This application also provides a computer-readable storage medium storing a computer program, which, when executed by a processor, can implement the steps in the above-described method embodiments.
[0123] This application provides a computer program product that, when run on a mobile terminal, enables the mobile terminal to implement the steps described in the various method embodiments.
[0124] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the methods of the above embodiments of this application can be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include at least: any entity or device capable of carrying the computer program code to a photographic device / terminal device, a recording medium, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electrical carrier signal, a telecommunication signal, and a software distribution medium. Examples include USB flash drives, portable hard drives, magnetic disks, or optical disks.
[0125] In the above embodiments, the descriptions of each embodiment have different focuses. For parts that are not described in detail or recorded in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0126] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0127] In the embodiments provided in this application, it should be understood that the disclosed apparatus / network devices and methods can be implemented in other ways. For example, the apparatus / network device embodiments described above are merely illustrative. For instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.
[0128] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0129] The technical features of the various embodiments described above in this application can be combined arbitrarily without conflict. For the sake of brevity, this specification does not describe all possible combinations, but as long as these combinations do not violate the technical spirit of this application, they should all be considered within the scope of this application. Based on the content disclosed in this application, those skilled in the art can reasonably combine, delete, or replace the technical features of the above embodiments according to actual needs, and such modifications and variations all fall within the protection scope of this application.
[0130] The above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application, and should all be included within the protection scope of this application.
Claims
1. A method for determining the ultrasonic wave transmission time, characterized in that, include: If the ultrasonic flow meter emits multiple ultrasonic excitation signals to the target fluid with preset signal parameters, the combined echo signal corresponding to the multiple ultrasonic excitation signals is obtained. The combined echo signal is subjected to waveform feature extraction processing to obtain echo feature information, wherein the echo feature information is used to indicate the echo characteristics of the echo waveform of the combined echo signal, and different echo characteristics correspond to different conduction time extraction methods; The propagation time of the ultrasonic excitation signal is determined based on the propagation time extraction method corresponding to the echo feature information.
2. The method for determining ultrasonic wave propagation time as described in claim 1, characterized in that, The preset signal parameters include at least one of the following: transmission frequency, pulse amplitude, signal pulse width, and number of pulses.
3. The method for determining ultrasonic wave transmission time as described in claim 1, characterized in that, The step of detecting multiple ultrasonic excitation signals emitted by the ultrasonic flow meter to the target fluid with preset signal parameters and acquiring the combined echo signal corresponding to the multiple ultrasonic excitation signals includes: When the ultrasonic flow meter is detected to emit multiple ultrasonic excitation signals toward the target fluid with the preset signal parameters, the echo signal corresponding to each ultrasonic excitation signal is received. The gain coefficient of each echo signal is determined based on the echo characteristic information of each echo signal. The combined echo signal is obtained by sequentially weighting and superimposing the gain coefficients of each echo signal.
4. The method for determining ultrasonic wave propagation time as described in claim 1, characterized in that, The waveform feature extraction process of the combined echo signal to obtain echo feature information includes: Time-domain waveform analysis is performed on the combined echo signal to extract echo characteristic parameters from the echo waveform of the combined echo signal. The echo feature information is generated based on the extracted echo feature parameters.
5. The method for determining ultrasonic wave propagation time as described in claim 1, characterized in that, Before determining the propagation time of the ultrasonic excitation signal based on the propagation time extraction method corresponding to the echo feature information, the method includes: If the echo feature information shows that the combined echo signal has an envelope abrupt change inflection point feature, then the conduction time extraction method is determined to be the envelope abrupt change inflection point method. If the echo feature information shows that the combined echo signal contains a preset number of echo oscillation interference features, then the conduction time extraction method is determined to be the maximum kurtosis method.
6. The method for determining ultrasonic wave transmission time as described in claim 5, characterized in that, When the conduction time extraction method is determined to be the signal maximum kurtosis method, determining the conduction time of the ultrasonic excitation signal based on the conduction time extraction method corresponding to the echo feature information includes: The combined echo signal is smoothed and filtered to obtain the processed combined echo signal; The echo waveforms of the processed combined echo signal are traversed along the time domain using a sliding window, and the statistical characteristic values of the echo waveforms of the processed combined echo signal are calculated window by window. Based on the statistical feature value corresponding to each window, a full waveform kurtosis sequence corresponding to the echo waveform of the processed combined echo signal is generated. Based on the kurtosis peak value in the full waveform kurtosis sequence, interpolation fitting is performed on the neighborhood data of the kurtosis peak value to determine the time domain point corresponding to the kurtosis peak value; The propagation time of the ultrasonic excitation signal is determined based on the time-domain point corresponding to the kurtosis peak.
7. The method for determining ultrasonic wave conduction time as described in claim 5, characterized in that, When the conduction time extraction method is determined to be the envelope abrupt change inflection point method, determining the conduction time of the ultrasonic excitation signal based on the conduction time extraction method corresponding to the echo feature information includes: The Hilbert transform is performed on the echo waveform of the combined echo signal to obtain the envelope curve of the echo waveform; The envelope curve is smoothed by a smoothing filter to obtain a smoothed envelope curve; The smoothed envelope curve is differentiated along the time domain to generate the slope sequence corresponding to the smoothed envelope curve; Based on the extreme values of the slope in the slope sequence, interpolation fitting is performed on the neighborhood data of the extreme values of the slope to determine the time-domain point corresponding to the extreme values of the slope. The propagation time of the ultrasonic excitation signal is determined based on the time-domain point corresponding to the extreme value of the slope.
8. A device for determining the ultrasonic wave conduction time, characterized in that, include: The acquisition module is used to acquire the combined echo signal corresponding to the multiple ultrasonic excitation signals if the ultrasonic flow meter emits multiple ultrasonic excitation signals to the target fluid with preset signal parameters. The extraction module is used to perform waveform feature extraction processing on the combined echo signal to obtain echo feature information, wherein the echo feature information is used to indicate the echo characteristics of the echo waveform of the combined echo signal, and different echo characteristics correspond to different conduction time extraction methods. The determination module is used to determine the propagation time of the ultrasonic excitation signal based on the propagation time extraction method corresponding to the echo feature information.
9. A terminal device, characterized in that, The method includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the computer program, implements the method as claimed in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the method as described in any one of claims 1 to 7.