Next Article in Journal
Real-Time Optimal States Estimation with Inertial and Delayed Visual Measurements for Unmanned Aerial Vehicles
Previous Article in Journal
Adaptive DCS-SOMP for Localization Parameter Estimation in 5G Networks
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Ultrasonic Thickness Measurement Method and System Implementation Based on Sampling Reconstruction and Phase Feature Extraction

Hubei Key Laboratory of Modern Manufacturing Quantity Engineering, College of Mechanical Engineering, Hubei University of Technology, Wuhan 430068, China
*
Author to whom correspondence should be addressed.
Sensors 2023, 23(22), 9072; https://doi.org/10.3390/s23229072
Submission received: 9 October 2023 / Revised: 27 October 2023 / Accepted: 6 November 2023 / Published: 9 November 2023
(This article belongs to the Section Physical Sensors)

Abstract

:
The existing ultrasonic thickness measurement systems require high sampling frequencies for echo signal acquisition, leading to complex circuit designs and high costs. Moreover, extracting the characteristics of ultrasonic echo signals for accurate thickness measurement poses significant challenges. To address these issues, this paper proposes a method that utilizes conventional sampling frequencies to acquire high-frequency ultrasonic echo signals, overcoming the limitations of high-frequency data acquisition imposed by the Nyquist–Shannon sampling theorem. By employing an improved sampling reconstruction technique, the multi-cycle sampling signals are reconstructed and rearranged within a single cycle, effectively increasing the equivalent sampling frequency. Additionally, a combination of coarse estimation using fast Fourier transform (FFT) and precise phase extraction using the moving sine fitting algorithm is proposed for accurate thickness measurement, resolving the limitations of common thickness measurement methods such as peak detection, envelope detection, and Hilbert autocorrelation in terms of low measurement accuracy. Experimental results obtained from thickness measurements on 45 steel ultrasonic test blocks within the range of 3 mm to 20 mm indicate a measurement error of ±0.01 mm, while for thicknesses ranging from 1 mm to 50 mm, the measurement error is ±0.05 mm.

1. Introduction

Ultrasonic penetration ability, applied to metal thickness measurement [1], has the characteristics of low cost, fast speed, and high accuracy [2]. For the aerospace and nuclear industries and other harsh environments or high-risk areas in the use of pressure vessels [3], process equipment, and other structures and components, the use of ultrasonic wall thickness measurement is timely and feasible [4,5]. It provides an effective basis for the components of the operational reliability of the judgment in the service life [6,7].
The ultrasonic frequency is high, and general thickness measurement using the ultrasonic probe is between 0.5 and 15 MHz [8]. The current ultrasonic thickness measurement system requires a specialized high-speed AD sampling chip and FPGA controller [9]. It makes the system complex and adds unnecessary burden and cost. In addition, the accuracy of ultrasonic thickness measurement relies on the time of flight (TOF) [10] in ultrasonic thickness measurement, i.e., the accuracy of ultrasonic echo signal period extraction. The simplest way to determine the TOF is to set a fixed threshold, the time difference between the moment when the echo signal amplitude exceeds the threshold for the first time and the initial moment of the excitation signal. It is simple to compute but affected by the size of the set threshold; the estimation error is large and cannot be modeled for analysis.
Kim Y H utilizes the peak method for thickness measurement [11]. The peak method searches for the maximum peak point of the echo signal in all time domains. Calculating the distance between two neighboring peaks. The corresponding time is the TOF. This method is susceptible to noise and external interference, resulting in a shift of the maximum peak searched for, a large measurement error, and a decrease in accuracy. The literature [12] proposed the envelope peak method. The echo signal envelope fitting is processed through the measurement of the neighboring envelope peak distance to derive the TOF. Avoiding the impact of noise on the measurement accuracy, but there is the disadvantage that searching for the peak position is not permitted when the amplitude of the envelope signal is close to the shortcomings. Zhou Qianqian [13] proposed the Hilbert autocorrelation algorithm to process the echo signal, using the Hilbert transform to extract the features and then autocorrelation to find the TOF to improve the measurement accuracy.
In view of the above two problems, this paper proposes an ultrasonic thickness measurement processing method with sample reconstruction and FFT rough estimation [14]. Using the FFT algorithm to calculate the peak point of amplitude-frequency characteristics, the frequency of the sampled signal can be roughly estimated. The phase is accurately extracted by the moving sine fitting algorithm. The purpose of ultrasonic thickness measurement can be realized by using only the low-frequency AD sampling function inside the STM32F407 mi-processor (STMicroelectronics, Switzerland) and the developed moving sine fitting algorithm. The limitations of high-frequency sampling required to acquire ultrasonic echo signals and the defects of low accuracy and poor stability of the traditional direct calculation of workpiece thickness by peak point position characteristics are solved. The cost-effectiveness of the ultrasonic thickness measurement system is demonstrated.

2. Improved Sampling Reconstruction Technique

Sampling reconstruction can generally be divided into two sampling methods: sequential sampling reconstruction [15] and random sampling reconstruction [16]. The ultrasonic thickness measurement system sampling method using improved sampling reconstruction technology involves setting the sampling frequency and excitation frequency, determining a fixed number of excitation cycles and the total number of sampling points to achieve continuous acquisition of sampling points, and reordering the sampling points to complete the signal reconstruction. To meet the purpose of the improved sampling reconstruction technique, the excitation frequency f e of the ultrasound probe and the sampling frequency f s of the ultrasound signal should meet the following requirements:
n f s = m f x n T s = m T x
where n and m are prime numbers of each other, n is the total number of sampling points, m is the number of ultrasonic excitation signal cycles, T s is the sampling period of the signal, and T x is the excitation signal period. Consequently, it is necessary to ensure that the total time of the n sampling cycles is equal to the total time of the m excitation signal cycles. The sampling period of the improved sampling reconstruction technique is much smaller than the excitation period, and the sampling period of the sequential sampling reconstruction is the sum of the excitation cycle time and the step increment delay time, which is set to be larger than the excitation cycle time. The signal reconstruction is accomplished by synthesizing n points sorted into one signal cycle through the reconstruction sorting algorithm, in which the important parameters m, n, T s , and T x need to be set according to the system clock of the STM32F407 microprocessor following the improved sample reconstruction formula. The sampling reconstruction frequency f s e is shown in Equation (2).
f s e = n f x = m f s
Compared with the original ultrasound signal sampling frequency, sampling reconstruction frequency increases by a factor of m. It can meet the requirements of periodic high-frequency signal sampling. The principle of the improved sampling reconstruction is shown in Figure 1.
In the above figure, each ultrasonic excitation cycle contains multiple gradually attenuated ultrasonic echo signals. The thickness measurement system in the STM32F407 microprocessor set parameters m, n, T s , T x should meet the improved sampling reconfiguration of Equation (1), so m excitation cycle contains exactly n sampling points, and m and n reciprocity to ensure that n sampling points are not duplicated to be uniformly inserted into a signal excitation cycle can be synthesized into a complete high-frequency signal cycle.
Figure 2, for example, shows the basic principle of the signal reconstruction algorithm, assuming that the sampling points are collected once every 75° interval, the original periodic signal is one cycle for every 360° interval, the total number of sampling points is 24, and the number of signal cycles is 5, which meets the requirements of the improved sampling reconstruction formula, and the sampling points can be synthesized completely into one cycle, but the sequence of sampling points is not sequential, and the sampling points are needed to be synthesized into one cycle. However, the sequence of sample points is not sequential, and it is necessary to sort the sample points synthesized into a signal cycle. The signal reconstruction schematic is shown in Figure 2.
The transformation of the original sampled data sequence to the rearranged sampled data sequence in the figure is obtained according to the reconstruction algorithm, whose specific derivation formula is shown in (3):
r * = r m r m n · n y r * = x r
where r * is the rearrangement sequence number of the signal, r is the sequence number of the sampled signal, from 0 to n − 1 sequential sequence. m is the number of signal cycles, n is the total number of sampling points, [] is the sign of downward taking an integer, the rearrangement sequence signal is y r * , and the sampling sequence signal is x r .
Due to the jitter in the sampling and excitation clocks of the microprocessor [17], it is difficult to ensure that the initial position of the sampling clock is synchronized with the initial position of the excitation signal. The position of the initial sampling point is random, and the reconstructed signal will be distorted. As shown in Figure 3, the maximum point is found based on the echo peak feature. The distorted signal is recombined by feature-point translation. The ultrasonic echo signal characteristics within the signal period are effectively recovered. The accuracy of the ultrasonic echo signal is guaranteed.
In the figure, T is the ultrasonic emission wave, and B 0 , B 1 , and B 2 are the first ultrasonic echo, the second ultrasonic echo, and the third ultrasonic echo in the ultrasonic echo signal, respectively.
Through the above analysis, the effect of fast sampling can be achieved by simply setting the relative sampling frequency and excitation frequency, as well as determining the number of sampling points and the number of signal cycles. Compared with the traditional sampling reconstruction method, the sampling efficiency is higher and faster.

3. Thickness Measurement System Hardware Design

3.1. Hardware System Design

The overall design of the hardware circuit for ultrasonic thickness measurement is shown in Figure 4. The actual circuit diagram of the experiment is shown in Figure 5. It mainly includes the STM32F407 minimum system circuit, external SRAM circuit, power supply circuit, ultrasonic transmitter–receiver circuit, limiter circuit, analog multiplier circuit, programmable amplifier circuit, sampling circuit, and touch display circuit.
Among them, the STM32F407 minimum system is the core of the thickness measurement system. It is mainly responsible for running the program, realizing the excitation pulse (PWM pulse) generation, and collecting and storing the echo signal. Using a noise reduction algorithm and a moving sine fit phase feature extraction algorithm to measure the thickness of the object. And then transmitting the measured results to a touchscreen display via the USART communication protocol. The external SRAM circuit is mainly used to expand the memory for the programmed embedding of the wavelet threshold noise reduction algorithm, FFT, and moving sine fitting algorithm. The power management module is mainly responsible for managing the system voltage distribution. The output 400 V DC voltage is used as the excitation voltage of the ultrasound probe. Output 5 V is the working voltage of the touch panel display. Output 3.3 V is the working voltage and reference voltage of the STM32F407 microprocessor. The ultrasound transmitter–receiver circuit is used to control the ultrasound probe operation as well as the ultrasound signal transmitting and receiving. The limiter circuit is to reduce the amplitude of the received echo signal to protect the circuit. The analog multiplier circuit is the ultrasonic echo signal self-multiplication process, the alternating ultrasonic signals into pulsating DC signals conducive to echo signal acquisition. The programmable amplifier circuit amplifies the weak echo signals, the sampling circuit samples and reconstructs the echo signals, and the touch panel display facilitates man-machine operation, the issuance of commands, and the direct display of measurement results.

3.2. Analog Multiplier Circuit

The analog multiplier circuit [18] mainly consists of the multiplier chip AD835 and its peripheral circuits to self-multiply the ultrasound echo signal. The alternating ultrasound signal into a pulsating DC signal is the main role of two points. The first is to self-multiply the ultrasonic echo signal to provide a basis for the subsequent FFT rough estimation algorithm and reduce the arithmetic pressure of the main control chip. The second is that the sampling amplitude of the echo signal can be increased to facilitate signal sampling.
Low-frequency samplers have the nature of a smoothing filter. Direct sampling of the original alternating high-frequency ultrasound echo signal results in a sampled signal with amplitude attenuation. Using ultrasonic echo signal modeling to create simulation comparisons, the sampling amplitude of the original signal and the self-multiplying sampled signal changes, as shown in Figure 6 and Figure 7.

4. System Software Design and Implementation

4.1. System Software Design Process

The system software design flow is shown in Figure 8. In the thickness measurement system, the host computer is set up to meet the sampling reconstruction requirements of the excitation frequency f x and sampling frequency f s and other parameters, sent to the lower computer STM32F407, to control the lower computer to produce excitation signals for sampling reconstruction and noise cancellation processing, the use of moving sine fitting algorithms to extract the phase characteristics of the signal, and derive the workpiece under test TOF. Based on the calibrated speed of sound, the thickness of the workpiece is calculated, and the result is transmitted to the touch-screen display of the host computer for display.

4.2. Wavelet Noise Reduction Method for Ultrasound Echo Signals

In the ultrasonic thickness measurement process, the system power supply perturbation and external interference will introduce noise to the ultrasonic echo signal [19]. To improve the accuracy of ultrasonic thickness measurement and reduce the impact of noise on the ultrasonic echo signal, there needs to be noise reduction on the echo signal. General noise reduction methods include hardware noise reduction [20] and digital processing noise reduction [21]. Hardware noise reduction for the device performance requirements is high, and the cost is expensive. At this stage, digital signal processing echo noise reduction technology has matured, and the wavelet noise reduction method [22] has a good noise reduction effect and is widely used.
The noise-containing signal is wavelet decomposed into a low-frequency approximation part and a high-frequency detail part. The useful signal is located in the low-frequency part. The noise signal is located in the high-frequency detail part. The wavelet-decomposed high-frequency detail coefficients are subjected to threshold quantization and wavelet reconstruction with the low-frequency approximation coefficients to realize wavelet threshold noise reduction, the principle of which is shown in Figure 9.
According to the characteristics of the ultrasonic echo signal in this paper, the dbN orthogonal wavelet is selected as the wavelet function in the threshold noise reduction algorithm. The selection of the threshold value in the wavelet threshold noise reduction method plays a crucial role. If the threshold is too large, the mixed noise cannot be eliminated, and the noise reduction effect is poor. There are several commonly used thresholding methods.
Fixed threshold (Sqtwolog rule) with the threshold derivation formula shown in (4).
λ s = σ 0 2 ln N σ 0 = m e d d 1 , k 0.6745
where σ 0 is the noise standard deviation, N is the signal length, med is the median, and d 1 , k is the sequence of wavelet coefficients in the first layer.
The unbiased risk estimation threshold (Rigrsure rule), based on the principle of unbiased likelihood estimation, has a threshold derivation formula shown in (5).
λ r = σ 0 m i n N 2 k + r 1 , k 2 + N k r 1 , k 2 N k = 1 , 2 , 3 , , N
where r 1 , k is the ascending order of the wavelet coefficients of the first layer.
The maximum–minimum criterion threshold (Minimaxi rule) is selected concerning the noise standard deviation, and its threshold derivation formula is shown in (6).
λ m = σ 0 0.3936 + 0.1829   log 2 N                                                           N > 32 0                                                                                                                                                       N 32
The heuristic threshold (Heursure rule), which is the preferred choice between a fixed threshold and an unbiased risk estimation threshold, has a threshold derivation formula shown in (7).
λ n = λ s                                                                                                   d 1 , k N < log 2 N N 3 2 min λ s , λ r                                                                   d 1 , k N < log 2 N N 3 2
Multi-resolution thresholding is an improvement over fixed thresholding. The wavelet decomposition process, wavelet coefficients, and noise signals are affected by the number of decomposition layers, and the threshold derivation formula is shown in (8).
λ i = σ 2 ln l e n g t h d i , k ln i + 1 σ = m e d d i , k 0.6754
where i is the number of decomposition layers, length is the length, and d 1 , k is the sequence of wavelet coefficients in the ith layer.
Based on the root-mean-square error (RMSE) and signal-to-noise ratio (SNR) of the noise-canceled signal as an evaluation criterion, the equations are shown in (9) and (10).
R M S E = y n y n * 2 N
S N R = 10 lg y n 2 y n y n * 2
The smaller the root-mean-square error (RMSE) of the noise-canceled signal, the better the noise-canceling effect; the larger the signal-to-noise ratio (SNR), the better the noise-canceling effect; and vice versa.
In the actual ultrasonic thickness measurement, the ultrasonic echo signal is mixed with noise. To simulate the actual echo signal, random Gaussian white noise is added to the ideal single echo signal, and the model of the simulated mixed-noise echo signal is shown in Equation (11).
y t = s θ ; t + v t
where s θ ; t is the single echo and v(t) is the Gaussian white noise, and the specific echo of Gaussian white noise with 10 dB added is shown in Figure 10.
The above single-echo signal model can be deduced from the multiple-echo signal; each time the reflected wave is received, it is gradually attenuated, and the amplitude is getting smaller and smaller. Considering this layer of the problem, the multiple-echo model is shown in Equation (12).
y r t = m = 1 M s θ ; t + v t
where M is the number of echo signals and s θ ; t is the mth echo waveform.
Keeping the above single-echo eigenvector parameters unchanged, setting the attenuation factor to 0.6 and the time interval = 4 μs, the simulated ultrasound echo signal is shown in Figure 11.
Based on [23], wavelet 5-layer decomposition is chosen to simulate the above five thresholding methods, and the simulation results are shown in Figure 12. The root mean square error (RMSE) and signal-to-noise ratio (SNR) are calculated, and the results are shown in Table 1.
According to Table 1, it can be seen that the multi-resolution thresholding method has the smallest root-mean-square error (RMSE) and the largest signal-to-noise ratio (SNR), and the signal noise reduction effect is better than other thresholding methods. Therefore, multiresolution thresholding as the wavelet threshold was selected.

4.3. Algorithm for Feature Extraction of Echo Signals

After noise reduction of the echo signal using wavelet multiresolution thresholding, the signal has a high signal-to-noise ratio, and this paper proposes an algorithm to accurately extract the phase information of the echo signal. Extracting the phase information via FFT rough estimation of the signal and shifted sine fitting. Then TOF is calculated from the phase difference of the feature positions.

4.3.1. FFT Rough Estimation Algorithm

The fast Fourier transform (FFT) algorithm is commonly used for spectral simulation and analysis of signals, using a time-to-frequency domain signal processing method to obtain a discrete sequence of equally spaced samples containing frequency components [24]. To extract the frequency components of the low-frequency part of the ultrasonic echo signal, the direct FFT processing of the ultrasonic echo signal cannot determine the location of the low-frequency frequency components, while the self-multiplied ultrasonic echo signal can be decomposed to clarify the location of the low-frequency, and the decomposition of the specific self-multiplied equivalent ultrasonic echo modeling decomposition formula is shown in (17).
X t = f 2 t = f m 2 φ · cos 2 2 π f l t · cos 2 2 π f h t · f 2 α
Since f m φ and f α are pulse constant signals and attenuation factors, it can be simplified as:
X * ( t ) = cos 2 2 π f l t cos 2 2 π f h t = 1 + cos ( 4 π f l t ) 2 1 + cos ( 4 π f h t ) 2 = 1 4 + cos ( 4 π f l t ) 4 + cos ( 4 π f h t ) 4 + cos ( 4 π f l t ) cos ( 4 π f h t ) 4 = 1 4 + cos ( 4 π f l t ) 4 + cos ( 4 π f h t ) 4 + cos ( 4 π f l t 4 π f h t ) 8 + cos ( 4 π f l t + 4 π f h t ) 8
The low-frequency frequency f l in Equation (14) is in the second sequence in the decomposition equation. Thus, the FFT transform of the self-multiplying ultrasound echo signal determines that the low-frequency spectral position is at the position of the extreme value point after the constant.
The self-multiplying equivalent ultrasound echo signal of length N is selected for the FFT transform, and the resulting spectrogram is shown in Figure 13.
The position of the frequency point corresponding to the low-frequency harmonics of the ultrasound echo is determined as k by the decomposition formula in the figure, and the formula for calculating the low-frequency frequency f l of the FFT is deduced based on the position of this frequency point as shown in (19).
f l = k · f s e N
In the formula, f s e is the sampling reconstruction frequency, and N is the number of sampling points. From the above formula, it can be seen that the accuracy of low-frequency frequency calculation is affected by the sampling frequency and the number of sampling points. In the case of a certain sampling frequency, it can only increase the length of the window and deal with a large number of sampling points, which is not high in real-time, and the accuracy is poor when the FFT algorithm is used directly to count the low-frequency frequency. Therefore, in this paper, the moving sine fitting is used to accurately calculate the echo characteristic phase information and then accurately calculate the low-frequency frequency and period.
Since the moving sine fitting algorithm is used, the phase interval of the fitted sequence needs to be known. Therefore, the FFT algorithm was used to roughly estimate the ultrasound echo low-frequency harmonics, and the phase interval δ was calculated based on the echo low-frequency harmonics, as shown in (20).
δ = 2 π k N

4.3.2. Calculation of the Wrap Phase of a Moving Sine Fit

A segment-by-segment shifted sinusoidal fit yields information on the magnitude and phase of points in the sampled sequence of points, except for one cycle of boundary loss [25]. The essence of shifted sine fitting is to obtain the amplitude and phase of the fundamental frequency harmonics at various points in the return signal. If the ultrasound echo sequence is y ( i ) , the qth sequence of segment length l is expressed as { y ( q ) , y ( q + 1 ) , , y ( q + l 1 ) } and a sine fit to it yields the amplitude A(q) and the initial phase φ(q) of the segment, respectively:
A ( q ) = a q 2 + b q 2 φ ( q ) = a t a n 2 ( b q , a q )
where a q and b q are calculated as follows:
a q b q c q = Q 0 1 i = q q + l 1 y ( i ) sin ( i δ ) i = q q + l 1 y ( i ) cos ( i δ ) i = q q + l 1 y ( i )
Here the matrix Q 0 is a constant symmetric matrix:
Q 0 = i = 0 l 1 sin 2 ( i δ ) i = 0 l 1 1 2 sin ( 2 i δ ) i = 0 l 1 sin ( i δ ) i = 0 l 1 1 2 sin ( 2 i δ ) i = 0 l 1 cos 2 ( i δ ) i = 0 l 1 cos ( 2 i δ ) i = 0 l 1 sin ( i δ ) i = 0 l 1 cos ( 2 i δ ) 1
According to the characteristics of the symmetry of the sinusoidal signal period, the fitting of the whole period sampling points has a higher accuracy. Therefore, the segment length adopted for segment-by-segment shifted sinusoidal fitting should be as close as possible to the cycle length of the ultrasonic echo signal, and here the segment length of the fitting can be designed according to the interval phase calculated by Equation (16):
L = [ 2 π δ ]
Moving sine fitting is computationally intensive and can be greatly reduced if recursion is used for the cumulative sum operation in Equation (7) [25].
Considering that the initial phase sequence ϕ ( q ) sought in Equation (6) is the wrapped phase, the unwrapped phase can be obtained as ϕ ( q ) by the unwrapping operation. A least-squares linear fit to the data set [ q ,   ϕ ( q ) ] is performed, i.e., the following equation is satisfied:
ϕ ( q ) = s 1 q + s 0
After the straight line fitting calculating the fitted slope parameter s 1 , the refined estimation of the ultrasound echo signal time difference is:
T e = 2 π · T x n · s 1
The thickness of the workpiece is:
H = π T x n · s 1 · v s
v s is the velocity of ultrasonic propagation.

4.3.3. Calculation of TOF

The computer extracts the phase information through the forward and inverse functions. The phase information is 0~π in one and two quadrants and −π~0 in three and four quadrants, and it will jump in two and three quadrants. The value of the phase information φ x is constrained to be between (−π~π), which is discontinuous, and it is called the wrapped phase. The wrapped phase of the echo-sampled signal is shown in Figure 14.
Therefore, the phase needs to be subjected to the unwrapping operation. The specific solution algorithm for serializing the wrapped phase is shown in Equation (28).
φ i = φ i 1 + W i
where W i defines the unwrapping operator:
W i = φ i φ i 1 2 π                                                                                   φ i φ i 1 > π   φ i φ i 1 + 2 π                                                                             φ i φ i 1 < π φ i φ i 1                                                                             π < φ i φ i 1 < π
The period of the ultrasound echo is calculated by the phase difference and time difference of the characteristic positions of the echo, as shown in (30).
T l = 2 π · m 2 m 1 φ m 2 φ m 1 · f s e
where m 1 , m 2 are the points at the characteristic positions, i.e., the two positions corresponding to the zero phase in 19. φ m 2 , φ m 1 are the phases corresponding to the unwrapped phase, and f s e is the sampling reconstruction frequency. The TOF of the ultrasound echo is T l .

5. Ultrasonic Thickness Measurement Results and Analysis

5.1. Velocity of Sound Calibration and Calculation of TOF

According to the sampling reconstruction technique, it can be seen that the size of the sampling period T s and the excitation period T x are set by the internal system timer; the excitation period is T x = R 1 /144 M. The sampling period is T s = R 2 /144 M. The setting of the sampling period must be greater than 0.41 μs and satisfy the improved equivalent Equation (1), in which it is known that the number of sampling points n, the number of sampling periods m, and the counter accumulator R 1 and R 2 setting values satisfy the following relationship:
m · R 1 = n · R 2
Three thicknesses of 45 steel-stepped specimens were selected to calculate TOF and calibrate the speed of sound. Thickness measurements were carried out on specimens with calibrated thicknesses of 3.010 mm, 10.003 mm, and 24.047 mm. The calibrated thickness of 3.010 mm was used as an example.
The first is to set the parameters R 1 = 18,000 , R 2 = 67 , m = 67 , n = 18,000 . According to Formula (2), it can be seen that the sampling reconfiguration frequency f s e = 144   M H z , the sampling frequency is relatively increased by 67 times. ADC sampling of ultrasound echo signals can be realized. Obtaining 67 excitation cycles and 18,000 sampling points. 18,000 points first reconstruct 36,000 points, 2 bytes, 72 k memory. stm32F407 has 128 k memory. The actual data to be processed is the initial 4096 points sampled, and the floating point number occupies 4096 × 4 space, i.e., 16 k data for the FFT transform. Therefore, the memory space for sampling and reconstruction can be multiplexed. Reconstructing the sampled signal via the above signal arrangement Equation (3) to obtain the complete echo signal for one excitation cycle. The sequence diagram of the reconstructed ultrasound echo signal at the intercepted 2500 points is shown in Figure 15a. The reconstructed signal is then subjected to wavelet noise reduction by the multiresolution thresholding method, and the processed signal is shown in Figure 15b.
Extracting the phase information based on the method of shifted sine fitting and calculating the TOF. The FFT roughly estimates the low-frequency harmonics of the echo signal, selecting N = 4096 points for the FFT transform. Its spectrogram is shown in Figure 16. The position of the frequency point corresponds to the low-frequency harmonics of the ultrasound echo k = 28. The phase interval δ = 0 .043 and the segment length of the shifted sine fit L = 146 were determined according to Equations (20) and (24), respectively.
Using a moving sine fitting algorithm to extract the phase information of the ultrasound echo signal. The phase-out φ x corresponding to the echo signal after noise reduction is calculated according to Equations (21) and (22), etc. Solving the parcel Equation (28) to solve the phase. The continuous phase information is shown in Figure 17. Finally, the fitted echo period is calculated by the phase difference Equation (30). That is, the TOF is t T O F = 1.015 μs.
For the remaining two sets of calibrated thickness values of 10.003 mm and 24.047 mm, the TOF process is the same as above. The ultrasound echo signals for the two thicknesses are shown in Figure 18, and the phase information is shown in Figure 19.
The TOF was 3.373 μs and 8.112 μs for the thicknesses of 10.003 mm and 24.047 mm, respectively. A linear fit of the calibrated thickness values to the measured TOF resulted in a straight line for the thickness versus TOF relationship, with the slope of the line being one-half of the calibrated speed of sound, as shown in Figure 20.
The linear regression model is given by:
y = A x + B
where y is the calibrated thickness measurement sequence. x is the transition time sequence. B is the zero calibration value. A is the parameter that represents the sound–velocity relationship. The expression for the speed of sound is:
c = 2 A = 2 n x i y i x i y i n x i 2 x i 2
Equations (32) and (33) give a calibrated speed of sound of 5928 m/s for 45 steel and a zero calibration value of 0.0029 mm.

5.2. Determination of Thickness Measurement Range

The selected ultrasonic thickness test block range is from 1 mm to 50 mm, the selected ultrasonic probe has a fixed frequency of 2.5 MHz, the minimum time interval between the transmitted signal and the echo signal is t = 0.8 μs, the calibrated speed of sound in 45 steel is 5928 m/s, and the minimum thickness of the measurement is d m = 2.37 mm. However, the method applied in this experiment is to select the characteristic positions of multiple echo signals in a finite attenuation signal and to find the phase difference, which can remove the confusing overlapping signals and extract the useful echo characteristic signal. As shown in Figure 21, the minimum thickness of a 1 mm specimen can be measured. According to the system’s ultrasonic excitation period of 125 μs, the conditions of signal attenuation, and the theoretical maximum measurement thickness of 150 mm, the system’s thickness measurement range meets the requirements of 1 mm to 50 mm.

5.3. Thickness Measurement Results

The remaining thickness of the ultrasonic step test block was measured using this experimental algorithm. The crossing time was recorded. The measured thickness was calculated using the calibrated sound velocity of 5928 m/s with a zero calibration value of 0.0029 mm. And the ultrasonic thickness measurement block comparison experiment was performed by the Hilbert autocorrelation method [13]. The measured thickness results are shown in Table 2, and the comparison graph of the absolute value of error is shown in Figure 22.
Based on the above data, it can be seen that the error of the algorithm for phase feature extraction in this paper is less than that of the Hilbert autocorrelation method. In this paper, the consumption of systematic measurement time is mainly reflected in the following aspects, as shown in Table 3.
The system has a fast measurement speed with a single measurement time of about 40 ms.
The Hilbert autocorrelation method mainly performs the Hilbert transform on the self-multiplying echo signal first, and then undergoes the autocorrelation method to obtain TOF. The Hilbert transform is first obtained by an N-point FFT operation to obtain the spectrum. The positive half of the spectrum is multiplied by −i, the negative half by i, and the DC component is set to 0. Finally, the frequency domain signal is inverted into a time domain signal by N FFTs to complete the Hilbert transform. The Hilbert transform is completed by multiplying the frequency domain signal by N + 3/2Nlog2N times and adding the complex numbers by N + 3Nlog2N times. The traditional autocorrelation algorithm is computationally intensive and requires N 2 multiplications and N(N − 1) additions. Now the autocorrelation operation is generally converted from the time domain to a frequency operation. First, the FFT operation is performed on the signal at N points. Then the N-point complex self-multiplication is performed. Finally, the FFT is inverted to get the result. It also requires N + 3/2Nlog2N times complex multiplication and N+3Nlog2N times complex addition. Therefore, the Hilbert autocorrelation method requires a total of 2N + 3Nlog2N complex multiplications and 2N + 6Nlog2N complex additions.
The complexity of the algorithm in this paper is mainly in the FFT operation and the shifted sine fitting operation. It requires one FFT operation with N points, 1/2Nlog2N complex multiplications, and Nlog2N complex additions. The shifted fit requires only 15 real multiplications and 20 real additions per recursion. One complex multiplication requires four real multiplications and two real additions. The Hilbert autocorrelation method requires 8N + 12Nlog2N real multiplications. The algorithm in this paper requires 15N + 2Nlog2N real multiplications. Its real number multiplication complexity simulation diagram is shown in Figure 23.
Figure 23 reflects that the algorithm in this paper has less complexity than the Hilbert autocorrelation method, and the longer the length of the ultrasound echo signal to be measured, the better the performance.

6. Conclusions

Aiming at the limitations of high-frequency signals needing a high-frequency sampler and the difficulty of accurate extraction of echo signal features. This paper first proposes an improved sampling reconstruction method, a moving sine fitting method to accurately extract the phase information of echo features, establishes an ultrasonic echo model, and analyzes the performance with the commonly used transit time measurement methods to verify the advantages of the algorithm. The system’s thickness measurement experiments were conducted on different thicknesses of 45 steel calibration and thickness measurement experiments, through the measurement of three sets of thickness of the transit time and its corresponding calibration thickness value to obtain the calibration speed of sound and the zero calibration value of 45 steel. The remaining thicknesses were measured and analyzed for errors. The conclusions show that the measurement error is ±0.01 mm for the thicknesses within 3 mm~20 mm and ±0.05 mm for the other thicknesses within 1 mm~50 mm. The single measurement time is 40 ms. This work is highly integrated and requires only a microcontroller. No additional AD converter chip is needed. The processing method makes the measurement accuracy high and reduces the cost. By setting a reasonable sampling frequency and number of sampling points, a larger range of thickness can be measured. Repeating multiple sampling accumulations improves the signal-to-noise ratio of the echo signal, which has a certain development prospect.

Author Contributions

W.G. experiment, writing—original draft, writing—review and editing; X.W. project administration, resources; Z.Y. tests and data analysis, edited the manuscript, writing—review; Z.Z. conceptualization, supervision; W.F. formal analysis; D.L. conceptualization, supervision. All authors have read and agreed to the published version of the manuscript.

Funding

This work was supported by the National Natural Science Foundation of China (No. 32071457), Hubei Natural Science Foundation (No. 2022CFA006) and the Wuhan Keyresearch and development plan (Grant No. 2022012202015034).

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

Data are contained within the article.

Conflicts of Interest

The authors declare that this study received funding from the National Natural Science Foundation of China (No. 32071457), Hubei Natural Science Foundation (No. 2022CFA006), and the Wuhan Keyresearch and development plan (Grant No. 2022012202015034). The funder was not involved in the study design, collection, analysis, interpretation of data, the writing of this article or the decision to submit it for publication.

References

  1. Liu, Y.; Yang, S.; Gan, C. A Novel Laser Ultrasonic Thickness Measurement Method for Metal Plate Based on Spectral Analysis. In Proceedings of the 2015 12th International Conference on Ubiquitous Robots and Ambient Intelligence (URAI), Goyang, Republic of Korea, 28–30 October 2015; pp. 324–329. [Google Scholar]
  2. Liu, H.; Wang, Y.; Jia, Z.; Guo, D. Integration strategy of on-machine measurement (OMM) and numerical control (NC) machining for the large thin-walled parts with surface correlative constraint. Int. J. Adv. Manuf. Technol. 2015, 80, 1721–1731. [Google Scholar] [CrossRef]
  3. Liu, H.; Wang, Y.; Lian, M.; Zhang, T.; Liu, B. Thickness Measurement using Ultrasonic Scanning Method for Large Aerospace Thin-Walled Parts. In Proceedings of the 2019 IEEE 5th International Workshop on Metrology for AeroSpace (MetroAeroSpace), Torino, Italy, 19–21 June 2019; pp. 243–247. [Google Scholar]
  4. Kanai, H.; Koiwa, Y. Measurement of Propagation Speed of Pulsive Wave in Heart Wall at End-Systole. In Proceedings of the 2002 IEEE Ultrasonics Symposium, Munich, Germany, 8–11 October 2002; Volume 1312, pp. 1313–1316. [Google Scholar]
  5. Mihaljević, M.; Markučič, D.; Runje, B.; Keran, Z. Measurement uncertainty evaluation of ultrasonic wall thickness measurement. Measurement 2019, 137, 179–188. [Google Scholar] [CrossRef]
  6. Hermann, M.; Pentek, T.; Otto, B. Design Principles for Industrie 4.0 Scenarios. In Proceedings of the 2016 49th Hawaii International Conference on System Sciences (HICSS), Koloa, HI, USA, 5–8 January 2016; pp. 3928–3937. [Google Scholar]
  7. Langenberg, K.-J.; Marklein, R.; Mayer, K. Ultrasonic Nondestructive Testing of Materials: Theoretical Foundations; Routledge: London, UK, 2012. [Google Scholar]
  8. Jen, C.K.; Wu, K.T.; Kobayashi, M. Ultrasonic probes having three orthogonal polarizations. IEEE Trans. Ultrason. Ferroelectr. Freq. Control 2010, 57, 189–192. [Google Scholar] [CrossRef] [PubMed]
  9. Zhai, L.; Xu, B.; Haiyan, X.; Jin, N. Simultaneous measurement of velocity profile and liquid film thickness in horizontal gas–liquid slug flow by using ultrasonic Doppler method. Chin. J. Chem. Eng. 2023, 58, 323–340. [Google Scholar] [CrossRef]
  10. Geng, T.; Meng, Q.; Xu, X.; Wang, P.; Yuan, X. An extended ultrasonic time-of-flight method for measuring lubricant film thickness. Proc. Inst. Mech. Eng. Part J J. Eng. Tribol. 2015, 229, 861–869. [Google Scholar] [CrossRef]
  11. Kim, Y.H.; Song, S.-J.; Lee, J.-K. Technique for Measurements of Elastic Wave Velocities and Thickness of Solid Plate from Access on Only One Side. Jpn. J. Appl. Phys. 2005, 44, 5240. [Google Scholar] [CrossRef]
  12. Jenot, F.; Ouaftouh, M.; Duquennoy, M.; Ourak, M. Corrosion thickness gauging in plates using Lamb wave group velocity measurements. Meas. Sci. Technol. 2001, 12, 1287. [Google Scholar] [CrossRef]
  13. Kazys, R.; Tumsys, O.; Pagodinas, D. Ultrasonic detection of defects in strongly attenuating structures using the Hilbert–Huang transform. NDT E Int. 2008, 41, 457–466. [Google Scholar] [CrossRef]
  14. Ma, C.; Chen, H.; Ma, L. An Efficient Design of High-Accuracy and Low-Cost FFT. In Proceedings of the IET International Radar Conference 2013, Xi’an, China, 14–16 April 2013; pp. 1–4. [Google Scholar]
  15. Yang, J.; Liu, S.; Zhu, C.; Hao, F.; Ma, J. Equivalent Sampling Oscilloscope with External Delay Embedded System. In Proceedings of the 2011 IEEE International Conference on High Performance Computing and Communications, Banff, AB, Canada, 2–4 September 2011; pp. 195–201. [Google Scholar]
  16. Ivchenko, V.G.; Kalashnikov, A.N.; Challis, R.E.; Hayes-Gill, B.R. High-Speed Digitizing of Repetitive Waveforms Using Accurate Interleaved Sampling. IEEE Trans. Instrum. Meas. 2007, 56, 1322–1328. [Google Scholar] [CrossRef]
  17. Mak, T.M. Jitters in high performance microprocessors. In Proceedings of the 2008 IEEE International Test Conference, Santa Clara, CA, USA, 28–30 October 2008; pp. 1–6. [Google Scholar]
  18. Cheng, M.; Yang, L.; Ding, Z.; Li, S.; Lei, J. Circuit Design of a Novel Analog Multiplier. In Proceedings of the 2023 9th International Conference on Control Science and Systems Engineering (ICCSSE), Shenzhen, China, 16–18 June 2023; pp. 386–390. [Google Scholar]
  19. Kendrick, P.; Cox, T.J.; Li, F.F.; Fazenda, B.M.; Jackson, I.R. Automatic detection of microphone handling noise. In Proceedings of the 2014 4th International Workshop on Cognitive Information Processing (CIP), Copenhagen, Denmark, 26–28 May 2014; pp. 1–6. [Google Scholar]
  20. Misol, M.; Algermissen, S.; Rose, M.; Monner, H.P. Aircraft Lining Panels with Low-Cost Hardware for Active Noise Reduction. In Proceedings of the 2018 Joint Conference—Acoustics, Ustka, Poland, 11–14 September 2018; pp. 1–6. [Google Scholar]
  21. Roetzheim, W.H. Noise reduction during digital signal generation. In Proceedings of the Eighth Annual International Phoenix Conference on Computers and Communications, 1989 Conference Proceedings, Scottsdale, AZ, USA, 22–24 March 1989; pp. 45–48. [Google Scholar]
  22. Chen, H.; Zuo, M.; Wang, X.; Hoseini, M. An adaptive Morlet wavelet filter for time-of-flight estimation in ultrasonic damage assessment. Measurement 2010, 43, 570–585. [Google Scholar] [CrossRef]
  23. Mojškerc, B.; Ravnikar, D.; Šturm, R. Experimental characterisation of laser surface remelting via acoustic emission wavelet decomposition. J. Mater. Res. Technol. 2021, 15, 3365–3374. [Google Scholar] [CrossRef]
  24. Lucarini, S.; Upadhyay, M.V.; Segurado, J. FFT based approaches in micromechanics: Fundamentals, methods and applications. Model. Simul. Mater. Sci. Eng. 2022, 30, 023002. [Google Scholar] [CrossRef]
  25. Wang, X.; Luo, Y.; Zhai, Z.; Yang, L.; He, T. Algorithm for Sine Wave Cure Fit Based on Frequency Precise Estimation. In Proceedings of the 2017 International Conference on Mechanical, System and Control Engineering (ICMSC), St. Petersburg, Russia, 19–21 May 2017; pp. 357–361. [Google Scholar]
Figure 1. Schematic diagram of the principle of improved sampling reconstruction.
Figure 1. Schematic diagram of the principle of improved sampling reconstruction.
Sensors 23 09072 g001
Figure 2. (a) Raw sampling data sequence; (b) rearrangement of sampled data series.
Figure 2. (a) Raw sampling data sequence; (b) rearrangement of sampled data series.
Sensors 23 09072 g002
Figure 3. Schematic diagram of ultrasound echo signal recovery.
Figure 3. Schematic diagram of ultrasound echo signal recovery.
Sensors 23 09072 g003
Figure 4. Overall block diagram of the hardware circuit.
Figure 4. Overall block diagram of the hardware circuit.
Sensors 23 09072 g004
Figure 5. The actual circuit diagram of the experiment.
Figure 5. The actual circuit diagram of the experiment.
Sensors 23 09072 g005
Figure 6. Raw signal sampling simulation.
Figure 6. Raw signal sampling simulation.
Sensors 23 09072 g006
Figure 7. Simulation of self-multiplying echo signal sampling.
Figure 7. Simulation of self-multiplying echo signal sampling.
Sensors 23 09072 g007
Figure 8. Thickness measurement system program flow chart.
Figure 8. Thickness measurement system program flow chart.
Sensors 23 09072 g008
Figure 9. Schematic diagram of the principle of wavelet thresholding noise reduction method.
Figure 9. Schematic diagram of the principle of wavelet thresholding noise reduction method.
Sensors 23 09072 g009
Figure 10. Single echo signal with SNR = 10 dB noise.
Figure 10. Single echo signal with SNR = 10 dB noise.
Sensors 23 09072 g010
Figure 11. Multiple echo signal with SNR = 10 dB noise.
Figure 11. Multiple echo signal with SNR = 10 dB noise.
Sensors 23 09072 g011
Figure 12. Simulation effect of different thresholding methods.
Figure 12. Simulation effect of different thresholding methods.
Sensors 23 09072 g012
Figure 13. FFT spectrogram.
Figure 13. FFT spectrogram.
Sensors 23 09072 g013
Figure 14. Wrapped phase diagram of the echo sampled signal.
Figure 14. Wrapped phase diagram of the echo sampled signal.
Sensors 23 09072 g014
Figure 15. (a) Reconstructed ultrasound echo signal (3.010 mm); (b) ultrasound signal after wavelet noise reduction (3.010 mm).
Figure 15. (a) Reconstructed ultrasound echo signal (3.010 mm); (b) ultrasound signal after wavelet noise reduction (3.010 mm).
Sensors 23 09072 g015
Figure 16. FFT spectrogram of ultrasound signal (3.010 mm).
Figure 16. FFT spectrogram of ultrasound signal (3.010 mm).
Sensors 23 09072 g016
Figure 17. Phase information (3.010 mm).
Figure 17. Phase information (3.010 mm).
Sensors 23 09072 g017
Figure 18. Ultrasound echo signal maps for different thicknesses.
Figure 18. Ultrasound echo signal maps for different thicknesses.
Sensors 23 09072 g018
Figure 19. Graph of phase information for different thicknesses.
Figure 19. Graph of phase information for different thicknesses.
Sensors 23 09072 g019
Figure 20. Fitted line graph for sound speed calibration.
Figure 20. Fitted line graph for sound speed calibration.
Sensors 23 09072 g020
Figure 21. Signal obfuscation and echo characteristic signal extraction plot.
Figure 21. Signal obfuscation and echo characteristic signal extraction plot.
Sensors 23 09072 g021
Figure 22. This experimental algorithm and the Hilbert autocorrelation method measure the absolute value of the error in steel.
Figure 22. This experimental algorithm and the Hilbert autocorrelation method measure the absolute value of the error in steel.
Sensors 23 09072 g022
Figure 23. Plot of computation versus signal length.
Figure 23. Plot of computation versus signal length.
Sensors 23 09072 g023
Table 1. Results of SNR and RMSE for different thresholding methods.
Table 1. Results of SNR and RMSE for different thresholding methods.
Threshold MethodsSNR (dB)RMSE
Fixed threshold8.720.071
Unbiased risk estimation threshold10.020.061
Heuristic threshold9.700.068
The max–min criterion threshold9.740.067
Multiresolution threshold10.860.055
Table 2. Thickness measurement results of this experimental algorithm and Hilbert autocorrelation method.
Table 2. Thickness measurement results of this experimental algorithm and Hilbert autocorrelation method.
Test Block NumberCalibration Thickness Value/MmTOF/μsThe Actual Measured Value of This Experiment/mmThe Algorithmic Measurement Error of This Experiment/mmMeasurements of Hilbert Autocorrelation/mmHilbert Autocorrelation Measurement Errors/mm
7A-10.9940.3190.948−0.0461.0900.096
7A-21.5120.5181.5380.0261.437−0.075
7A-32.0070.6812.0210.0142.0040.033
7A-44.0131.3514.007−0.0063.996−0.017
7C-15.5681.8755.560−0.0085.5890.021
7A-55.9922.0195.987−0.0055.969−0.023
7C-27.4472.5147.4540.0077.4650.018
7A-68.0042.7028.0120.0088.0310.027
7C-39.0103.0369.001−0.0098.986−0.024
7C-411.5983.91411.6040.00611.6130.015
7B-212.5124.21812.505−0.00712.490−0.022
7C-515.4155.20315.4250.01015.4280.013
7C-617.5825.93417.5910.00917.6100.028
7C-719.9526.72719.942−0.01019.921−0.031
7B-429.98110.12330.0080.02730.0250.044
7B-536.03912.14736.006−0.03335.998−0.041
7B-642.04514.19742.0830.03842.1270.082
7B-747.95016.19347.9990.04948.0420.092
Table 3. System measurement time allocation.
Table 3. System measurement time allocation.
Sampling Reconstruction Response Time/msMulti-Resolution Threshold Noise Reduction Response Time/msFFT Transform Response Time/msMoving Sine Fitting Response Time/ms
8.37525.263.171.37
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Gong, W.; Wang, X.; Yang, Z.; Zhai, Z.; Feng, W.; Liu, D. Ultrasonic Thickness Measurement Method and System Implementation Based on Sampling Reconstruction and Phase Feature Extraction. Sensors 2023, 23, 9072. https://doi.org/10.3390/s23229072

AMA Style

Gong W, Wang X, Yang Z, Zhai Z, Feng W, Liu D. Ultrasonic Thickness Measurement Method and System Implementation Based on Sampling Reconstruction and Phase Feature Extraction. Sensors. 2023; 23(22):9072. https://doi.org/10.3390/s23229072

Chicago/Turabian Style

Gong, Wenqiang, Xuanze Wang, Zhenyu Yang, Zhongsheng Zhai, Wei Feng, and Da Liu. 2023. "Ultrasonic Thickness Measurement Method and System Implementation Based on Sampling Reconstruction and Phase Feature Extraction" Sensors 23, no. 22: 9072. https://doi.org/10.3390/s23229072

APA Style

Gong, W., Wang, X., Yang, Z., Zhai, Z., Feng, W., & Liu, D. (2023). Ultrasonic Thickness Measurement Method and System Implementation Based on Sampling Reconstruction and Phase Feature Extraction. Sensors, 23(22), 9072. https://doi.org/10.3390/s23229072

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop