# Performance Optimization of Underwater Communication Links at Different Ranges for AIS Relay to AUV
## 3 Proposed Underwater Acoustic Modem
### Multi-Carrier Spread Spectrum  
Depending on the target mission, in practice distance between the buoy and the AUVs ranges from less than a kilometer to tens of kilometers. Thus, the modem needs to be able to adapt its characteristics in such a way that the communication between the buoy and the AUVs stays stable and reliable. MC-SS combines spreading and MC signal. Multiple combinations of spreading and OFDM have been proposed [12; 13; 14; 15; 16]. To have both frequency and time diversity, the designed modem uses a 2D orthogonal variable spreading factor (OVSF) with spreading code \(\mathbf{C}\)[17]. Coding matrix \(\mathbf{C}\) has a size of \(Q\times M\) where \(M\) designs the SF in the time domain and \(Q\) is the SF in the frequency domain. \(Q\) must be a divisor of the number of subcarriers \(K\). Thereby, \(I=\frac{K}{Q}\) Quadrature phase shift keying (QPSK) symbols can be sent on 1 MC-SS-2D symbol. Figure 1: Performance of academic and commercial modems. \[\mathbf{C}= \begin{pmatrix}c_{0}&...&c_{m}&...&c_{M-1}\\ \vdots&\vdots&\vdots&\vdots\\ c_{qM}&c_{qM+m}&c_{qM+M-1}\\ \vdots&\vdots&\vdots&\vdots\\ c_{(Q-1)M}&...&c_{(Q-1)M+m}&c_{QM-1}\end{pmatrix}  \tag{1}\]  
MC-SS-2D transmitter structure is shown in Figure 2, where \(\mathbf{d}=[d_{0},\ldots,d_{I-1}]\) represents \(I\) QPSK symbols for \(1\) MC-SS-2D symbol, \(K\) is the number of subcarriers and \(\mathbf{s}=[s_{0},\ldots,s_{K-1}]\) is a scrambling code. To better understand how the waveform is created, let us use an example with:  
* \(K=12\);
* \(Q=4\);
* \(M=4\);
* \(I=3\). As one can be shown in Figure 2, QPSK data symbols \(\mathbf{d}=[d_{0},\ldots,d_{I-1}]\) are first repeated Q times. Repetition is performed by creating a matrix where each QPSK symbol is diagonally repeated \(Q\) times as illustrated with the example in Figure 3.  
Then, spreading is realized by multiplying by the matrix \(\mathbf{C}\). Result of this operation is illustrated in Figure 4.  
Figure 3: Example: QPSK symbols repetition for MC-SS-2D. Figure 2: MC-SS 2D transmitter structure. A frequency interleaver is then applied. Interleaving is used to maximize the distance between two chips of the same QPSK symbols in the frequency domain (the distance between two symbols \(d_{0}\) in Figure 5 for instance) and, therefore, to increase the frequency diversity. Indeed, frequency diversity is present if channel coefficients affecting two chips of the same data symbols are independent. As shown in Figure 5, the separation in the frequency domain between each chip from the same QPSK symbol is maximized and equal to \(I=\oint\limits_{Q}\). Finally, the spread symbols are scrambled with a complex sequence \(\mathbf{s}\) before being modulated on different subcarriers using inverse FFT. Each subcarrier is multiplied by one chip of the scrambling code. With this scheme, the SF can be modified in both time and frequency domains giving this scheme flexibility in how it uses time and frequency diversity. Furthermore, setting \(M=1\) or \(Q=1\), scheme of the MC-SS waveform with spreading only in the frequency domain or time domain is obtained. If both \(M\) and \(Q\) are equal to 1, an OFDM waveform is obtained. Figure 4: Example: spreading in MC-SS-2D. Figure 5: Example: frequency interleaving in MC-SS-2D. Figure 6 represents the corresponding receiver structure. After FFT, received signal for 1 MC-SS-2D symbol is given by:  
\[r_{k,m}=d_{k\%_{k}l}c_{\left\lfloor\frac{k}{l}\right\rfloor M+m}s_{k}\tilde{h}_ {k,m}+w_{k,m} \tag{2}\]  
where \(k\in\{0,\dots,K-1\}\) is the subcarrier index and \(m\in\{0,\dots,M-1\}\) is the time index representing all OFDM symbols for 1 MC-SS-2D symbol, % is the modulo symbol and \(\bigcup\) is floor function. Function \(\tilde{h}_{k,m}\) is the frequency response of the channel affecting one subcarrier and \(w_{k,m}\) is an additive noise. To retrieve QPSK symbols, five steps are needed. First, received signal is multiplied by conjugate of the scrambling code.