# RFID Authentication System Based on User Biometric Information +
## 4 System Design
### Data Preprocessing  
The phase is a periodical function with the periodic signal surround and the inverted \(\pi\) phenomenon, which are the essential characteristics of the tag signal. As shown in Figure 4, the figure above shows the wrapped phase, and the figure below shows the inverted \(\pi\) phenomenon of the phase. In order to obtain usable phase characteristics, we need to  
Figure 3: Work flow of the RF-Ubia system. preprocess the data after getting the tag signal to obtain the tag information with the phase unwrapped and the inverted \(\pi\) phenomenon eliminated. In general, the first n data of the tag are the signal data when the tag is more stable, i.e., the tag signal without user touch interference. We select the phase average \(\theta_{m}\) of the first n data of the tag as the tag phase reference value. Thus, the difference between the first n phase values of the tag and the reference value, respectively, \(\Delta\theta_{i}=|\theta_{i}-\theta_{m}|\), can be obtained. We handle anomalies by setting thresholds. Since the phase of the tag fluctuates on its own and changes when touched by the user, if the threshold [3] is set too large or too small, it can lead to some data being processed incorrectly and ultimately affect the overall experimental data. We set the threshold value as  
\[ \begin{cases}\textit{thres}_{1}=\pi-\textit{thres},\\ \textit{thres}_{2}=\pi+\textit{thres},\end{cases} \quad\textit{and}\quad\theta _{i}= \begin{cases}\theta_{i},&\Delta\theta_{i}\leq\textit{thres}_{1}\\ (\theta_{i}+\pi)mod2\pi,&\textit{thres}_{1}<\Delta\theta_{i}<\textit{thres}_{2 }\\ \theta_{i}-2\pi,&\theta_{i}-\theta_{m}\geq\textit{thres}_{2}\\ \theta_{i}+2\pi,&\theta_{i}-\theta_{m}\leq-\textit{thres}_{2}\end{cases}  \tag{1}\]  
where the value of thres will be selected as the optimal value by iterative adjustment during the experiment. By comparing the difference \(\Delta\theta_{i}\) with the set threshold, if \(\Delta\theta_{i}\leq\textit{thres}_{1}\), then the phase is normal data; if \(\textit{thres}_{1}<\Delta\theta_{i}<\textit{thres}_{2}\), then it is judged to be an inverted \(\pi\) phenomenon; if \(\Delta\theta_{i}\geq\textit{thres}_{2}\), then it is judged to be the occurrence of a phase wrapping phenomenon, as shown in Equation (1). After processing the first n stable phases of the tag, the subsequent data of the tag are processed using a sliding window. We improve and optimize the processing algorithm because the user touch operation may cause a large abrupt change in the tag phase; for example, touching the tag causes the tag phase to change beyond \(\textit{thres}_{1}\), which is a phase change caused by the touch operation and not an inverse \(\pi\) phenomenon or a phase wrapping phenomenon. In this case, as the user's touch has a continuous effect on the phase and the inverted \(\pi\) is an episodic phenomenon, we will use the data after this phase to make a judgment. As shown in Equation (2), the average value of this phase \(\theta_{k}\) and the m phases after it is taken, and if the difference between the phase value and the average  
Figure 4: The ‘\(\times\)’ symbols circled in red represent data with period wrap or phase inverted \(\pi\), i.e. abnormal data, while the red ‘\(\times\)’ symbols represent normal data after pre-processing. The figure above shows the wrapped phase. The figure below shows the inverted \(\pi\) phenomenon  
value is small compared to the threshold value \(thres_{3}\), then the phase is not anomalous and does not need to be processed. \[\left|\theta_{k}-\frac{\sum\limits_{i=1}^{m}\theta_{k+i-1}}{m}\right|<thres_{3}. \tag{2}\]  
When the user touches the tags in the array, we find that some of them cannot feedback the tag signal. In Figure 5, two adjacent pieces of data are connected by dashed lines. A large amount of signal data is missing between the two pieces of data surrounded by blue circles.