## 3 Detection Precision and Sensitivity Analysis  
### Precision Analysis of Quadrant Detector under Beacon Spread-Spectrum Modulation  
For the QD, the root-mean-square error (RMSE) of the position of the detection spot is used as a measure of the position-detection precision. Due to the symmetric response characteristics of the QD in the x and y directions, we will only discuss the x direction. As the correlation between the noise and the local PRN after the cross-correlation operation is significantly lower than the correlation between the received photocurrent signal and the local PRN, the relative position of the QD output spot is as follows:  
\[\begin{array}{l}x_{r}\\ \\  
\[\sigma_{x_{r}}^{2} = \frac{(R_{sl}(\tau)+R_{sII}(\tau))^{2}+(R_{sII}(\tau)+R_{sIII}(\tau))^ {2}}{(R_{sl}(\tau)+R_{sII}(\tau)+R_{sIII}(\tau)+R_{sIV}(\tau))^{4}}\cdot\mathbf{ \delta}\cdot I_{n}^{2}\] \[= k\cdot\frac{4\cdot I_{n}^{2}}{(R_{sl}(\tau)+R_{sII}(\tau)+R_{sIII }(\tau)+R_{sIV}(\tau))^{2}}\]  
where the scaling factor \(k=2\cdot\frac{(R_{sl}(\tau)+R_{sII}(\tau))^{2}+(R_{sII}(\tau)+R_{sIII}(\tau))^ {2}}{(R_{sl}(\tau)+R_{sII}(\tau)+R_{sIII}(\tau)+R_{sIV}(\tau))^{2}}\) represents the total power of the Gaussian beam correlation peaks (excluding noise factors), and \(4\cdot I_{n}^{2}\) represents the total power of the detector's correlated post-noise current in four quadrants. The total SNR after despreading R\({}_{\text{SNRL}}\) is defined as follows:  
\[R_{SNRL}=\frac{(R_{sl}(\tau)+R_{sII}(\tau)+R_{sIII}(\tau))^{2}}{4\cdot I_{n}^{ 2}} \tag{14}\]  
In a spread-spectrum communication system, the SNR of the output relative to the SNR of the received signal at the receiver undergoes certain improvements after despreading. The ratio of the output to input SNR in the receiving system is defined as the spreading gain, which can be expressed as the ratio of the bandwidth after spreading to the bandwidth before spreading [32; 33; 34]. \[G_{p}=\frac{(S/N)_{out}}{(S/N)_{in}}=\frac{T_{c}}{T_{s}} \tag{15}\]  
where \((S/N)_{out}\) represents the SNR of the output signal after despreading, and \((S/N)_{in}\) represents the SNR of the input signal before despreading. When \(R_{\text{SNRE}}\) is defined as the SNR of the detector-received photoelectric signal, according to Equation (15), the total SNR after despreading is related to the SNR of the detector's received photoelectric signal, as follows:  
\[R_{\text{SNRL}}=G_{p}\cdot R_{\text{SNRE}} \tag{16}\]  
Therefore, the relationship between the actual position \(x_{0}\) of the beam centroid and its relative position can be expressed as follows: \(x_{0}=\frac{\omega}{\sqrt{2}}erf^{-1}(x_{r})\). Then, the relationship between \(k\) and the actual value \(x_{0}\): \(k=1+erf^{2}\left(\frac{\sqrt{2}x_{0}}{\omega}\right)\) is established. The variance in the value can be obtained from the below formula:  
\[\sigma_{x_{r}}=\frac{1}{\sqrt{G_{p}\cdot R_{\text{SNRE}}}}\sqrt{1+erf^{2} \left(\frac{\sqrt{2}x_{0}}{\omega}\right)} \tag{17}\]  
By establishing a mathematical model to determine the precision of relative position detection under beacon spread-spectrum modulation, it can be observed from the mathematical model that the precision of relative position detection \(\sigma_{x_{0}}\) is related to the waist radius \(\omega\) of the Gaussian beam, the actual position \(x_{0}\) of the beam centroid, the SNR of the detector-received photoelectric signal \(R_{\text{SNRE}}\), and the spreading gain \(G_{P}\). When spread-spectrum technology is employed, the position-detection performance of the quadrant detector is improved by a factor of \(\sqrt{G_{P}}\). Spread-spectrum technology effectively improves the accuracy of position detection by enhancing the signal-to-noise ratio of optoelectronic signals. Therefore, simulations based on Equation (17) were conducted to assess the precision of the position detection performed by the QD under different spreading gains.