# Joint Power and Time Allocation in Hybrid NoMA/OMA IoT Networks for Two-Way Communications
## 3 Numerical Efficient Solution
The DL transmission rate C2 can be equivalently expressed as a convex one written by  
\[\log_{2}\left(1+\frac{\left|h_{k}\right|^{2}p_{\text{D},k}}{\sigma_{k}^{2}} \right)\geq\frac{\bar{R}_{\text{D},k}}{\tau_{k}}. \tag{9}\]  
Now that the constraints (6)-(8) are in DC form, and the other constraints together with the newly defined objective function are convex, the original problem (5) is accordingly transformed to be a DC programming problem given by  
\[\min_{\{\tau,\tau_{k},p_{\text{D},k},p_{\text{U},k},\mu_{\text{U},k},\mu_{\text{D},k}\}}\ q_{\text{U}}^{2}+\sum_{k=1}^{K}q_{\text{D},k}^{2}\] (10) \[\text{s.t.}\ \eqref{eq:constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_ constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_constraint_ constraint_constraint_constraint_constraint_constraint_constraint_constraint_ constraint_must be active when the problem (10) attains the optimum. We prove this by contradiction. When the constraints (6) and (10) are inactive, we can decrease \(q_{\text{U}}\) and \(q_{\text{D},k}\) to make them active. The \(q_{\text{U}}\) and \(q_{\text{D},k}\)'s decreases can further reduce the system's power consumption. Therefore, when the problem (10) attains the optimum, the constraints (6) and (7) must be active.  
Now that the problem (10) becomes a DC programming problem, SCA can be applied to transform it to be a convex one. By using the first-order Taylor approximation, the non-convex constraints (6)-(8) can be respectively transformed to be the following convex ones given by  
\[\frac{2\bar{q}_{\text{U}}}{\bar{\tau}}q_{\text{U}}-\frac{\bar{q}_{ \text{U}}^{2}}{\bar{\tau}^{2}}\tau\geq\sum_{k=1}^{K}p_{\text{U},k}, \tag{11}\]  
\[\frac{2\bar{q}_{\text{D},k}}{\bar{\tau}_{k}}q_{\text{D},k}-\frac{\bar{q}_{ \text{D},k}^{2}}{\bar{\tau}_{k}^{2}}\tau_{k}\geq p_{\text{D},k}, \tag{12}\]  
\[\log_{2}\left(\sum_{j=k}^{K}\left|h_{j}\right|^{2}p_{\text{U},j}+ \sigma_{\text{AP}}^{2}\right)-\log_{2}\left(\sum_{j=k+1}^{K}\left|h_{j}\right| ^{2}\bar{\rho}_{\text{U},j}+\sigma_{\text{AP}}^{2}\right)\] \[-\frac{\sum_{j=k+1}^{K}\left|h_{j}\right|^{2}\left(p_{\text{U},j} -\bar{\rho}_{\text{U},j}\right)}{\left(\sum_{j=k+1}^{K}\left|h_{j}\right|^{2} \bar{\rho}_{\text{U},j}+\sigma_{\text{AP}}^{2}\right)\ln 2}\geq\frac{\bar{R}_{\text{U},k} }{\tau}, \tag{13}\]  
where \(\bar{q}_{\text{U}}\), \(\bar{q}_{\text{D},k}\), \(\bar{\rho}_{\text{U},j}\), \(\bar{\tau}\), and \(\bar{\tau}_{k}\) are the points at which the first-order Taylor's expansions of the associated functions are carried out. Based on these transformations, the original non-convex problem (5) can be reformulated as the following convex one:  
\[\frac{q_{\text{D},k}^{2}}{\tau_{k}}\geq p_{\text{D},k}, \tag{7}\]0 (14) s.t. \[\eqref{eq:eq:eq:eq:eq:eq:eq:eq:eq:eq:eq:eq:eq:eq:eq:eq:eq:eq:eq: eq:eq:eq:eq:eq:eq:eq:eq:eq:eq:eq:  
_Algorithm Initialization._ In Algorithm 1,the optimization problem (14) is feasible only when the fixed values \(\left\{\tilde{q}_{U},\tilde{q}_{D,k},\tilde{p}_{U,k},\tilde{\tau},\tilde{\tau}_{k}\right\}\) are in the feasible set of the problem. While randomly chosen \(\left\{\tilde{q}_{U},\tilde{q}_{D,k},\tilde{p}_{U,k},\tau,\tilde{\tau}_{k}\right\}\) are generally outside the feasible set, an alternative initialization method becomes a must in order for Algorithm 1 to work properly. We present a simple yet efficient initialization method consisting of two steps. The first step is to pre-allocate the time resource among the UL, the DL, and the DL TDMA slots. For this, we can simply assume both equal-length two-way transmissions and equal-length DL TDMA transmissions, and in this case, we have \(\tau=\frac{1}{2}\), \(\tau_{k}=\frac{1}{2K}\) for any \(k\).