## 4 Target Model and Frequency Offset Extraction Method
### Target Detection Processing Method
#### 4.2.2 Doppler Frequency Offset Estimation  
According to Equation (12), there will be a phase shift caused by a Doppler frequency shift between different symbols on the same subcarrier. Therefore, the Doppler frequency shift produced by the rotating target can be calculated through the phase shift between symbols. Then, the rotation speed of the rotating target can be estimated based on the obtained Doppler frequency deviation versus the time curve.  
In this experiment, the carrier frequency is much larger than the signal bandwidth, so the target Doppler frequency shifts obtained by different subcarriers can be approximately  
Figure 8: Flow chart of target frequency offset estimation based on 5G signal.  
equal. To obtain the target Doppler frequency offset, the channel response obtained at different single subcarrier positions can be used for processing, that is, a time-frequency analysis of \(H(i,m),i=0,1,2,\dots,N_{1}-1\). However, due to frequency selectivity, the channel response obtained on a single subcarrier may have lower energy and greater interference. It is also possible to stack the channel responses at multiple subcarrier positions in the frequency domain before conducting a time-frequency analysis, i.e., conducting a time-frequency analysis on \(\sum\limits_{i}H(i,m)\). The time-frequency analysis serves to perform a short-time Fourier transform on the obtained channel response to obtain frequency domain information and time domain information at the same time. The time-frequency analysis schematic is shown in Figure 9. In data processing, it is necessary to choose an appropriate window length to achieve better results.  
The channel response extracted using the n-th subcarrier can be represented as \(H_{n}\), and the result of the time-frequency analysis on \(H_{n}\) can be represented as follows:  
\[ST(i,j)=STFT\{H_{n}\} \tag{13}\]  
The size of the matrix \(ST(i,j)\) is \(I\times J\), where the column vector represents the result of the FFT transformation at the corresponding time \(j\).  
The global maximum value index is obtained by detecting the amplitude of the FFT result corresponding to a certain time \(j\), and the frequency corresponding to the index is the target Doppler frequency at that time, which can be expressed as follows:  
\[f_{d}(j)=\arg\max_{0\leq i\leq I-1}\{\text{abs}[ST(i,j)]\} \tag{14}\]  
where \(f_{d}(j)\) is the target Doppler frequency offset index at the corresponding time \(j\), \(\text{abs}(\cdot)\) represents the modulus value, and \(\text{argmax}(\cdot)\) represents the index corresponding to the global maximum.  
For multiple targets, the global maximum cannot detect all targets. Instead, local maximum detection can be used to extract the frequency offset of multiple targets by sorting the local maximum or setting a threshold, which can be represented as follows:  
\[f_{d_{k}}(j)=\operatorname*{arg\text{findpeaks}}_{k,0\leq i\leq I-1}\{\text{ abs}[ST(i,j)]\} \tag{15}\]  
where \(f_{d_{k}}(j)\) is the Doppler frequency offset index of the k-th target at time \(j\), and \(\operatorname*{arg\text{findpeaks}}(\cdot)\) represents the index corresponding to the maximum of the k-th along the vector index \(i\). When the number of targets is known, the local maximum values can be directly sorted to obtain the frequency offset of all targets. Inversely, if the number of targets is unknown, the algorithm of constant false alarm rate [23; 24] detection can be applied to generate an adaptive threshold; thus, the local maximum value exceeding the threshold will be determined as a target.  
Figure 9: Time–frequency analysis schematic.