# Co-Efficient Vector Based Differential Distributed Quasi-Orthogonal Space Time Frequency Coding
## 4 Pairwise Error Probability Analysis  
We then proceeded to develop sufficient conditions based on the PEP analysis for our code to achieve full diversity of order \(P\Gamma\) while the coding gain was maximized as much as possible. Since each of the \(K\) blocks contained arbitrary symbols, which were independently distributed across the relay nodes, only a single block \(k\) is required for our PEP analysis, which was valid for any \(k=1,2,\ldots,K\). It was assumed that the path gains \(f_{p,t}(l)\) and \(g_{p,t}(l)\) were independent for different transmission paths such that the \(P\) relay nodes form spatially uncorrelated channels between the source node and the destination. Thus, \(P\Gamma\) information symbols are simultaneously distributed in the spatial, temporal, and frequency dimensions. Based on this, and the analysis of [31], the achievable diversity order of our code could be determined as the product of the number of relay nodes, the rank of the temporal correlation matrix, and the number of delay paths, when sufficient conditions were reached. These conditions were discussed below. The frequency response vector between the source node and the relay nodes was denoted by \(\mathbf{f}_{k}=\left[f_{k}(1),\ldots,f_{k}(P\Gamma)\right]^{T}\). Similarly, the frequency response vector between the relay nodes and the destination was \(\mathbf{g}_{k}=\left[g_{k,1}(1),\ldots,g_{k,1}(\Gamma),\ldots,g_{k,P}(1),\ldots,g_ {k,P}(\Gamma)\right]^{T}\). The correlation matrix of the channel frequency response could be found as \(\mathbf{R}=E\left\{\mathbf{h}_{k}\mathbf{h}_{k}^{H}\right\}=E\left\{(\mathbf{f}_{k}\odot\mathbf{g }_{k})(\mathbf{f}_{k}\odot\mathbf{g}_{k})^{H}\right\}\). Unlike the case of multiple antenna systems, the cooperative network had the 'transmit' and 'cooperate' stages; thus, \(\mathbf{R}\) could be decomposed as \(\mathbf{R}=\mathbf{R}_{1}\odot\mathbf{R}_{2}\). It can easily be shown that \(\mathbf{R}\), \(\mathbf{R}_{1}\), and \(\mathbf{R}_{2}\) were full rank based on the following:  
\[\mathbf{R}_{1}=E\left\{\mathbf{f}_{p}\mathbf{f}_{k}^{H}\right\} =\mathbf{W}_{1}E\left\{\mathbf{f}_{p,t}\mathbf{f}_{p,t}^{H}\right\}\mathbf{W}_{1} ^{H} \tag{21}\] \[=\mathbf{W}_{1}diag\left(\sigma_{5R}{}^{2}(0),\ldots,\sigma_{5R}{}^{ 2}(L_{SR}-1)\right)\mathbf{W}_{1}^{H}\] \[\mathbf{R}_{2}=E\left\{\mathbf{g}_{k}\mathbf{g}_{k}^{H}\right\} =\mathbf{W}_{2}E\left\{\mathbf{g}_{p,t}\mathbf{g}_{p,t}^{H}\right\}\mathbf{W}_{2} ^{H}\] (22) \[=\mathbf{W}_{2}diag\left(\sigma_{RD}{}^{2}(0),\ldots,\sigma_{RD}{}^{ 2}(L_{RD}-1)\right)\mathbf{W}_{2}^{H}\] \[\mathbf{W}_{1}=\left[\mathbf{w}^{\mathbf{a}_{0}{}^{T}},\ldots,\mathbf{w}^{\mathbf{a}_ {L-1}{}^{T}}\right],\mathbf{W}_{2}=\left[\mathbf{w}^{\mathbf{g}_{0}{}^{T}},\ldots,\mathbf{w}^{ \mathbf{b}_{L-1}{}^{T}}\right],\] \[\mathbf{w}=\left[1,\omega^{1},\ldots,\omega^{(P\Gamma-1)}\right],\omega =e^{-j2\pi\Delta f} \tag{23}\]  
where \(\mathbf{f}_{p,t}=\left[f_{p,t}(0),\ldots,f_{p,t}(L_{SR}-1)\right]^{T}\) and \(\mathbf{g}_{p,t}=\left[g_{p,t}(0),\ldots,g_{p,t}(L_{RD}-1)\right]^{T}\), and \(\Delta f=1/T\) was the sub-carrier spacing. From (23), if \(\mathbf{W}_{1}\) and \(\mathbf{W}_{2}\) were unitary matrices (valid if all \(L_{SR}\) and \(L_{RD}\) fall within the sampling instances of the relay nodes and destination respectively [31], then \(\mathbf{W}_{1}\) and \(\mathbf{W}_{2}\) have full rank. Furthermore, based on the theorem in Section 1.2.4 of [32], which stated that; if \(\mathbf{R}_{1}\) and \(\mathbf{R}_{2}\) were positive definite, then \(\mathbf{R}\) was itself a positive definite (full rank correlation matrix), \(\mathbf{R}\), \(\mathbf{R}_{1}\), and \(\mathbf{R}_{2}\) could thus be verified as positive definite (full rank correlation matrices). Since it was established that \(\mathbf{R}\) had full rank, we then proceeded to discuss the criteria in order to achieve maximum diversity. Statistically independent samples of the source relay channel were defined as \(\mathbf{f}=[f_{1,t}(0),\ldots,f_{1,t}(L_{SR}-1),\ldots,f_{P,t}(0),\ldots,f_{P,t}(L_{ SR}-1)]\).