## 3 Power Allocation of SCO\(-\)AN
### Objective Function of Power Allocation
#### 3.1.1 Objective Function of Power Allocation for SISO Communication System
The initial secrecy capacity is \(C_{sec}^{co}\). \[\log\Biggl{(}1+\frac{|\hat{H}|^{2}x}{\sigma_{n}^{2}+|H_{eo}|^{2}x+|\hat{H}|^{ 2}y+|H_{eo}|^{2}y}\biggr{)}-\log\Biggl{(}1+\frac{|G_{k}|^{2}x_{0}}{|G_{k}|^{2} y_{0}+\sigma_{e}^{2}}\biggr{)}=C_{sec}^{co} \tag{25}\]  
The power allocation problem of SCO\(-\)AN for SISO under imperfect channel estimation is written as:  
\[ \begin{split}\min&-\log\Biggl{(}1+\frac{|\hat{H}|^{ 2}x}{\sigma_{n}^{2}+|H_{eo}|^{2}x+|\hat{H}|^{2}y+|H_{eo}|^{2}y}\biggr{)}+\log \Biggl{(}1+\frac{|G_{k}|^{2}x}{|G_{k}|^{2}y+\sigma_{e}^{2}}\biggr{)}\\ \text{s.t.}&\log\Biggl{(}1+\frac{|\hat{H}|^{2}x}{ \sigma_{n}^{2}+|H_{eo}|^{2}x+|\hat{H}|^{2}y+|H_{eo}|^{2}y}\biggr{)}-\log \Biggl{(}1+\frac{|G_{k}|^{2}x}{|G_{k}|^{2}y+\sigma_{e}^{2}}\biggr{)}>C_{sec}^{ co}\\ &\log\Biggl{(}1+\frac{|\hat{H}|^{2}x}{\sigma_{n}^{2}+|H_{eo}|^{2} x+|\hat{H}|^{2}y+|H_{eo}|^{2}y}\biggr{)}\geq K\\ & x+y\leq P\\ & x>0\\ & y>0\end{split}  \tag{26}\]  
The Lagrange function of (26) is:  
\[L(x,y,\mu,\lambda)=f(x,y)-\mu_{1}h_{1}(x,y)-\sum_{j=1,2,3,4}\lambda_{j}g_{j}( x,y), \tag{27}\]  
where  
\[ \begin{split} f(x,y)&=-\log\biggl{(}1+\frac{|\hat{H}| ^{2}x}{\sigma_{n}^{2}+|H_{0}|^{2}x+|\hat{H}|^{2}y+|H_{eo}|^{2}y}\biggr{)}+\log \biggl{(}1+\frac{|G_{k}|^{2}x}{|G_{k}|^{2}y+\sigma_{e}^{2}}\biggr{)}\\ g_{1}(x,y)&=\log\biggl{(}1+\frac{|\hat{H}|^{2}x}{ \sigma_{n}^{2}+|H_{0}|^{2}x+|\hat{H}|^{2}y+|H_{eo}|^{2}y}\biggr{)}-\log\biggl{(} 1+\frac{|G_{k}|^{2}x}{|G_{k}|^{2}y+\sigma_{e}^{2}}\biggr{)}-C_{sec}^{co}\\ g_{2}(x,y)&=x\\ g_{3}(x,y)&=y\\ g_{4}(x,y)&=\log\biggl{(}\frac{|\hat{H}|^{2}x}{ \sigma_{n}^{2}+|H_{0}|^{2}x+|\hat{H}|^{2}y+|H_{eo}|^{2}y}\biggr{)}-K\\ h_{1}(x,y)&=x+y-P.\end{split}  \tag{28}\]The most frequently used methods for channel estimation are least square (LS) channel estimation and minimum mean square error (MMSE) channel estimation. LS channel estimation is a classic algorithm for non-blind channel estimation. The pilot symbols are used to estimate the channel. The LS channel estimation is given as:  
\[\mathbf{\tilde{H}}_{LS}=\mathbf{z}_{k}(\mathbf{x}_{k})^{-1}. \tag{29}\]  
For the MIMO communication system, the LS channel estimation is:  
\[ \begin{split}\left\|\mathbf{H}_{\omega}^{LS}\right\|^{2}& =\left\|\mathbf{H}-\mathbf{\tilde{H}}_{LS}\right\|^{2}\\ &=\left\|(\mathbf{z}_{k}-\mathbf{n})\mathbf{x}_{k}^{-1}-\mathbf{ x}_{k}\mathbf{x}_{k}^{-1}\right\|^{2}\\ &=\left\|\mathbf{nx}_{k}^{-1}\right\|^{2}.\end{split}  \tag{30}\]  
In (30), \(\mathbf{H}_{\omega}^{LS}\) denotes the error of LS channel estimation and \(\left\|\mathbf{H}_{\omega}^{LS}\right\|^{2}\) denotes the second norm of the LS channel estimation error. \(\left\|\mathbf{H}_{\omega}^{LS}\right\|^{2}\) is in proportion to the SNR of the legitimate channel. For the SISO communication system, the LS channel estimation is:  
\[\left|H_{\omega}^{LS}\right|^{2}=\left|H-\widetilde{H}_{LS}\right|^{2}=\left| nx_{k}^{-1}\right|^{2}. \tag{31}\]  
For the MIMO communication system, similar to LS estimation, it is easy to obtain (32):  
\[ \begin{split}\left\|\mathbf{H}_{\omega}^{MMSE}\right\|^{2}& =\left\|\mathbf{H}-\mathbf{\tilde{H}}_{\mathbf{MMSE}}\right\|^{2}\\ &=\left\|\mathbf{H}-R_{\mathbf{H\tilde{H}}}(R_{\mathbf{HHH}}+ \frac{\sigma_{\theta}^{2}}{\sigma_{z}^{2}}I)^{-1}\mathbf{\tilde{H}}_{LS} \right\|^{2}\\ &=\left\|\mathbf{H}-R_{\mathbf{H\tilde{H}}}(R_{\mathbf{HHH}}+ \frac{\sigma_{\theta}^{2}}{\sigma_{z}^{2}}I)^{-1}\mathbf{y}_{k}\mathbf{x}_{k }^{-1}\right\|^{2},\end{split}  \tag{32}\]  
where \(\mathbf{H}_{\omega}^{MMSE}\) denotes the error of MMSE channel estimation and \(R_{\mathbf{AB}}\) denotes the cross-correlation matrix of \(\mathbf{A}\) and \(\mathbf{B}\). For SISO communication system, \(R_{AB}\) denotes the cross-correlation coefficient of \(A\) and \(B\). \[