## 3 Power Allocation of SCO\(-\)AN
### Objective Function of Power Allocation  
#### 3.1.1 Objective Function of Power Allocation for SISO Communication System  
\(\|\mathbf{p}_{k}\|^{2}\)=1 and \(\mathbf{Z}_{k}\) is a standard orthonormal basis for \(\mathbf{H}_{k}\), which means \(\mathbf{Z}_{k}\mathbf{Z}_{k}^{\intercal}=\mathbf{I}\) for MIMO and \(Z_{k}Z_{k}^{\intercal}=1\) for SISO. We assume that the transmission power is P.  
\[\sigma_{g}^{2}+\sigma_{u}^{2}\leq P. \tag{20}\]  
We use \(x\) instead of \(\sigma_{u}^{2}\) and \(y\) instead of \(\sigma_{g}^{2}\). The initial states of \(x\) and \(y\) are \(x_{0}\) and \(y_{0}\) respectively. For the SISO communication system, the secrecy capacity before power allocation is \(C_{sec}^{0}\). Therefore:  
\[\log\left(1+\frac{|H_{k}|^{2}x_{0}}{\sigma_{n}^{2}+|H_{k}|^{2}y_{0}}\right)- \log\left(1+\frac{|G_{k}|^{2}x_{0}}{|G_{k}|^{2}y_{0}+\sigma_{e}^{2}}\right)=C_ {sec}^{0}. \tag{21}\]  
There are no variables except \(x_{0}\) and \(y_{0}\) in (21). The power allocation problem of SCO\(-\)AN for SISO is written as:  
min \[\log\left(1+\frac{|G_{k}|^{2}x}{|G_{k}|^{2}y+\sigma_{e}^{2}}\right) -\log\left(1+\frac{|H_{k}|^{2}x}{\sigma_{n}^{2}+|H_{k}|^{2}y}\right)\] s.t. \[\log\left(1+\frac{|H_{k}|^{2}x}{\sigma_{n}^{2}+|H_{k}|^{2}y} \right)-\log\left(1+\frac{|G_{k}|^{2}x}{|G_{k}|^{2}y+\sigma_{e}^{2}}\right)>C_ {sec}^{0}\] (22) \[\log\left(\frac{|H_{k}|^{2}x}{\sigma_{n}^{2}+|H_{k}|^{2}y}\right) \geq K\] \[x+y\leq P\] \[x>0\] \[y>0\]  
In (22), a restricted condition \(\log\left(1+\frac{|H_{k}|^{2}x}{\sigma_{n}^{2}+|H_{k}|^{2}y}\right)-\log \left(1+\frac{|G_{k}|^{2}x}{|G_{k}|^{2}y+\sigma_{e}^{2}}\right)>C_{sec}^{0}\) is added to make sure that the optimal direction is correct. SCO\(-\)AN is an extra noise for Bob the receiver as well. \(K\) is the minimum signal-to-noise ratio (SNR) for normal communication. We add another restricted condition \(\log\left(1+\frac{|H_{k}|^{2}x}{\sigma_{n}^{2}+|H_{k}|^{2}y}\right)\geq K\) to ensure normal communication. The value of \(K\) varies among different communication systems. The objective function in (22) is \(\log\left(1+\frac{|G_{k}|^{2}x}{|G_{k}|^{2}y+\sigma_{e}^{2}}\right)-\log \left(1+\frac{|H_{k}|^{2}x}{\sigma_{n}^{2}+|H_{k}|^{2}y}\right)\). The Hessian matrix of the objective function in (22) is not positive definite, so the extremum of the objective function cannot be obtained by the partial derivative method. An improved sequence quadratic program (ISQP) is adopted to optimize power allocation. The basic idea of ISQP is that, at each iterative step, a quadratic programming problem is solved to \begin{table}
\begin{tabular}{c c c c c c} \hline \hline \multirow{2}{*}{**Method**} & \multirow{2}{*}{**Design Difficulty**} & **Secrecy Capacity** & \multirow{2}{*}{**Application**} & \multirow{2}{*}{**Connection with H**} & \multirow{2}{*}{**Connection with G**} \\  & & **Improvement** & & & & \\ \hline AN & tough & normal & normal & in null space & in range space \\ SCO\(-\)AN & easy & good & good & in range space & in range space \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Comparison of AN and SCO\(-\)AN. establish a descent direction, which reduces the value function to obtain compensation. The iterative steps are repeated until the solution of the original problem is obtained. The Lagrange function of (22) 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{23}\]  
where  
\[ \begin{split} f(x,y)&=-\log\biggl{(}1+\frac{|H_{ 1}|^{2}x}{\sigma_{n}^{2}+|H_{0}|^{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{|H_{1}|^{2}x}{ \sigma_{n}^{2}+|H_{0}|^{2}y}\biggr{)}-\log\biggl{(}1+\frac{|G_{k}|^{2}x}{|G_{k }|^{2}y+\sigma_{e}^{2}}\biggr{)}-C_{sec}0\\ g_{2}(x,y)&=x\\ g_{3}(x,y)&=y\\ g_{4}(x,y)&=\log\biggl{(}\frac{|H_{0}|^{2}x}{\sigma_{ n}^{2}+|H_{0}|^{2}y}\biggr{)}-\mathrm{K}\\ h_{1}(x,y)&=x+y-P.\end{split}  \tag{24}\]  
For the case of imperfect channel estimation, the initial states of \(x\) and \(y\) are \(x_{0}\) and \(y_{0}\) respectively.