A Multi-Iteration Enhanced 2P-SMA Method for Improved Error Reduction on a WP-SAW Water Temperature and Pressure Sensor

Due to the instability of the characteristics of materials, fabrication processes and user handling, newly designed and fabricated wireless passive surface acoustic wave (WP-SAW) sensor nodes have inconsistent sensing performance. Furthermore, ambient environmental interferences aggravate inconsistences under complex working conditions. In this paper, a multi-iteration enhanced two-point simple moving average (MI-2P-SMA) method is proposed for sensing error reduction of a WP-SAW reflective delay line water temperature and pressure sensor. This method is improved from the traditional 2P-SMA method for better performance on error reduction. The results show: the MI-2P-SMA method does not change the original characteristics of experimental data; it can reduce relative errors of the WP-SAW reflective delay line water temperature and pressure sensor and has better performance than a traditional 2P-SMA method; it reduces the number of data points and the extent of this reduction is dependent on iteration time.


I. INTRODUCTION
The demand of sensors is growing rapidly worldwide. Besides the growth of the quantity, the technical requirements for better performance of sensors and the demand of customed sensing systems from industrials are increasing greatly due to the development of Internet of Things (IoT) enabled technologies [1]- [6]. Wang et al. [1] proposed an intelligent trust evaluation scheme in sensor-cloud-enabled industrial IoT. Qi et al. [2], [3] reviewed data fusion techniques for IoT applications and IoT for healthcare systems, and did researches on IoT enabled wearable sensors. Astill et al. [4] reviewed smart sensors, big data, and IoT for smart The associate editor coordinating the review of this manuscript and approving it for publication was Po Yang . poultry management. Kamilaris and Pitsillides [5] reviewed IoT in mobile phone computing. Liu et al. [6] reviewed spintronic sensors with Internet of Things for smart living.
Wireless passive surface acoustic wave (WP-SAW) sensors have been increasingly investigated by worldwide researchers nowadays. It is so attractive because of its passive characteristics which makes batteries unnecessary in sensing systems, outstanding stability and reliability in harsh environment, small size making it easy to deploy for various applications, and its investor-friendly low cost [7]- [14].
WP-SAW sensors have been developed for measuring different kinds of physical quantities such as temperature [15], pressure [16], toque [17], strain [18], etc. and gas densities such as NO 2 [19], CO 2 [20], etc. However, the sensing data obtained and processed by newly designed and fabricated sensors are affected by errors due to various interferences, e.g., characteristics of materials, vibration effect, chip integration orientation misalignment, heating issues, random noise of operating environment, handling of world users, etc. [21]- [25].
Researchers made efforts on reduction of sensing errors caused by these interferences. Some algorithms were developed by previous researchers [26], such as least squares [27], polynomial fitting [28], and interpolation [29], etc., but these methods do not reflect real-time output data and cannot be used for real-time monitoring tasks. This disadvantage limits their usage scenarios. A traditional two-point simple moving average has very limited effect on error reduction on sensing errors if the variance is not close to 1 [30].
In order to resolve the aforementioned problem, an improved multi-iterative two-point simple moving average (MI-2P-SMA) method is proposed in this paper. For verification of its characteristics and effectiveness, it is applied to the original experimental sensing data of a newly designed and fabricated WP-SAW reflective delay line temperature and pressure sensor.
This research makes the following contributions.
1) The improved MI-2P-SMA is derived mathematically from the traditional 2P-SMA and analyzed using a diagram.
2) The improved MI-2P-SMA is successfully utilized to reduce relative errors on a WP-SAW reflective delay line temperature and pressure sensor.
3) The limitations of the improved MI-2P-SMA are summarized that the iteration time is limited to keep the characteristics of original data and at least half data points.
The rest paper is organized as follows. In Section II, the mathematical derivation of the improved MI-2P-SMA is presented. It is derived from the fundamental SMA theory and improved from the traditional 2P-SMA. It is described by a mathematic equation and a diagram. An architecture of data flow is proposed to explain how the MI-2P-SMA method works. In Section III, the WP-SAW reflective delay line temperature and pressure sensor is introduced. In Section IV, the experiments for obtaining sensing data are presented. In Section V, experimental data are compared with the data after MI-2P-SMA is applied. Regression and relative error analysis are utilized for data analysis. Finally, in Section VI, the results are concluded.

II. MULTI-ITERATION ENHANCED TWO-POINT SIMPLE MOVING AVERAGE
A. MATHMATICAL DERIVATION SMA can be utilized to reduce random noise and retain a sharp step response. It operates by averaging a series of points from input to produce each point in the output signal, which can be described as (1).
where x is the input signal; y is the output signal; M is the number of points in average; i is the order of the data. Therefore, a 2P-SMA is that the number of points in average is 2, which is described as (2).
If the output of this 2P-SMA is the input of another 2P-SMA process, this entire two-step process is defined as a 2-iterative 2P-SMA, which can be described as (3).
If this goes further, an n-iterative 2P-SMA process can be concluded and described as (4).
where n is a natural number; C 0 n , C 1 n , C 2 n , . . . , C n n are combinations, which are defined as (5).
where k is a natural number and less or equal to n, and n!, k!, and (n-k)! are factorials. Equation (4), an n-iterative 2P-SMA, is defined as an n-time MI-2P-SMA. Actually, the traditional 2P-SMA is a one-time MI-2P-SMA. Figure 1 is the diagram of the MI-2P-SMA, which shows the data flow and also some features of the MI-2P-SMA. The feathers of MI-2P-SMA are summarized as follows. The first row shows the i-th point and its subsequent points of original data before MI-2P-SMA is applied, and the number of points of this row is m + 1. y n is the (n + 1)-th row which is the i-th point and its subsequent points of original data after n-time MI-2P-SMA. The number of original data points reduces n after n-time MI-2P-SMA.

C. ITERATION TIME
In order to improve the accuracy of sensing systems, MI-2P-SMA is applied to the original experimental data. However, the iteration time n should be limited to an appropriate range because of the feature of the reduction of data points. In order to have effective number of data points to keep characteristics of the original data, m + 1 must be much larger than n. To select appropriate iteration time n is a key issue for the best performance of MI-2P-SMA. Figure 2 shows the flow chart to select appropriate iteration time n. This flow chart proposes the methodology to obtain the n. Firstly, the characteristic curve section of original data Result (0) needs to be indicated. The characteristic curve

III. WP-SAW WATER TEMPERATURE AND PRESSURE SENSOR
The newly designed and fabricated WP-SAW sensor node is a WP-SAW reflective delay line temperature and pressure sensor node fabricated on a 0.5 mm thick Y-Z cut LiNbO 3  piezoelectric crystal substrate, which has been presented in our previous work [31]- [33]. Table 1 shows the parameters of this WP-SAW sensor, and Figure 3 shows the structure of this WP-SAW sensor node.
An IDT is fabricated in the center of the surface of the substrate for converting received RF signals to the energy of SAW, and also re-converting the reflected SAW energy back to RF signals. The antenna is connected to the IDT for interrogation RF signal receiving and response signal transmission. The SAW propagates on the surface of the substrate, which is vertical to the IDT bars and to both opposite directions from the IDT. Three reflectors are fabricated on the surface of the substrate on the way of SAW propagation, which are paralleled to the IDT. Sound absorption materials are applied to the edges of the substrate for absorbing redundant SAW energy to avoid interferences on the useful SAW reflections. In Fig. 3, one reflector R 1 is on the left side of the IDT for pressure sensing purpose, and two reflectors R 2 and R 3 are on the right side of the IDT for temperature sensing purpose. On the left side of the IDT, the substrate acts as a cantilever on which ambient pressure change acts on it to make deformation to the left side of the substrate. This leads to the change of the distance between R 1 and the IDT, and subsequently influences the SAW propagation to make time delay change for sensing purpose. On the right side of the IDT, the substrate is bonded to the package to sense the temperature change. The temperature change can also make deformation of the substrate to make SAW propagation change which further causes the time delay change.
This WP-SAW reflective delay line temperature and pressure sensor has the following regulations based on our previous work [30]. In time domain, phase differences of the response signals reflected by the three reflectors from the 48238 VOLUME 9, 2021 sensor node have linear relationships with testing temperature and pressure changes, which can be shown in (6) and (7).
where T i is the initial temperature and ϕ 3i is the corresponding initial phase difference of the response signal reflected by R 3 ; T is the temperature and ϕ 3 is the corresponding phase difference of the response signal reflected by R 3 ; A is a constant related to the wavelength of the SAW, the substrate material and the distance between the IDT and R 3 . Similarly, P i is the initial pressure and ϕ 1i is the corresponding initial phase difference of the response signal reflected by R 1 ; P is the Pressure and ϕ 1 is the corresponding phase difference of the response signal reflected by R 1 ; B is a constant related to the wavelength of the SAW, the substrate material and the distance between the IDT and R 1 ; C is a constant related to the substrate material. Figure 4 shows the photo of the experimental framework for testing the fabricated WP-SAW reflective delay line temperature and pressure sensor node. The instruments include an Agilent 33220A Function/Arbitrary Waveform Generator (20 MHz), an Agilent E4438C ESG Vector Signal Generator (250 kHz -6 GHz), an Agilent MSO 6104A Mixed Signal Oscilloscope (1 GHz) and an Agilent E4440A PSA Series Spectrum Analyzer (30 kHz -26.5 GHz). The sensor node is placed in the inner layer top of a double-layer glass pipe. The inner layer of the pipe is strictly sealed by the steal substrate and have access to the liquid pressure transfer platform for pressure test purpose. The outer layer of the pipe is sealed by a rubber plug and connected to the water bath temperature controller by two rubber hoses for a water cycle to control the temperature of the inner layer pipe. The sensor node receives the interrogation RF signal which is the wireless modulated signal from the Agilent E4438C ESG Vector Signal Generator, and then reflect it to form response signals with sensing information to the Agilent MSO 6104A Mixed Signal Oscilloscope and Agilent E4440A PSA Series Spectrum Analyzer which are used to record and process both interrogation and response RF signals.  Table 2 shows the linear regression equations and variances of original experimental temperature data, 5-, and 10-time MI-2P-SMA processed data, where x is the temperature value and y is the phase difference value. The linear regression equation represents the theoretical linear relation between temperature and the phase difference of the response signal reflected by R 3 . The variance values are close to 1, which means the data are close to their linear regression equations.

V. RESULTS AND DISCUSSIONS
Relative error can be calculated by (8). Figure 6 shows the comparison of relative errors of original experimental temperature data, 5-, and 10-time MI-2P-SMA processed data. Table 3 shows the range of relative errors of original experimental temperature data, 5-, and 10-time MI-2P-SMA processed data. The range of relative errors of the original experimental temperature data is from −3.40% to 1.87%. After 5-, and 10-time MI-2P-SMA, the range of relative errors VOLUME 9, 2021  is from −0.88% to 0.35%, and from −0.17% to 0.13%, respectively.
In summary of temperature data analysis, the MI-2P-SMA method does not change the original characteristics of experimental temperature data. The more iterative times of MI-2P-SMA applies, the range of relative errors is more significantly reduced, and the variance values are closer to 1. This indicates that the more iterative times of MI-2P-SMA applies, the temperature data are closer to their linear regression equations. Figure 5 shows the obvious reduction of the number of data points, which verified the regulation of MI-2P-SMA presented in Section 2. In this temperature data case, the characteristic curve of original experimental temperature data is almost linear. After 10-time MI-2P-SMA, the variance is extremely close to 1; the range of the relative errors is significantly reduced; more than half data points are kept. Therefore, 10 iteration times are selected for this temperature data case.     Table 4 shows the linear regression equations and variances of original experimental pressure data, 4-, 5-, 6-, and 10-time MI-2P-SMA processed data, where x is the pressure value and y is the phase difference value. The linear regression equation represents the theoretical linear relation between pressure and the phase difference of the response signal reflected by R 1 . The variance values are close to 1, which means the data are close to their linear regression equations. Figure 8 shows the comparison of relative errors of original experimental pressure data, 4-, 5-, 6-, and 10-time MI-2P-SMA processed data. Table 5 shows the range of relative errors of original experimental pressure data, 4-, 5-, 6-, and 10-time MI-2P-SMA processed data. The range of relative errors of the original experimental pressure data is from 48240 VOLUME 9, 2021 TABLE 5. The range of relative errors of original experimental pressure data, 4-, 5-, 6-, and 10-time MI-2P-SMA processed data. −3.38% to 2.95%. After 4-, 5-, 6-, and 10-time MI-2P-SMA, the range of relative errors is from −1.62% to 1.52%, from −1.45% to 1.44%, from −1.22% to 1.38%, and from −1.30% to 0.96%, respectively.
In summary of pressure data analysis, the MI-2P-SMA method does not change the original characteristics of experimental pressure data. The more iterative times of MI-2P-SMA applies, the range of relative errors is more significantly reduced, but in this pressure data case, the variance value reaches highest after 5-time MI-2P-SMA, and then it gradually drops. Figure 7 also shows the obvious reduction of the number of data points, which verified the regulation of MI-2P-SMA presented in Section 2. In this pressure data case, the characteristic curve of original experimental pressure data is almost linear. After 10-time MI-2P-SMA, the range of relative errors is significantly reduced, and more than half data points are kept. Therefore, 10 iteration times are selected for this pressure data case.
Compared with the temperature data, the original experimental pressure data have larger error range than the original experimental temperature data. This is due to the higher relative resolution and accuracy of temperature sensing than pressure by this WP-SAW reflective delay line temperature and pressure sensor. The relative resolution and accuracy are related to the sensor node design and the standard of the fabrication processes.

VI. CONCLUSION
The improved MI-2P-SMA method is presented by mathematic deviation from fundamental SMA and traditional 2P-SMA and diagram analysis. The method of selection of the iterative time n is discussed. The WP-SAW reflective delay line temperature and pressure sensor node is briefly introduced. The experimental framework with instrumentation is introduced. The experimental temperature and pressure data and their post-MI-2P-SMA results are compared and discussed by regression and relative error analysis. The results show: the MI-2P-SMA method does not change the original characteristics of experimental data; the more iterative time of MI-2P-SMA applies, the range of relative errors is more significantly reduced; however, at least half data points should be kept after MI-2P-SMA. Therefore, the iterative time n should be less than the number of half data points. The characteristics of original data should also be kept after MI-2P-SMA. He is currently working as an Associate Professor with the School of Environment, Harbin Institute of Technology. He leads a research group and received a variety of research grants as a PI and a co-PI for a number of projects, including EU FP7 Marie Curie Actions, the Royal Society U.K., the National Natural Science Foundation of China, and industries. He has published over 60 articles and contributed contents to three books. He owns five software copyrights and 19 patents. His research interests include water supply network simulation, hydro-informatics, long distance pipeline transient analysis, water supply system optimal schedule, and pipeline hygienics.
JINGTING LUO received the Ph.D. degree from Tsinghua University, China, in 2012.
From 2012 to 2015, he worked as an Assistant Professor with the College of Physics and Technology, Shenzhen University, China. From 2016 to 2017, he worked as an Academic Visitor with the Faculty of Engineering and Environment, University of Northumbria, Newcastle upon Tyne, U.K. Since 2017, he has been an Associate Professor with the College of Physics and Optoelectronic Engineering, Shenzhen University. He has extensive experience in acoustic wave devices, lab-on-chip, micromechanics, piezoelectric thin films, and nanostructured composite/films for applications in MEMS, sensing, and energy harvesting applications. He has published over 100 science citation index (SCI) journal articles and over 20 conference papers. He is regular journal article reviewers for more than ten journals and has co-organized five international conferences.