# Energy Efficient GNSS Signal Acquisition Using Singular Value Decomposition (SVD)
## 4 Simulation and Performance
### Performance Metrics
#### 4.1.4 Probability of Detection (Pd) and Probability of False Alarm (Pfa)  
The analysis of the probabilities of detection and false alarm is closed to the analysis done for the L1 C/A signal in [1]. The result of the circular correlation between the receiver and the local signal in Figure 3 can be modeled as:  
\[I_{i}(\tau_{u},f_{du})=Ad_{i}R(\tau-\tau_{u})sinc((f_{d}-f_{du})T_{1})\cos(\theta _{ei})+nI_{i} \tag{21}\]  
\[Q_{i}(\tau_{u},f_{du})=Ad_{i}R(\tau-\tau_{u})sinc((f_{d}-f_{du})T_{1})\sin( \theta_{ei})+nQ_{i} \tag{22}\]  
where \(\tau_{u}\) and \(f_{d}\) are the possible code delay and Doppler shift, in the same manner \(\tau\) and \(f_{d}\) are the true code delay and Doppler shift, and \(d\) is a data bit value. \(R(. )\) is the autocorrelation function of the C/A code, \(T\) is the millisecond correlation interval, \(\theta_{e}\) is the average phase error over the integration time, \(A\) is the amplitude, which is normalized to derive the noise variance to 1. The terms \(nI_{i}\) and \(nQ_{i}\) are the in phase and quadrature components of the noise, and both have the distribution \(N\Big{(}0,\ \frac{\sigma_{N}}{\sqrt{2}}\Big{)}\), where \(\sigma_{N}^{2}\) is the total noise power at the input to the correlation. To determine the correct alignment, a threshold is chosen above the noise power that has a low probability of being exceeded by the noise. That probability is called the probability of false alarm \((pf)\), and the computation of \(pf\) is straightforward by constructing a Gaussian distribution centered at the mean value of the noise and computing the area under the tail of the distribution. Considering the results after non-coherent integration, a function of the form  
\[r=\sqrt{I^{2}+Q^{2}}. \tag{23}\]  
If a signal is present \(r\) has a Rayleigh distribution with mean and variance given by [41]:  
\[\mu(X)=\sigma\sqrt{\frac{\pi}{2}} \tag{24}\]  
\[var(X)=\frac{4-\pi}{2}\sigma^{2} \tag{25}\]  
The approach to compute the probability of detection is also to construct a Gaussian distribution centered around the \(n\) peak, and computing the area under the curve that is above the false alarm threshold once the threshold is established for the \(pf\). The standard deviation at the peak is different than the standard deviation away from the peak by the definition of SNR [1] as the power ratio of the peak magnitude to the noise standard deviation, \(\sigma_{N}\). For a given SNR the variance at the peak comes from the Rice distribution and is given by the following equation from [1; 41]:  
\[\sigma_{P}^{2}=\
u^{2}+2\sigma_{N0}^{2}-\langle V\rangle^{2} \tag{26}\]  
where \(\
u=S_{0}\), the mean amplitude of the coherent peak is the standard deviation of the noise on \(I\) or \(Q\)\(\sigma_{N0}\); \(\langle V\rangle\) = mean \((S+\mu_{N})\):  
\[\langle V\rangle=\Big{(}\sigma_{N0}\sqrt{\
icefrac{{\pi}}{{2}}}\Big{)}e^{- \frac{2}{2}}[(1+\gamma)I_{0}(\
icefrac{{\gamma}}{{2}})+\gamma I_{1}(\
icefrac{{ \gamma}}{{2}})] \tag{27}\]  
where \(I_{0}\) and \(I_{1}\) are the \(n\)th-order modified Bessel function. The variance away from the peak as Equation (26) is, \(\sigma_{N}^{2}=\sigma_{N0}^{2}(^{4}-\
icefrac{{\pi}}{{2}})/2\), the ratio of the variances at the peak and away from the peak is:  
\[\frac{\sigma_{P}^{2}}{\sigma_{N}^{2}}=\frac{\
u^{2}+2\sigma_{N0}^{2}-\langle V \rangle^{2}}{\sigma_{N0}^{2}(^{4}-\
icefrac{{\pi}}{{2}})/2} \tag{28}\]  
\[q=\frac{\sigma_{P}^{2}}{\sigma_{N}^{2}}=\frac{4}{4-\pi}(\gamma+1-\frac{\pi}{4} e^{-\gamma}[(1+\gamma)I_{0}(\
icefrac{{\gamma}}{{2}})+\gamma I_{1}(\
icefrac{{ \gamma}}{{2}})]^{2}) \tag{29}\]  
\[\gamma=S_{0}\Big{/}2\sigma_{N0}^{2} \tag{30}\]where \(\gamma\) is the coherent SNR, and \(q\) is the ratio of the standard deviation at the correlation peak to the standard deviation away from the peak. The correct alignment is then determined by the delay in an output that exceeds the threshold when a signal is present and it is called the probability of detection.