An ultrasonic flow measuring device based on a transfer function waveform optimizer
By introducing a transfer function waveform optimizer and a linear amplification excitation module into the ultrasonic flow measurement device, the excitation signal is optimized to generate a stable sine segment and a high signal-to-noise ratio segment, thus solving the problem of low flow measurement accuracy in small-diameter pipes at low flow velocities and achieving higher measurement accuracy and stability.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- HARBIN INST OF TECH
- Filing Date
- 2026-04-23
- Publication Date
- 2026-07-14
AI Technical Summary
Existing ultrasonic flow measurement devices have low flow measurement accuracy and poor repeatability under small-diameter pipes and low flow velocity conditions, and the signal characteristics are difficult to distinguish accurately, resulting in large dispersion of measurement results.
An ultrasonic flow measurement device based on a transfer function waveform optimizer is adopted. The excitation waveform is optimized by the waveform optimizer and combined with the linear amplification excitation module to generate stable sine segment and high signal-to-noise ratio segment signal. The excitation signal is optimized by particle swarm optimization algorithm to improve signal stability and feasibility.
The accuracy and repeatability of flow measurement are significantly improved. The device can still maintain stable reception under complex conditions such as low flow velocity, small diameter and multiple reflections, which improves the robustness and reliability of flow measurement, enhances the physical consistency of the signal chain, and makes the results reproducible in engineering.
Smart Images

Figure CN122062769B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of ultrasonic flow measurement technology and relates to an ultrasonic flow measurement device. Background Technology
[0002] For decades, ultrasonic flow measurement technology has been widely recognized as a crucial tool for solving flow detection challenges in various fields, including chemical industry, energy metering, healthcare, and industrial production. This technology is renowned for its non-contact and non-invasive measurement characteristics, and boasts advantages such as high detection sensitivity, flexible structural layout, and low overall cost, enabling effective measurement in diverse fluid media and complex operating conditions.
[0003] From the perspective of measurement principles, current mainstream ultrasonic flow measurement methods can be divided into three categories: time-difference method, Doppler method, and phase method. Among them, the time-difference method has become the most widely used technical route in industry due to its advantages such as simple structure, diverse installation methods, and wide measurement range. However, under conditions of small-diameter pipes and low flow velocities, the time difference between upstream and downstream propagation is extremely small, making it difficult to accurately distinguish signal characteristics. This results in large dispersion and poor repeatability of measurement results, thus limiting the scope of application of this method. Summary of the Invention
[0004] This invention addresses the problem that the flow measurement accuracy of existing ultrasonic flow measurement devices needs to be improved.
[0005] An ultrasonic flow measurement device based on a transfer function waveform optimizer includes a transmitting transducer and a receiving transducer, and the device further includes:
[0006] Waveform optimizer: Optimizes the excitation waveform and outputs the excitation signal through the waveform generator to make the output signal of the receiving transducer present a stable sine segment and / or a high signal-to-noise ratio segment;
[0007] Linear amplification excitation module: linearly amplifies and excites the output signal of the waveform generator, enabling the transmitting transducer to reproduce the excitation signal output by the waveform generator.
[0008] Furthermore, the waveform optimizer includes a waveform optimization unit for waveform optimization and a waveform output management unit responsible for sending out the final waveform; wherein the waveform optimization unit includes:
[0009] Real-time transfer function calculation module: used for real-time calculation of transfer functions;
[0010] Optimization Solver Module: Combining the results from the forward and reverse calculation module based on transfer function, the waveform modification module, and the realizability evaluation module, it utilizes optimization algorithms to optimize the parameter vector of the value to be optimized. Optimization is performed, and during the optimization process, the solution with the smallest tail energy and the smallest reciprocal of the amplitude is selected as the optimal solution based on the objective function of the feasibility assessment module; the parameter vector to be optimized. The elements in the equation include the waveform characteristics of the excitation signal and the stability characteristics of the output signal.
[0011] The forward calculation module based on the transfer function generates a corresponding periodic signal as the excitation signal based on the waveform characteristics of the excitation signal, and solves for the output signal based on the transfer function.
[0012] Waveform modification module: based on The stability characteristics of the corresponding output signal are used to modify the output signal calculated by the forward calculation module based on the transfer function, resulting in a new time-domain signal, i.e., the modified output signal.
[0013] The inverse calculation module based on the transfer function: solves the modified excitation signal by using the transfer function to solve the modified output signal in the waveform modification module;
[0014] Feasibility assessment module: Based on the energy tail of the modified excitation signal and the amplitude V of the modified output signal itself. out The reciprocal of the value is used as the objective function of the optimization algorithm. During the optimization process of the solver module, the solution with the smaller tail energy and the smaller the reciprocal of the magnitude is selected as the optimal solution.
[0015] Furthermore, during the process of optimizing the excitation waveform by the waveform optimizer, the initial excitation signal is a chirp signal.
[0016] Furthermore, the transfer function is , , ,in , It represents the time-domain and frequency-domain forms of the received signal excited by the Chirp signal. , It is the time-domain and frequency-domain form of the Chirp signal; It is time. It represents frequency, and j is the imaginary unit.
[0017] Furthermore, the process by which the forward calculation module based on the transfer function solves for the output signal based on the transfer function includes:
[0018] Periodic signal generated based on the waveform characteristics of the excitation signal The form is in the time domain, and the corresponding frequency domain form is obtained through frequency domain transformation. According to the transfer function Obtain the frequency domain form of the output signal The time-domain form of the output signal is obtained through inverse frequency domain transform. .
[0019] Furthermore, the process by which the inverse computation module based on the transfer function solves for the modified excitation signal using the transfer function includes:
[0020] The waveform shaping module is used to obtain a new time-domain form. Transformation yields the frequency domain, resulting in a signal in frequency domain form. Then through the transfer function Inverse calculation of the frequency domain form of the excitation signal The time-domain form of the excitation signal obtained through inverse frequency domain transformation. .
[0021] Furthermore, the objective function of the optimization algorithm is as follows:
[0022] ,
[0023] ,
[0024] In the formula, To optimize the objective function; N / f refers to Total length, The integration interval is Nine times the total length of time; V out This is the amplitude of the output signal itself.
[0025] Furthermore, the waveform characteristics of the excitation signal include frequency f, amplitude A, and number of excitation cycles N.
[0026] Furthermore, the stability characteristics of the output signal include the start time t of the stable amplitude. s End time t e and amplitude V out .
[0027] Furthermore, the linear amplification excitation module includes:
[0028] High-voltage rail power supply module: ensures the peak driving capability required to drive the piezoelectric transducer;
[0029] Wideband power amplifier stage: ensures that the excitation waveform maintains amplitude and phase consistency over a large frequency range;
[0030] Output impedance adjustment network: used to achieve optimal energy matching with the piezoelectric transducer and reduce reflection and energy dissipation;
[0031] Protection circuit: Ensures that the protection circuit and transducer are not damaged under overvoltage and overcurrent conditions.
[0032] Beneficial effects:
[0033] 1. This invention, by embedding a physically-informed waveform optimizer in the processor, enables traditional ultrasonic flow meters driven by fixed excitation signals to adaptively generate optimal excitation signals. This waveform optimizer uses the transducer's transfer function as a physical constraint, guiding the excitation signal to dynamically adjust according to the device's structural characteristics. This gives the ultrasonic flow measurement device of this invention the "adaptive excitation" and "physical consistency optimization" characteristics not found in existing instruments.
[0034] 2. The stability of the received waveform output by the device is significantly improved. Unlike traditional ultrasonic flowmeters that use fixed sine pulses or simple envelope shaping, the device of this invention generates an excitation signal with a more concentrated energy distribution within the effective bandwidth of the system through a waveform optimizer, resulting in a highly stable sine wave at the receiving end. The periodic peak fluctuations of the received signal within the stable segment are significantly reduced, and the peak difference is basically controlled within 1% of the overall amplitude, effectively reducing amplitude difference errors and time difference errors in flow inversion.
[0035] 3. The accuracy and repeatability of flow measurement are significantly improved. The optimized excitation signal enables the device to maintain stable reception even under complex operating conditions such as low flow velocity, small diameter, and multiple reflections, effectively improving the robustness of flow velocity and flow rate calculations based on the VAD method or time difference method. Due to the more stable received waveform and higher peak consistency, the overall repeatability, linearity, and long-term stability of the device are significantly improved, thereby enhancing its usability in industrial applications.
[0036] 4. The physical consistency of the signal chain in the device is significantly enhanced, and the results are reproducible in engineering. Traditional signal optimization methods often ignore the bandwidth, acceleration limits, and system frequency response of the transducer, easily generating waveforms that cannot be actually transmitted by the device. This invention introduces a system transfer function during the optimization process, ensuring that the excitation signal generated by the device necessarily meets the physical constraints of the transducer and signal chain. This guarantees that the waveform output by the device can be accurately transmitted and repeatedly verified, achieving highly engineerable optimization results.
[0037] 5. The device boasts low-dimensional optimization advantages, high operating efficiency, and ease of online deployment. This invention employs a signal reconstruction method based on physical features, reducing the original high-dimensional search of thousands of time-domain signals to a few-dimensional optimization, significantly decreasing the processor's computational load. The device can perform optimization not only during factory calibration but also has the capability for on-site adaptive adjustments, making it suitable for applications such as online optimization and periodic calibration. Attached Figure Description
[0038] Figure 1 The diagram shows the received signal and maximum amplitude under long sinusoidal pulse excitation.
[0039] Figure 2 This is the core optimization step of the waveform optimizer.
[0040] Figure 3 To optimize the input signal diagram.
[0041] Figure 4 A comparison of the input signal spectrum before and after optimization.
[0042] Figure 5 A comparison chart of received signals before and after optimization. Detailed Implementation
[0043] To address the problems existing in the background technology, Wang Xuesong et al. proposed the Voltage Amplitude Difference (VAD) method. This method indirectly measures flow velocity by converting the "propagation time difference" of the original time difference method into the "received voltage amplitude difference," which has a certain steady-state improvement effect. Its basic principle is as follows: Two sets of transducers are simultaneously excited. There is a phase difference between the ultrasonic signals propagating in the downstream and upstream directions. When the signals are superimposed at the receiving end, an amplitude oscillation that varies with the phase difference is generated. By measuring this amplitude difference, flow information can be derived.
[0044] Although this method achieved good measurement results in experiments, the effect on the stable section generated by sinusoidal excitation is limited. Significant fluctuations exist in the peak amplitude between different periods, such as... Figure 1 As shown, the energy conversion efficiency of the transducer fluctuates under high-frequency excitation. This instability will further affect the envelope consistency of the received signal and the reliability of time difference calculation.
[0045] To receive a more stable signal and improve flow measurement accuracy, improvements to the existing input signal are still necessary. If the output signal's time-domain waveform is assumed to be arbitrary, the existence of the input signal is often difficult to guarantee. From a frequency domain perspective, this is due to the limited bandwidth of the system's response frequency domain. If the output signal is directly assumed to be a certain waveform, the resulting input signal is often of infinite length in the time domain, a result that can be considered theoretically unreproducible. From a physical perspective, the maximum value of the vibration acceleration of piezoelectric ceramics limits the applicability of the transfer function, and its characteristics under extreme operating conditions are nonlinear. If the output signal does not conform to the true physical signal, a physically realizable input signal cannot be obtained.
[0046] Therefore, this invention, based on the existing voltage difference flow measurement device, introduces a waveform optimizer and a linear power amplifier module to design an ultrasonic flow measurement device. This device enables the ideal output signal to both conform to physical laws and generate the required waveform, thereby improving the accuracy of voltage difference flow measurement.
[0047] Since this device can be approximated as a linear system within its permissible operating range, the transfer function can be used to establish the correspondence between the excitation signal and the received signal. Based on the transfer function, the achievable received signal can be obtained from a given excitation signal through forward calculation; conversely, possible excitation signals can be deduced from the received signal through reverse calculation.
[0048] However, in the reverse engineering process, if an arbitrarily shaped received signal is input and an attempt is made to solve for the excitation signal using a transfer function, a physically meaningless solution is often obtained. The fundamental reason is that arbitrarily constructed received signals usually do not originate from a real linear response process, and may even not exist physically at all. Such signals often contain frequency components beyond the bandwidth, and their amplitude or phase requirements cannot be met. Therefore, the reverse engineering results obtained from the transfer function in this case lose their engineering significance. In other words, physically unrealizable excitation signals are usually composed of high-frequency components outside the bandwidth, and the device cannot produce a corresponding response to such signals.
[0049] In contrast, forward computation is feasible: any given excitation signal can be transformed into a mathematically definable and physically realizable received signal through a transfer function. However, forward computation cannot guarantee in advance that the received signal will exhibit the required "amplitude stability" shape, and therefore cannot be directly used to design excitation signals that meet specific stability conditions.
[0050] For this device, the so-called "amplitude-stable received signal" is merely a set of characteristics. Within this set, there may be an infinite number of signals that satisfy the conditions, such as their stable frequency, stable amplitude, and stable time interval, which may all be different. If a received signal is randomly selected from this set and an attempt is made to solve for the excitation signal in reverse, the probability of obtaining a physically unrealizable solution is extremely high, i.e., the signal length is infinitely long in the time domain, the frequency components are complex, and there are many ultra-high frequency components, making it difficult to actually generate the calculated signal; if a forward design is performed directly, it cannot be guaranteed that the received signal will exhibit stable amplitude characteristics.
[0051] Based on the above contradictions, this invention proposes an ultrasonic flow measurement device that achieves stable signal generation by synchronously iteratively optimizing the characteristics of excitation and received signals, effectively solving the problem that the stable segment of the received signal is difficult to construct directly.
[0052] Specifically, in the process of synchronously iteratively optimizing and achieving stable signal generation based on the characteristics of the excitation and received signals, a strictly describable sinusoidal cycle is first constructed as the initial excitation signal, whose characteristics include frequency f, amplitude A, and number of excitation cycles N. This feature triplet can completely describe an arbitrary sinusoidal cycle, therefore the received signal calculated in its forward direction must be physically realizable. Regardless of whether the received signal naturally contains a stable amplitude range, this invention assumes that it can reach and maintain the expected stable amplitude V after a certain moment. out .
[0053] Based on the above assumptions, an idealized target receiving signal can be generated, and a set of modified excitation signals can be obtained by performing inverse calculations on this signal using a transfer function. The frequency domain realizability of the modified excitation signals is then evaluated, with particular attention paid to the presence of ultra-widebandwidth frequency components. By combining this with particle swarm optimization, an optimal solution that balances the realizability of the excitation signals with the stability of the received signals can be found.
[0054] The advantage of this method lies in the following: By using a sinusoidal frequency as the initial excitation signal, it ensures that the received signal from the first forward calculation necessarily exists. The process of modifying the signal using this necessarily existing signal as a blueprint and then recalculating the excitation signal from the modified received signal is called the reverse calculation stage. Reverse calculation makes it easier to obtain a physically realizable excitation signal. This significantly reduces the optimization search space and improves solution efficiency and algorithm convergence. From a frequency domain perspective, the desired received signal needs to have significant energy concentration at a specific frequency, which means that the corresponding excitation signal must also contain components of the same frequency. This method significantly reduces optimization complexity and improves stability and reliability by first establishing the main spectral distribution of the excitation signal and then using an optimization algorithm for small-scale fine-tuning. Therefore, the waveform optimizer part of the ultrasonic flow measurement device of this invention uses a particle swarm optimization algorithm to ensure the feasibility of using the received signal for flow measurement. The core idea of the particle swarm optimization algorithm originates from swarm intelligence theory. By simulating the cooperative behavior of a swarm of particles in a multidimensional solution space, it achieves the approximation of the global optimal solution. Each particle in the algorithm represents a set of parameters to be optimized. ,in, Value to be optimized The nth value to be optimized has a position vector that corresponds to the current signal design scheme. These are the feature quantities to be optimized. In this embodiment, they include the frequency f, amplitude A, and number of excitation cycles N of the excitation sine wave, as well as the start time t of the received signal stabilization amplitude. s End time t e and amplitude V out There are a total of six values to be optimized, and this six-dimensional vector is called the optimization feature vector. The velocity vector... Decide The search direction and step size in the parameter space.
[0055] It should be noted that the above six quantities are selected as the features to be optimized in this embodiment. In fact, other embodiments can also be selected and optimized according to the actual situation. Generally, the features to be optimized will include the frequency f, amplitude A, and excitation cycle N of the excitation sine wave. Other features can be selected according to the actual situation.
[0056] During the algorithm initialization phase, particles are randomly distributed within the defined parameter boundaries to form an initial population. Each particle calculates its fitness using an objective function, which reflects the deviation between the output signal and the ideal characteristics under the current parameter configuration. A smaller fitness indicates that the signal generated by that parameter combination is closer to the optimal state. The objective function primarily considers the energy distribution of the signal, measuring the amplitude fluctuation of the signal in a steady state, and providing a unified quantitative indicator for the optimization process. During the iteration process, the particle motion follows the following update mechanism:
[0057] ,
[0058] in, Inertial weights are used to balance the global and local aspects of the search. and These are the individual learning factor and the group learning factor, which control the degree to which a particle responds to its own historical experience and the optimal position of the group. To maintain the randomness and diversity of the search, random numbers are selected based on a uniform distribution. Each particle retains two types of memory during the search process: its historical best position. Represents individual cognitive experience, while the optimal position for the group. This represents information shared by all particles. The subscript s is the iteration number.
[0059] Through this individual-group dual feedback mechanism, particles can continuously adjust their search direction in the solution space, achieving a dynamic balance between local exploration and global collaboration.
[0060] The ultrasonic flow measurement device based on a transfer function waveform optimizer described in this embodiment aims to improve the stability and engineering applicability of flow measurement by utilizing the presence of a stable sine wave in the signal form.
[0061] The measurement process of traditional ultrasonic flow measurement devices is generally as follows: pulse excitation → transmitting transducer → sound wave propagation → receiving transducer → receiving signal processing. The device proposed in this invention consists of: waveform optimizer → linear amplification excitation module → transmitting transducer → sound wave propagation → receiving transducer → receiving signal processing.
[0062] The transmitting and receiving transducers can be based on existing technologies, and will not be described in detail in this embodiment. The following focuses on the linear amplification excitation module and the waveform optimizer.
[0063] This invention proposes a linear amplification excitation module. Through a high-power linear amplifier circuit with high linearity and wide bandwidth characteristics, the transmitting transducer can accurately reproduce complex excitation signals output by arbitrary waveform generators. The linear amplification excitation module not only needs to possess amplitude linearity in the conventional sense, but also needs to maintain high consistency in phase response, frequency response, and output impedance matching. This ensures that the amplifier can achieve almost distortion-free amplification even when faced with excitation waveforms containing multiple frequency bands or with strict amplitude and phase requirements. In terms of hardware configuration, the linear amplification excitation module includes a high-voltage rail power supply module, a wideband power amplifier stage, an output impedance adjustment network, and protection and control circuitry.
[0064] High-voltage rail power supply module: ensures the peak driving capability required to drive the piezoelectric transducer;
[0065] Wideband power amplifier stage: ensures that the excitation waveform maintains amplitude and phase consistency over a large frequency range;
[0066] Output impedance adjustment network: used to achieve optimal energy matching with the piezoelectric transducer and reduce reflection and energy dissipation;
[0067] Protection circuit: Ensures that the protection circuit and transducer are not damaged under overvoltage and overcurrent conditions.
[0068] The key value of introducing a linear amplification excitation module in this invention lies in freeing the transmitter from the limitations of traditional pulse excitation methods. As the source of acoustic energy, the mechanical vibration characteristics of the transducer are entirely determined by the electrical excitation signal. Therefore, when the excitation signal possesses an adjustable spectral structure, a stable amplitude, and a waveform that can dynamically change according to optimization requirements, the transducer's vibration behavior can fundamentally become controllable and reconfigurable. This controllability allows the waveform optimization process proposed in this invention to truly function: by optimizing the excitation waveform, the received signal automatically presents a stable sine wave or a high signal-to-noise ratio segment, thereby significantly simplifying subsequent signal processing.
[0069] In other words, the linear amplification excitation module is not only the physical foundation of the entire optimization task, but also a prerequisite for the waveform optimizer to achieve its final goal. By introducing higher complexity at the transmitting end, the receiving signal becomes controllable, improving the stability and anti-interference capability of the measurement results. Especially in environments with drastic changes in liquid flow rate, the presence of bubbles or impurities in the pipeline, or minor deviations in the transducer installation, the linear amplification excitation can fully utilize its waveform adjustability, enabling the device to maintain measurement accuracy with greater robustness. In summary, the linear amplification excitation module of this embodiment provides a reliable hardware foundation for the core functions of this invention, ensuring the feasibility and controllability of complex excitation signals, and laying the key technical foundation for subsequent received waveform optimization.
[0070] Since the transmitting transducer in this embodiment uses a piezoelectric transducer, which has obvious capacitive load characteristics, this embodiment employs a high-linearity analog linear power output stage. By keeping the output stage transistors operating in the linear region, high-fidelity amplification of complex waveforms is achieved. This ensures that the amplifier maintains a flat frequency response across the operating frequency range of hundreds of kHz to several MHz. Especially in complex excitation methods such as waveform modulation, frequency scanning, and amplitude envelope control, linear amplification excitation ensures that all details of the excitation signal in the time and frequency domains are fully represented, making the transducer's output mechanical vibration more controllable and predictable.
[0071] In this embodiment, the waveform optimizer, as one of the core modules of the invention, primarily functions to generate a complex excitation signal that meets physical constraints and can produce a stable sinusoidal band at the receiving end. The waveform optimizer uses a processor or digital signal processing unit as its computational center and combines an arbitrary waveform generator as its output actuator. It obtains the optimal excitation waveform by comprehensively calculating the transfer function, the target characteristics of the received signal, and the physical realizability conditions. Unlike traditional ultrasonic flowmeters that rely on simple pulse excitation, this invention introduces an optimization stage at the transmitting end, significantly simplifying the spectrum and waveform structure of the received signal, thereby improving the stability of the entire measurement process.
[0072] The core idea of the waveform optimizer is that since the device can be accurately described by a transfer function within its linear range, the coupling relationship between the excitation and received signals can be established using both forward and backward calculations. However, any desired received signal does not necessarily correspond to a truly realizable excitation signal. Especially when it is desired that the received signal contain a stable sine wave band, it must be ensured that this sine wave band is consistent with the device bandwidth in the frequency domain and can be naturally generated by the transmitting excitation signal. To this end, the waveform optimizer employs a feature-synchronous iterative method based on frequency domain physical realizability constraints: First, a fully realizable initial excitation signal is constructed, typically a standard sine wave with frequency f, amplitude A, and number of periods N. Since any sine wave can be accurately calculated in the device, this initial excitation ensures that the first forward solution yields a physically existing received signal. Subsequently, by setting the target shape of the received signal, such as maintaining a stable amplitude to a target amplitude V for a certain period of time... out This allows for the construction of an ideal target receiving signal.
[0073] The waveform optimizer uses the transfer function to inversely solve the target received signal, obtaining the corresponding corrected excitation signal. Since the target received signal may contain excessively high frequency components in certain frequency bands, the corrected excitation signal needs to undergo frequency domain realizability verification to ensure that its main energy distribution is within the device bandwidth and can be accurately output by any waveform generator in a practical circuit. To achieve a balance between realizability and target effect, the waveform optimizer further introduces optimization algorithms, such as particle swarm optimization, which synchronously iterates parameters such as the excitation signal's spectral distribution and time envelope structure, ensuring that the final excitation signal, while satisfying physical constraints, automatically presents a stable, measurable, and easily analyzable sinusoidal band at the receiver.
[0074] Waveform optimizers can be implemented using various computing architectures, such as MCUs, DSPs, FPGAs, or general-purpose processors. Their software may include a waveform optimization unit (real-time transfer function solving module, optimization solver module, forward and reverse calculation module based on transfer function, waveform shaping module, and feasibility evaluation module) and a waveform output management unit; core steps include... Figure 2 As shown.
[0075] The functions and operation of each module and component within the waveform optimization unit are as follows:
[0076] 1. Real-time transfer function calculation module: This module calculates the transfer function of the current device in real time based on factors such as the measured flow rate of the pipeline and ambient temperature, providing an accurate transfer function for subsequent calculations. The specific process is as follows:
[0077] The input-output relationship is mainly described by the transfer function of the piezoelectric ceramic in its linear operating range. The response transfer function can be obtained through the Chirp signal. :
[0078] ,
[0079] ,
[0080] in, , It represents the time-domain and frequency-domain forms of the received signal excited by the Chirp signal. , It is the time-domain and frequency-domain form of the Chirp signal as the excitation signal. It is time. It represents frequency, and j is the imaginary unit.
[0081] It should be noted that, in the optimization phase, to ensure effectiveness, this invention first uses the Chirp signal to generate the initial excitation signal and calculates the transfer function. It is calculated based on the Chirp signal. Once the transfer function is determined, all subsequent optimization processes will use this transfer function. Even if a periodic signal is generated later with a different waveform, this transfer function will still be used for calculation and processing.
[0082] 2. Optimize the solver module: Utilize optimization algorithms to... Optimize;
[0083] First, we initialize the optimization algorithm, assuming there are i... As a particle swarm, each There are six values to be optimized. Each Each value to be optimized has upper and lower limits, such as the frequency should not exceed the device bandwidth and the amplitude should not exceed the device's maximum received signal, which meet the actual requirements.
[0084] Then, combining the forward calculation module based on the transfer function, the waveform modification module, and the reverse calculation module based on the transfer function, each... Optimization will be performed. The specific optimization process includes:
[0085] To reduce the dimensionality of the search space and improve convergence efficiency while adhering to physical laws, this invention designs a feature quantity in the waveform optimizer that can reconstruct and restore the signal based on its physical characteristics. This extracts features that fully characterize the main energy distribution, amplitude stability, and phase continuity as variables to be optimized. These features naturally conform to the continuity and stability laws of signals, and can retain key physical factors affecting signal formation and propagation while greatly compressing the optimization dimensionality, thus avoiding the dimensionality curse and premature convergence problems that occur in high-dimensional space in particle swarm optimization. Compared with directly optimizing the original signal sample points, this method transforms signal optimization from "point fitting" to "feature pattern matching," which not only significantly improves the algorithm's global search efficiency and physical interpretation but also ensures that the optimization results are feasible and reproducible under transfer function constraints. If feature values are not extracted and the time-domain signal is optimized directly, the following two problems will exist:
[0086] 1) The optimization results cannot satisfy physical laws. When the time-domain signal is directly used as the optimization signal, the number of points to be optimized is often in the tens of thousands. The physical relationships such as the continuity between points need to be clearly described. Otherwise, the time-domain signal cannot satisfy physical laws and there will be a large number of abrupt changes or results that obviously violate physical laws.
[0087] 2) Direct search has too high a dimension, resulting in a large amount of computational overhead and making optimization difficult. Thousands of points are treated as multi-dimensional information particles, while a particle swarm requires hundreds or thousands of such particles. This leads to the particle swarm entering an ultra-high-dimensional problem, making it difficult to optimize to the optimal solution and resulting in excessively long iteration times.
[0088] The selection of features depends on the functional decomposition of the practical problem. Considering the physical constraints and adjustable parameters during signal generation, propagation, and reception, key factors affecting signal morphology are extracted and parameterized. Based on specific application requirements, features that fully describe signal characteristics and are easily processed by the particle swarm optimization algorithm are selected from aspects such as frequency distribution, amplitude stability, phase continuity, and energy concentration. These features reflect the physical realizability of the signal and possess good independence and sensitivity, enabling the optimization process to accurately capture device response changes in low-dimensional space. This significantly improves the algorithm's search efficiency and result stability while ensuring physical rationality.
[0089] 3. Forward computation module based on transfer function: According to The frequency f, amplitude A, and excitation period N generate a corresponding periodic signal (such as a sine wave, square wave, etc.), which is the excitation signal. The received signal is then solved based on the transfer function.
[0090] The specific process of solving the received signal based on the transfer function includes:
[0091] Reconstruct the initial signal in the time domain based on the waveform characteristics (frequency, number of periods, amplitude) of the input signal corresponding to each feature vector. In some embodiments, if the selected signal is a sine wave, That is:
[0092] ,
[0093] Based on time domain signal The frequency domain transformation result can be used to obtain the corresponding frequency domain signal. :
[0094] ,
[0095] in, Frequency domain transformation.
[0096] Based on transfer function ,Will As the frequency domain value of the input signal (excitation signal), the frequency domain value of the received signal is calculated in the forward direction based on the transfer function. The time domain of the received signal can be obtained by inverse frequency domain transformation. .
[0097] ,
[0098] in, Inverse frequency domain transform.
[0099] 4. Waveform Modification Module: Based on a single... The corresponding received signal stability characteristics, in this embodiment, are the signal stability amplitude start time t. s End time t e and amplitude V out The received signal calculated by the forward calculation module based on the transfer function is modified, and its t is... s to t e The signal amplitude in the interval is corrected to an amplitude of V. out The sine wave, this process is denoted as the function Receive new signals .
[0100] 5. Inverse calculation module based on transfer function: The modified received signal in the waveform modification module is solved for the modified excitation signal using a transfer function;
[0101] The specific process of solving for the modified excitation signal using the transfer function includes:
[0102] Time domain frequency domain obtained by transformation Then, through the transfer function Inverse calculation of the frequency domain of the excitation signal under a certain eigenvector And the signal after inverse frequency domain transformation of the signal ;
[0103] ,
[0104] 6. Feasibility Assessment Module: Based on the energy tail of the modified excitation signal and the amplitude V of the modified received signal. out The reciprocal of the magnitude and the reciprocal of the magnitude are used as the objective function of the optimization algorithm. During the optimization process, the optimal solution is the one with the smaller tail energy and the smaller (larger) reciprocal of the magnitude.
[0105] The specific process of feasibility assessment includes:
[0106] calculate Signal energy distribution and modification of received signal The magnitude of the modified region, used as an evaluation term in the particle swarm optimization algorithm, can efficiently determine whether the optimization result is physically achievable, i.e., define the optimization objective:
[0107] ,
[0108] ;
[0109] In the formula, To optimize the objective function; N / f refers to The total length, and the integration interval is Nine times the total length of the time interval beyond the normal length of the excitation signal. In other words, the main purpose of optimizing the objective function is to statistically analyze the energy distribution over a long interval beyond the normal length of the excitation signal to determine its physical feasibility. Normally, the energy in this interval should be zero, but due to numerical calculations and the infeasibility of some solutions, a large amount of extra energy appears in this interval, which is undesirable. Therefore, the feasibility of the solution can be determined by constraining the energy distribution.
[0110] The smaller the objective function, the less energy distribution of the excitation signal in the irrelevant interval, the more concentrated the energy distribution within the transducer bandwidth, and the more stable the output signal. The final result is determined based on the optimization results. This is the excitation signal obtained from the design.
[0111] 7. Waveform Output Management Unit: Responsible for sending the waveform of the final excitation signal to the waveform generator.
[0112] The final output of the waveform optimizer is a complex but structurally controllable excitation waveform, whose spectral characteristics strictly correspond to the stable band required by the receiver. Since the excitation signal is derived from the device's transfer function, it ensures higher repeatability and stability of the received waveform. Especially in complex practical conditions such as flow velocity variations, noise interference, and medium density fluctuations, stable reception of the sinusoidal band significantly improves the accuracy of ultrasonic time-of-flight measurement, making processes such as cross-correlation algorithms, phase difference extraction, and time delay estimation more reliable. Through this method, the invention not only improves the signal-to-noise ratio of the received signal but also reduces reliance on complex filtering algorithms and digital compensation methods, simplifying and enhancing both the hardware implementation and software processing of the entire device. In summary, the waveform optimizer establishes a controllable, iterative, and physically sound optimization mechanism at the transmitting end, providing key technical support for achieving high-precision and high-stability ultrasonic flow measurement. The complex waveform calculated by the waveform optimizer is output through an arbitrary waveform generator circuit. Since the signal from the arbitrary waveform generator is insufficient to drive the piezoelectric ceramic vibration, a linear amplification excitation stage is required.
[0113] The process of optimizing the excitation signal of the flow measurement device using the particle swarm optimization algorithm is as follows:
[0114] S1, the real-time transfer function solving module applies the excitation Chirp signal to the transducer and amplifies it by a linear amplifier. It calculates the system's transfer function by using the excitation Chirp signal and the received signal. This process will be run again after a complete optimization procedure is completed, with the aim of providing the real-time transfer function for subsequent steps.
[0115] S2, the optimization solver module, the forward and reverse calculation module based on the transfer function, the waveform modification module, and the feasibility evaluation module are executed. The feasibility evaluation module assesses whether the current optimization round can end. If not, optimization continues according to the update mechanism. To further improve convergence efficiency, inertia weights are used. It typically decreases linearly with the number of iterations or adjusts adaptively. In the initial stage, a larger... This value ensures a sufficiently large search step size, thereby enhancing global exploration capabilities; in later stages, a smaller step size... This refinement of the search gradually promotes the algorithm's convergence to the global optimum. Furthermore, during the update of individual particle swarm velocities and positions, all parameters are subject to preset boundary constraints, ensuring that the generated signal parameters are physically realizable and meet design requirements.
[0116] After the particle swarm approaches the optimal region, a local optimization mechanism is introduced to perform a hybrid search. This aims to achieve the global optimum. Starting from a point, a constrained optimization model is established, and the search is further refined in the continuous space by using the projection gradient or quadratic programming method, thereby approximating the optimal solution in the continuous space.
[0117] S3. The final optimized signal is output through the waveform output management unit, and then the transducer is excited by the power linear amplification excitation module. The signal processing unit collects the received signal and calculates the flow rate. This completes one optimization and acquisition cycle, and step S1 is executed again.
[0118] In this embodiment, a signal generator (AFG31000) is used to generate a signal, which is then amplified by a self-made linear power amplifier to a peak value of 40Vpp. The excitation signal is input into the transducers on both the left and right sides. The generated ultrasonic signal is received by the central M-type transducer after multiple reflections within the pipe. After filtering, it is amplified (DPR300, Gain=61dB) and the signal is acquired using an oscilloscope.
[0119] To measure the transfer function, the designed chirp signal parameters were: 15µs, 1MHz to 6MHz. The frequency selection of the chirp signal is related to the piezoelectric ceramic transducer used; generally, its center frequency is the resonant frequency of the piezoelectric ceramic. The piezoelectric ceramic resonant frequency used in this invention is 4MHz, and considering bandwidth, the above-mentioned sweep frequency range was ultimately selected.
[0120] After obtaining the transfer function, according to the needs of the genetic algorithm, the upper and lower bounds of six quantities are defined for the first input signal frequency, the excitation length of the first input signal, the amplitude of the input signal, the starting position of the sine wave in the optimized output signal, the ending position of the sine wave in the optimized output signal, and the amplitude of the sine wave in the optimized output signal. It is required that all six characteristic quantities are integers (amplitude unit is millivolt).
[0121] The results are as follows Figure 3 , Figure 4 , Figure 5 As shown, the optimized excitation signal is in Figure 3 The difference is limited in the time domain, but... Figure 4 The difference in the frequency domain is significant, therefore making Figure 5 The results show that the envelope stability of the received signal is significantly improved. By comparing the unoptimized and optimized waveforms, it can be found that the fluctuation amplitude of each period peak in the stable section is significantly reduced, and the peak difference is basically controlled within 1% of the overall amplitude. The signal exhibits a continuous and smooth periodic waveform in the time domain, the envelope tends to be constant, and harmonic components are effectively suppressed in the frequency domain, with the main frequency energy concentrated within the effective bandwidth.
[0122] The above examples of the present invention are merely illustrative of the computational model and process of the present invention, and are not intended to limit the implementation of the present invention. Those skilled in the art will recognize that other variations or modifications can be made based on the above description. It is impossible to exhaustively list all possible implementations here. Any obvious variations or modifications derived from the technical solutions of the present invention are still within the scope of protection of the present invention.
Claims
1. An ultrasonic flow measurement device based on a transfer function waveform optimizer, comprising a transmitting transducer and a receiving transducer, characterized in that, The device further includes: Waveform optimizer: Optimizes the excitation waveform and outputs the excitation signal through the waveform generator to make the output signal of the receiving transducer present a stable sine segment and / or a high signal-to-noise ratio segment; Linear amplification excitation module: linearly amplifies and excites the output signal of the waveform generator, enabling the transmitting transducer to reproduce the excitation signal output by the waveform generator; The waveform optimizer includes a waveform optimization unit for waveform optimization and a waveform output management unit responsible for sending the final waveform; wherein the waveform optimization unit includes: Real-time transfer function calculation module: used for real-time calculation of transfer functions; Optimization Solver Module: Combining the results from the forward and reverse calculation module based on transfer function, the waveform modification module, and the realizability evaluation module, it utilizes optimization algorithms to optimize the parameter vector of the value to be optimized. Optimization is performed, and during the optimization process, the solution with the smallest tail energy and the smallest reciprocal of the amplitude is selected as the optimal solution based on the objective function of the feasibility assessment module; the parameter vector to be optimized. The elements in the equation include the waveform characteristics of the excitation signal and the stability characteristics of the output signal. The forward calculation module based on the transfer function generates a corresponding periodic signal as the excitation signal based on the waveform characteristics of the excitation signal, and solves for the output signal based on the transfer function. Waveform modification module: based on The stability characteristics of the corresponding output signal are used to modify the output signal calculated by the forward calculation module based on the transfer function, resulting in a new time-domain signal, i.e., the modified output signal. The inverse calculation module based on the transfer function: solves the modified excitation signal by using the transfer function to solve the modified output signal in the waveform modification module; Feasibility assessment module: Based on the energy tail of the modified excitation signal and the amplitude V of the modified output signal itself. out The reciprocal of the value is used as the objective function of the optimization algorithm. During the optimization process of the solver module, the solution with the smaller tail energy and the smaller the reciprocal of the magnitude is selected as the optimal solution.
2. The ultrasonic flow measurement device based on a transfer function waveform optimizer according to claim 1, characterized in that, During the process of optimizing the excitation waveform by the waveform optimizer, the initial excitation signal is the Chirp signal.
3. The ultrasonic flow measurement device based on a transfer function waveform optimizer according to claim 2, characterized in that, The transfer function is , , ,in , It represents the time-domain and frequency-domain forms of the received signal excited by the Chirp signal. , It is the time-domain and frequency-domain form of the Chirp signal; It is time. It represents frequency, and j is the imaginary unit.
4. The ultrasonic flow measurement device based on a transfer function waveform optimizer according to claim 3, characterized in that, The forward calculation module based on the transfer function solves for the output signal based on the transfer function. The process includes: Periodic signal generated based on the waveform characteristics of the excitation signal The form is in the time domain, and the corresponding frequency domain form is obtained through frequency domain transformation. According to the transfer function Obtain the frequency domain form of the output signal The time-domain form of the output signal is obtained through inverse frequency domain transform. .
5. The ultrasonic flow measurement device based on a transfer function waveform optimizer according to claim 4, characterized in that, The process by which the inverse computation module based on the transfer function solves for and modifies the excitation signal includes: The waveform shaping module is used to obtain a new time-domain form. Transform to the frequency domain to obtain the signal in frequency domain form. Then through the transfer function Inverse calculation of the frequency domain form of the excitation signal The time-domain form of the excitation signal obtained through inverse frequency domain transformation. .
6. The ultrasonic flow measurement device based on a transfer function waveform optimizer according to claim 5, characterized in that, The objective function of the optimization algorithm is as follows: , , In the formula, To optimize the objective function; N / f refers to Total length, The integration interval is Nine times the total length of time; V out This is the amplitude of the output signal itself.
7. The ultrasonic flow measurement device based on a transfer function waveform optimizer according to claim 6, characterized in that, The waveform characteristics of the excitation signal include frequency f, amplitude A, and number of excitation cycles N.
8. The ultrasonic flow measurement device based on a transfer function waveform optimizer according to claim 7, characterized in that, The stability characteristics of the output signal include the start time t of the stable amplitude. s End time t e and amplitude V out .
9. An ultrasonic flow measurement device based on a transfer function waveform optimizer according to any one of claims 1 to 8, characterized in that, The linear amplification excitation module includes: High-voltage rail power supply module: ensures the peak driving capability required to drive the piezoelectric transducer; Wideband power amplifier stage: ensures that the excitation waveform maintains amplitude and phase consistency over a large frequency range; Output impedance adjustment network: used to achieve optimal energy matching with the piezoelectric transducer and reduce reflection and energy dissipation; Protection circuit: Ensures that the protection circuit and transducer are not damaged under overvoltage and overcurrent conditions.