# Efficient Low-Complexity Turbo-Hadamard Code in UAV Anti-Jamming Communications
## 3 Low-Complexity Turbo-Hadamard Codes Based on Tail-Biting
### The Tail-Biting Turbo-Hadamard Decoder
The partial branch metric \(\gamma\) is defined as  
\[\gamma_{k}\Big{(}\pm\mathbf{h}^{j}\Big{)}=A\text{exp}\bigg{(}\frac{1}{2}\Big{<}\pm \mathbf{h}^{j},\{\mathbf{L}_{ak},\tilde{\mathbf{P}}_{k}\}\Big{>}\bigg{)}, \tag{16}\]  
where \(\mathbf{h}^{j}\) is the \(j\)th column of the Hadamard matrix, \(A\) is a constant, \(\mathbf{L}_{ak}\) is the \(k\)th row of \(\mathbf{L}_{a}\), and \(\tilde{\mathbf{P}}_{k}\) is denoted as the \(k\)th row of \(\tilde{\mathbf{P}}\). The logarithm partial branch metric \(g\) is calculated in the \(g\) computing unit (GCU) and defined as  
\[ \begin{split} g_{k}\Big{(}\pm\mathbf{h}^{j}\Big{)}&= \text{log}\Big{(}\gamma_{k}\Big{(}\pm\mathbf{h}^{j}\Big{)}\Big{)}\\ &=\text{log}(A)+\frac{1}{2}\Big{<}\pm\mathbf{h}^{j},\{\mathbf{L}_{ak}, \tilde{\mathbf{P}}_{k}\}\Big{>},\end{split}  \tag{17}\]  
where \(\text{log}(A)\) can be omitted as a constant. The full branch metric \(\lambda\) is defined as  
\[\lambda(s_{k-1},s_{k})=\sum_{(s_{k-1},s_{k})}\gamma_{k}\Big{(}\pm\mathbf{h}^{j} \Big{)}, \tag{18}\]where \(\lambda(s_{k-1},s_{k})\) denotes all parallel branches between \(s_{k-1}\) and \(s_{k}\). The logarithm'sfully branch metric \(l\) is defined as  
\[ \begin{split} l(s_{k-1},s_{k})&=\log\left(\sum \limits_{(s_{k-1},s_{k})}\exp\Bigl{(}g_{k}\Bigl{(}\pm\mathbf{h}^{j}\Bigr{)} \Bigr{)}\right)\\ &\approx\max\limits_{(s_{k-1},s_{k})}\Bigl{(}g_{k}\Bigl{(}\pm \mathbf{h}^{j}\Bigr{)}\Bigr{)}.\end{split}  \tag{19}\]  
The forward recursive metric \(\alpha\) in forward recursion is defined as  
\[\alpha(s_{k})=\sum\limits_{\forall s_{k-1}}\lambda(s_{k-1},s_{k})\alpha(s_{k- 1}). \tag{20}\]  
The logarithm's forward recursive metric \(a\) is calculated in the \(a\) computing unit (ACU) and defined as  
\[ \begin{split} a(s_{k})&=\log\left(\sum\limits_{(s_ {k-1},s_{k})}\exp(l(s_{k-1},s_{k})+a(s_{k-1}))\right)\\ &\approx\max\limits_{s_{k-1}}(l(s_{k-1},s_{k})+a(s_{k-1})).\end{split}  \tag{21}\]  
Correspondingly, the backward recursive metric \(b\) is defined as  
\[\beta(s_{k})=\sum\limits_{\forall s_{k+1}}\lambda(s_{k},s_{k+1})\beta(s_{k+1}), \tag{22}\]  
and the logarithm's backward recursive metric \(b\) is calculated in \(b\) computing units (BCU) and defined as  
\[b(s_{k})\approx\max\limits_{s_{k+1}}(l(s_{k},s_{k+1})+b(s_{k+1})). \tag{23}\]  
The \(k\)th row's \(i\)th bit of the posterior LLR of information bits \(L_{k}[i]\) is calculated in the LLR computing unit (LCU) and defined as  
\[L_{k}[i]=\log\frac{\sum\limits_{H[i,j]=\pm 1}\left(\gamma_{k}\bigl{(}\pm \mathbf{h}^{j}\bigr{)}\sum\limits_{\forall s_{k},s_{k+1}}\alpha(s_{k})\beta(s _{k+1})\right)}{\sum\limits_{H[i,j]=\mp 1}\left(\gamma_{k}\bigl{(}\pm\mathbf{h}^{j} \bigr{)}\sum\limits_{\forall s_{k},s_{k+1}}\alpha(s_{k})\beta(s_{k+1})\right)}, \tag{24}\]  
and this can then be simplified to  
\[ \begin{split} L_{k}[i]&\approx\max\limits_{H[i,j]= \pm 1}\left(g_{k}\Bigl{(}\pm\mathbf{h}^{j}\Bigr{)}+\max\limits_{(s_{k},s_{k+1})}( a(s_{k})+b(s_{k+1}))\right)\\ &-\max\limits_{H[i,j]=\mp 1}\left(g_{k}\Bigl{(}\pm\mathbf{h}^{j} \Bigr{)}+\max\limits_{(s_{k},s_{k+1})}(a(s_{k})+b(s_{k+1}))\right).\end{split}  \tag{25}\]  
\(r\) denotes the order of the Hadamard code, \(k=K\times r\) denotes the length of information bits and \(\eta\) represents the memory depth of the convolutional code. The maximum value of \(\delta\) elements can be obtained by calculating the \(\delta\) maximum value of \((\delta-1)\) pairs' elements. Moreover, the maximum value of an element pair can be evaluated by a subtraction and all subtraction can be evaluated by addition. Thus, calculating the maximum value of \(\delta\) elements requires \((\delta-1)\) additions. In each iteration, the proposed turbo-Hadamard codes based on tail-biting need to calculate \(K\) times, whereas the turbo-Hadamard codes [20] need to calculate \((K+\eta)\) times. Therefore, we can obtain the computation complexity estimation of the decoder through (17) to (25).