# Pilot-Based Adaptive Channel Estimation for Underwater Spatial Modulation Technologies
## 3 Optimal Detector  
Recently, the FGSM [15] and EFGSM [39] have been proposed to the UWA channel to improve the energy loss of the underwater sensor network. The transmission vector of the SMTs-MIMO is transmitted over underwater time-varying MIMO channel with an AWGN. As a result, the received signal after MIMO channel at the receiver can be represented as:  
\[\mathbf{y}=\mathbf{H}\mathbf{x}+\mathbf{v}, \tag{11}\]  
where \(\mathbf{y}\) is the received data \(\mathbf{y}\in\mathbb{C}^{N_{t}\times 1}\), \(\mathbf{H}\) denotes the UWA channel \(\mathbf{H}\in\mathbb{C}^{N_{t}\times N_{t}}\), \(\mathbf{x}\) is the sending data mapped by SMTs \(\mathbf{x}\in\mathbb{C}^{N_{t}\times 1}\) and an AWGN \(\mathbf{v}\in\mathbb{C}^{N_{r}\times 1}\) with identically independent (i.i.d) Gaussian distributed represented as \(\mathbf{v}\sim CN(0,\sigma^{2})\), and \(N_{r}\) is the number of receiver antennas, where \(\mathbf{v}\) is the complex value of the AWGN, and can be written as:  
\[\mathbf{v}=[v_{1},v_{2},...,v_{N_{t}}]^{\mathsf{T}}. \tag{12}\]  
Hence, Equation (11) can be written as:  
\[\left[\begin{array}{c}y_{1}\\ y_{2}\\ \vdots\\ y_{N_{t}}\end{array}\right]=\left[\begin{array}{cccc}\mathbf{h}_{11}& \mathbf{h}_{12}&\ldots&\mathbf{h}_{1N_{t}}\\ \mathbf{h}_{21}&\mathbf{h}_{22}&\ldots&\mathbf{h}_{2N_{t}}\\ \vdots&\vdots&\ddots&\vdots\\ \mathbf{h}_{N_{t}1}&\mathbf{h}_{N_{t}2}&\ldots&\mathbf{h}_{N_{t}N_{t}}\end{array} \right]\times\left[\begin{array}{c}x_{1}\\ x_{2}\\ \vdots\\ x_{N_{t}}\end{array}\right]+\left[\begin{array}{c}v_{1}\\ v_{2}\\ \vdots\\ v_{N_{t}}\end{array}\right]. \tag{13}\]  
The detection of antenna indices is a very challenging task in SMTs, in SM, GSM and FGSM antennas active are one constant number of antennas, and one or more/all, respectively. Among the set of transmit antennas, to detect the transmitted data, the antenna indices must be decided at the receiver side. The conventional ML optimal detector is used in the SMTs to detect the data constellation and antenna indices, and its representation equation can be written as [24]:  
\[[\widehat{g}_{ML},\widehat{k}_{ML}]=\operatorname*{arg\,max}_{g,k}p_{Y}( \mathbf{y}|\mathbf{x}_{g},\mathbf{H}). \tag{14}\]  
The \(\mathbf{x}_{g}\) is the \(k^{th}\) data symbol from M-ary constellation transmitted over the channel \(\mathbf{h}_{g}\) which represents the \(g^{th}\) row of the matrix channel \(\mathbf{H}\). As we can see in (5), (8), and (10) \(\mathbf{x}_{g}\) varies for different \(g\) and \(k\). The pdf conditioned to \(\mathbf{x}_{g}\) and \(\mathbf{h}_{g}\) of \(\mathbf{y}\) in Equation (14) can be stated as:  
\begin{table}
\begin{tabular}{c c c c} \hline
**Block Bits** & **Spatial Bits** & **Data Bits** & **Antenna Index** \\ \hline
000 b1b2 & 000 & b1b2 & 1 \\
001 b1b2 & 001 & b1b2 & 2 \\
010 b1b2 & 010 & b1b2 & 3 \\
011 b1b2 & 011 & b1b2 & 4 \\
100 b1b2 & 100 & b1b2 & 1,2 \\
101 b1b2 & 101 & b1b2 & 1,3 \\
110 b1b2 & 110 & b1b2 & 1,4 \\
111 b1b2 & 111 & b1b2 & 2,3 \\ \hline \end{tabular}
\end{table}
Table 4: Example of FGSM mapping for 5 bpcu, \(N_{t}=4\) and 4-QAM modulation.  
\[p_{Y}(\mathbf{y}|\mathbf{x}_{g},\mathbf{H})=\pi^{-N_{t}}\exp(-||\mathbf{y}-\mathbf{ h}_{g}x_{k}||_{F}^{2}), \tag{15}\]  
where  
\[\mathbf{h}_{g}=[h_{g1},h_{g2},...,h_{gN_{t}}]. \tag{16}\]  
After using (14) the optimal detector can be represented as:  
\[[\hat{g}_{ML},\hat{k}_{ML}]=\operatorname*{arg\,min}_{g,k}||\mathbf{j}_{gk}||_ {F}^{2}-2\Re\{\mathbf{y}^{H}\mathbf{j}_{gk}\}, \tag{17}\]  
where \(\mathbf{j}_{gk}=\mathbf{h}_{g}x_{k}\), \(1\leq g\leq N_{t}\), \(1\leq k\leq M\) and \(\Re\{.\}\) is the real operator. If both \(\widehat{g}_{ML}\) and \(\widehat{k}_{ML}\) is detected correctly by the receiver, then they can be demapped easily and combined to demodulate the transmitting bits. For accurate detection, at the receiver side the completed CSI should be available.