# Random Access for Underwater Acoustic Cellular Systems
## 4 RAP Detection  
In this section, we analyze the detection probability and false alarm probability of the proposed RAPs in a Doppler environment. Here, we assume that the RAP detector is composed of a bank of  
Figure 12: Number of possible RAPs in RAP 2.  
correlators that correlate/match a received signal with a bank of local RAPs in parallel. The received signal at the input of each correlator, \(y(t)\), is modeled as:  
\[y(t)=\left\{ \begin{array}{ll}\widetilde{z}^{c}(t),&\text{H}_{0}\\ \widetilde{x}^{c}(t)+\widetilde{z}^{c}(t),&\text{H}_{1}\end{array} \right. \tag{22}\]  
where \(\widetilde{x}^{c}(t)\) denotes the received signal from a desired UE \(c\). The interference signals from other UEs and additive noise are given by:  
\[\widetilde{z}^{c}(t)=\sum\limits_{i=0,i\
eq c}^{C-1}\widetilde{x}^{i}(t)+z(t) \tag{23}\]  
The hypothesis H\({}_{1}\) refers to the case where the received signal includes the RAP from the desired UE \(c\). In the hypothesis H\({}_{0}\) (null hypothesis), the received signal is composed of all the RAPs received from \(C-1\) UEs except UE \(c\) and additive noise, \(z(t)\). Here, \(C\) denotes the number of UEs transmitting RAPs simultaneously. The output of the correlator for UE \(c\) can be expressed as follows:  
\[r^{c}(t)=\int\limits_{-\tau/2}^{\tau/2}y(s+t+\tau/2)(x^{c}(s))^{*}ds \tag{24}\]  
where \(x^{c}(t)\) denotes the reference RAP transmitted from UE \(c\), which can be either RAP 1 or RAP 2. The desired RAP is detected when the correlation output exceeds a threshold value as follows:  
\[\hat{t}^{c}=\operatorname*{arg\,max}_{t\in[0,T_{W}]}\lvert r^{c}(t)\rvert^{2}>\gamma \tag{25}\]  
where \(\hat{t}^{c}\) denotes the estimated time delay of the \(c\)th UE. Here, \(T_{W}\) denotes the length of the correlator window. The squared magnitude of each correlator output is given by a random variable with a 2-degree-of-freedom non-chi square density function as follows:  
\[f_{R[t;\text{H}]}(r)=\frac{1}{\sigma^{2}[t;\text{H}]}e^{-\frac{r+\lambda[t; \text{H}]}{\sigma^{2}[t;\text{H}]}}\;I_{0}\left(\frac{2\sqrt{\lambda[t;\text{ H}]r}}{\sigma^{2}[t;\text{H}]}\right) \tag{26}\]  
where:  
\[ \begin{array}{l}R[t;\text{H}]=X_{\text{Re}}^{2}[t;\text{H}]+X_{\text{Im}}^{2 }[t;\text{H}]\\ \sigma^{2}[t;\text{H}]=2\
abla\{X_{\text{Re}}[t;\text{H}]\}=2\
abla\{X_{\text {Im}}[t;\text{H}]\}\\ \lambda[t;\text{H}]=\text{E}^{2}\{X_{\text{Re}}[t;\text{H}]\}+\text{E}^{2}\{X_ {\text{Im}}[t;\text{H}]\}\end{array}  \tag{27}\]  
where \(X_{\text{Re}}[t;\text{H}]\) and \(X_{\text{Im}}[t;\text{H}]\) denote random variables of the real and imaginary parts of the correlator output, given in (24), at time instant \(t\) with hypothesis H, respectively. Further, \(I_{0}(r)\) denotes the first-order Bessel function of the first kind with an argument of \(r\). Furthermore, \(\text{E}[\cdot]\) and \(\text{V}[\cdot]\) denote the expectation and variance operator, respectively. The detection probability, \(P_{D}\), and false alarm probability, \(P_{F}\), are defined as:  
\[ \begin{array}{l}P_{D}=\text{Pr}\{\text{one correlator output under H}_{1}\text{ is greater than }\gamma\}\\ P_{F}=\text{Pr}\{\text{one correlator output under H}_{0}\text{ is greater than }\gamma\}\end{array}  \tag{28}\]  
Although it is not shown in (28) owing to notational difficulty, the time delay can be estimated when the squared magnitude of correlator output exceeds the threshold value. A high peak will appear at the time index where the received signal and reference waveform are fully matched, producing the estimate of time delay. Using the definition in (28), we can obtain the detection probability and false alarm probability as follows [17]:  
\[ \begin{array}{l}P_{D}=1-\prod\limits_{t=0}^{T_{W}-t_{t}}\Pr\{R[t;\mathrm{H}_{1} ]\leq\gamma\}=1-\prod\limits_{t=0}^{T_{W}-t_{t}}F_{R[t;\mathrm{H}_{1}]}(\gamma) \\ P_{F}=1-\prod\limits_{t=0}^{T_{W}-t_{t}}\Pr\{R[t;\mathrm{H}_{0}]\leq\gamma\}=1 -\prod\limits_{t=0}^{T_{W}-t_{s}}F_{R[t;\mathrm{H}_{0}]}(\gamma)\end{array}  \tag{29}\]  
where:  
\[