2.1 System model
As shown in Fig. 1, we consider an IoV system assisted by MEC, in which a MEC server is deployed at anchor node (AN) and the electric vehicle as a cognitive node connected with AN. Hence, computing tasks will be offloaded partially from electric vehicle nodes (eVNs) to MEC server. Moreover, we assume that the AN works in full-duplex mode which can transmit and receive signals using the same time-frequency resources so as to utilize SWIPT technology to fullfill energy of eVNs as well as receive the offloading computing tasks from the other eVNs at the same time. What’s more, each eVN is equipped with a power splitting receiver for ID and EH with the energy conversion ratio \(\beta\) (\(\beta \in (0,1)\)).
In Fig. 2, each vehicle node \(VN_i(i \in \{1,\ldots ,K\})\) offloads partial computing tasks \(m_i(0 \le m_i \le M_i)\) to the AN within the time duration \(\tau _i^{\text {u}}\), where \(M_i\) denotes the total computation tasks of \(VN_i\) and K is the number of vehicle nodes. Simultaneously, AN transmits the computation tasks \(m_j^{\text {r}}(j \in \{1,\ldots ,K\})\) executed by MEC server to \(VN_j\) within the time duration \(\tau _j^{\text {d}}\), where \(m_j^{\text {r}} = \alpha m_j (0 \le \alpha \le 1)\), and \(\alpha\) is the ratio of the completed computation tasks from the MEC server. Moreover, the computing time consumption of the MEC server is ignored resulting from the powerful computing ability of it comparing with the vehicle nodes [39]. Furthermore, the local computing tasks \(m_i^{\text {lo}}\), which equals \(M_i-m_i\), is completed during the time duration \(\tau _i^{\text {lo}}\). Besides, the uplink time consumption of each VN is assumed to be more than the local computing time consumption of that, which is expressed as \(0 \le \tau _i^{\text {lo}} \le \tau _i\). More details are given as follows.
Notations: The channel fading is modeled as Rayleigh distribution in this paper. \(\varvec{h}_i^{\text {u}} \in \mathbb {C c}^{N\times 1}\) and \(\varvec{h}_j^{\text {d}} \in \mathbb {C c}^{N\times 1}\) satisfy uniform distribution\(\sim U(0.5,1)\) which present the uplink and downlink channel, respectively, where N is the antenna numbers of AN, and the superscript \(\text {u}\) and \(\text {d}\) refer to uplink and downlink transmission, respectively. Meanwhile, \(\varvec{H}_{\text {an}}\) represents the self-interference channel of AN. \(d_i\) and \(\varvec{d}_j \in \mathbb {C c}^{N\times 1}\) represent the transmitted signal from vehicle node and AN respectively, where \(|\varvec{d}_j|=1\). Moreover, \(p_i\) and \(p_j\) denote the transmitting power of VN and AN, respectively. Besides, the additive white Gaussian noise (AWGN) of AN is denoted as \(\varvec{n}_{\text {an}}\) with covariance matrix \(\sigma _{\text {an}}^2 \varvec{I}_M\). Similarly, \(n_j\) and \(n_{\text {ps}}\) are the AWGN of \(VN_j\) and PS receiver with variance \(\sigma _j^2\) and \(\sigma _{\text {ps}}^2\), respectively. Finally, the bandwidth of the system is expressed as B.
2.1.1 Computation task processing
In uplink transmission, partial computing tasks are uploaded from vehicle nodes to the AN in turns. Specifically, \(VN_i\) transmits \(d_i\) with transmitting power \(p_i\) to the AN within the time slot \(\tau _i^{\text {u}}\). Simultaneously, the AN transmits \(\varvec{d}_j\) with transmitting power \(p_j\) to VN. Therefore, we can obtain the received signal at AN,
$$\begin{aligned} \begin{aligned} \varvec{x}_i^{u} = \sqrt{{p_i}} {\varvec{h}}_i^{\text {u}}{d_i} + {{\varvec{H}}_{\text {an}}}(\sqrt{{ p_j}} {\varvec{d}_j}) + \varvec{n}_{\text {an}} \end{aligned} \end{aligned}$$
(1)
where the first iterm represents the desired signal from \(VN_i\), while the self-interference at the AN is expressed as the second iterm, and the rest one is the AWGN of AN. Meanwhile, \(p_i\) is the transmitting power of vehicle node which satisfies \(p_{\text {min}} \le p_i \le p_{\text {max}}\), where \(p_{\text {min}}\) and \(p_{\text {max}}\) are the minimal and maximal transmitting power of each vehicle node.
According to (1), the received signal of VN is expressed as equation (2), while equation (3) represents the signal to interference and noise ratio (SINR)
$$\begin{aligned} P_i= & {} \text {Tr}\{ \varvec{x}_i(\varvec{x}_i)^H \}\nonumber \\= & {} p_i \text {Tr}\{ \varvec{h}_i^{\text {u}}(\varvec{h}_i^{\text {u}})^H\}+p_j \text {Tr}\{ \varvec{H}_{\text {an}}(\varvec{H}_{\text{ an }})^H\}+\delta _{\text {an}}^2 \end{aligned}$$
(2)
$$\begin{aligned} \gamma _i= & {} \frac{p_i \text {Tr}\{ \varvec{h}_i^{\text {u}}(\varvec{h}_i^{\text{ u }})^H\}}{p_j \text {Tr}\{ \varvec{H}_{\text {an}}(\varvec{H}_{\text{ an }})^H\}+\delta _{\text {an}}^2} \end{aligned}$$
(3)
where \((.)^H\), \(\text {Tr}\{.\}\) represent the conjugate and trace of matrix, respectively. According to the equation above, we can obtain the uplink rate which is written as
$$\begin{aligned} \begin{aligned} r_i ={\text {B}log_2}(1+\gamma _i) \end{aligned} \end{aligned}$$
(4)
As we know, if the self-interference can be eliminated completely by self-interference cancelation (SIC), the maximal SINR can be expressed as
$$\begin{aligned} \begin{aligned} \gamma _i^{\text {max}} =\frac{p_i \text {Tr}\{ \varvec{h}_i^{\text{ u }}(\varvec{h}_i^{\text {u}})^H\}}{\delta _{\text {an}}^2} \end{aligned} \end{aligned}$$
(5)
Hence, we can obtain the following ideal uplink rate
$$\begin{aligned} \begin{aligned} r_i^{\text {max}} ={\text {B}} log_2 (1+\gamma _i^{\text {max}}) \end{aligned} \end{aligned}$$
(6)
However, limited by SIC device, self interference cannot be completely eliminated. Therefore, the uplink rate should not exceed the ideal maximal uplink rate, i.e.,
$$\begin{aligned} \begin{aligned} r_i \le r_i^{\text {max}} \end{aligned} \end{aligned}$$
(7)
Based on the analysis above, each time slot \(\tau _i^{\text {u}}\) of uplink transmission and the energy consumption of \(VN_i\) can be formulated as follow,
$$\begin{aligned} \tau _i= & {} \frac{m_i}{r_i} \end{aligned}$$
(8)
$$\begin{aligned} e^{\text {vn}}_i= & {} p_i\frac{ m_i}{r_i} \end{aligned}$$
(9)
In consideration of the theory in [39], the local computing time duration and the consumption of energy in each vehicle node is written as
$$\begin{aligned} \tau _i^{\text {lo}}= & {} \sum _{i=1}^{C(M_i-m_i)} \frac{1}{f_i^{\text {t}}} \end{aligned}$$
(10)
$$\begin{aligned} e_i^{\text {lo}}= & {} \sum _{n=1}^{C(M_i-m_i)} {\kappa (f_i^{\text {t}})^2} \end{aligned}$$
(11)
where the required CPU cycle is represented as C which for computing one bit of data. And, for \({\text {t}}\)-th CPU cycles, the CPU frequency of \(VN_i\) is \(f_i^{\text {t}}\). Here, \(f_i^{\text {t}}\) should no more than the maximal CPU frequency \(f_i^{\text {max}}\). And \(\kappa\) denotes the efficient capacitance coefficient in view of the vehicles’ chip architecture.
2.1.2 Energy harvesting
Similarly, in the downlink transmission, \(VN_j\) receives signal from the AN including the desired RF signal and the AWGN at \(VN_j\), which are expressed as
$$\begin{aligned} \begin{aligned} x_j=\sqrt{p_j}(\varvec{h}_j^{\text {d}})^T \varvec{d}_j+n_j \end{aligned} \end{aligned}$$
(12)
In (12), \((.)^T\) is the transposition operation. Here, the co-channel interference between vehicle nodes are not considered, since the VNs upload the computing tasks to the anchor node in turns. Likewise, we obtain the signal power received at \(VN_i\) in (13) and equation (14) is the downlink signal to noise ratio (SNR).
$$\begin{aligned} P_j= & {} { p_j} \text {Tr}\{(\varvec{h}_j^{\text {d}})^T (\varvec{h}_j^{\text{ d }})^{TH}\} +\delta _j^2 \end{aligned}$$
(13)
$$\begin{aligned} \gamma _j= & {} \frac{\beta p_j \text {Tr}\{ (\varvec{h}_j^{\text{ d }})^T(\varvec{h}_j^{\text {d}})^{TH}\}}{\delta _j^2} \end{aligned}$$
(14)
Hence, the downlink rate and the time slot can be derived as
$$\begin{aligned} r_j= & {} Blog(1+\gamma _j) \end{aligned}$$
(15)
$$\begin{aligned} \tau _j= & {} \frac{\alpha m_j}{r_j} \end{aligned}$$
(16)
Based on the coefficient \(\beta\) of the PS receiver for EH, the energy of EH at \(VN_i\) is shown as
$$\begin{aligned} \begin{aligned} e_j^{\text {eh}}= \beta {p_j} \text {Tr}\{(\varvec{h}_j^{\text {d}})^T (\varvec{h}_j^{\text {d}})^{TH}\} \tau _j^{\text {d}} \end{aligned} \end{aligned}$$
(17)
2.1.3 Problem formulation
The computing time of the MEC server is ignored, since the computing ability of it is more powerful than that of vehicle’s [39]. And, we assume that \({\text {T}}\) is the overall duration. Hence, the relationship between the \({\text {T}}\) and the total transmission time in uplink and downlink of vehicles as shown in formula (18) and (19), respectively.
$$\begin{aligned} 0\le & {} \sum _{i=1}^K \tau _i^{\text {u}} \le {\text {T}} \end{aligned}$$
(18)
$$\begin{aligned} 0\le & {} \sum _{j=1}^K \tau _j^{\text {d}} \le {\text {T}} \end{aligned}$$
(19)
Moreover, since vehicle node is not able to transmit and receive signal simultaneously, there should be no overlap between uplink and downlink transmission time of a same vehicle node, i.e.,
$$\begin{aligned}&\sum _{i=1}^K \tau _i^{\text {u}}+ \tau _K^{\text {d}} \le {\text {T}} \end{aligned}$$
(20)
$$\begin{aligned}&\sum _{i=1}^{K_{tmp}} \tau _i^{\text {u}} \le {\text{ T }}-\sum _{j=K_{tmp}}^{K} \tau _j^{\text {d}} \end{aligned}$$
(21)
where \(K_{tmp} \in \{1,\ldots ,K\}\).
Meanwhile, the downlink transmission slot is less than the uplink transmission slot, so as to gurantee the computing tasks offloading from the next vehicle node can be processed at the AN without time latency and queuing. i.e.,
$$\begin{aligned} \begin{aligned} \tau _j^{\text {d}} \le \tau _i^{\text {u}}, j = i-1 \end{aligned} \end{aligned}$$
(22)
Besides, we assume that each vehicle node has enough energy to complete the computing due to the sufficient energy supply from the AN. Hence, the energy harvested from the AN should no more than the total transmitting power from the AN. Hence, the energy consumption of each vehicle should satisfy,
$$\begin{aligned} e_i^{\text {vn}} + e_i^{\text {lo}}\le & {} e_i^{\text {eh}} \end{aligned}$$
(23)
$$\begin{aligned} e_i^{\text {eh}}\le & {} e_i^{\text {an}} \end{aligned}$$
(24)
where \(e_i^{\text {an}}=p_j \tau _j^{\text {d}}\). According to the derivations above, we formulate the following problem (P1) which is aim to maximizing the average enery efficiency of the total vehicle nodes.
$$\begin{aligned} \begin{array}{cl} (P1) &{} \mathop {\max }\limits _{{\varvec{f}^{\text {t}}, \varvec{p}, \varvec{m},\varvec{r}}} \frac{1}{K}\{\sum _{i=1}^K \frac{r_i}{e_i^{\text {vn}}+e_i^{\text {lo}}}\}\\ &{} s.t. \left\{ \begin{array}{l} C1: e_i^{\text {vn}} + e_i^{\text {lo}} \le e_i^{\text {eh}}\\ C2: e_i^{\text {eh}} \le e_i^{\text {an}}\\ C3: 0 \le f_i^{\text {t}} \le f_i^{\text {max}}\\ C4: p_{\text {min}} \le p_i \le p_{\text {max}}\\ C5: 0 \le m_i \le M_i\\ C6: 0 \le r_i \le r_i^{\text {max}}\\ C7: 0 \le \tau _i^{\text {lo}} \le \tau _i^{\text {u}}\\ C8: \tau _j^{\text {d}} \le \tau _i^{\text {u}}, j = i-1\\ C9: 0 \le \sum _{i=1}^K \tau _i^{\text {u}} \le {\text {T}}\\ C10: 0 \le \sum _{j=1}^K \tau _j^{\text {d}} \le {\text {T}}\\ C11: \sum _{i=1}^{K_{tmp}} \tau _i^{\text {u}} \le {\text{ T }}-\sum _{j=K_{tmp}}^{K} \tau _j^{\text {d}} \end{array} \right. \end{array} \end{aligned}$$
(25)
where \(\varvec{f}^{\text {t}}=[f_1^{\text {t}},\ldots ,f_K^{\text {t}}]^T\), \(\varvec{p}=[p_1,\ldots ,p_K]^T\), \(\varvec{m}=[m_1,\ldots ,m_K]^T\), \(\varvec{r}=[r_1,\ldots ,r_K]^T\) represent the CPU frequency, the uplink transmitting power, the offloading computation tasks and the uplink rate of all vehicle nodes, respectively. Moreover, the \(f_i^{\text {max}}\) is the maximum CPU frequency.
2.2 Problem solution
Since the cost function and the constraints in problem (P1) are nonlinear and nonconvex, two subproblems are derived from the problem (P1) first. For the first subproblem, a closed-form expression of \(f^{\text {t}}\) with fixed variables \(\varvec{p}, \varvec{m}, \varvec{r}\) is obtained. Combining the first subproblem with (P1), we derive the second subproblem. For the second subproblem, we utilize an alternate interior-point iterative scheme after decompose it into three subproblems. Finally, the suboptimal varibles \(<\varvec{f}^{\text{ t }}, \varvec{p}, \varvec{m}, \varvec{r}>\) are abtained.
2.2.1 Local computing optimization
Inspired by [39], the optimal CPU frequency should satisfy
$$\begin{aligned} \begin{aligned} f_i^1=f_i^2=\cdots =f_i^{C(M_i-m_i)}=\frac{C(M_i-m_i)}{\tau _i^{\text{ lo }}}={\overline{f}}_i \end{aligned} \end{aligned}$$
(26)
where the average CPU frequency is denoted as \({{\overline{f}}}_i\). Based on the derivation above, the original problem (P1) is converted into the problem (P2) as following.
$$\begin{aligned} \begin{array}{cl} (P2) &{} \mathop {\min }\limits _{{\varvec{{{\overline{f}}}}}} \frac{1}{K}\left\{ \sum _{i=1}^K e_i^{\text {lo}}\right\} \\ &{} s.t. \left\{ \begin{array}{l} C1: e_i^{\text {vn}} + e_i^{\text {lo}} \le e_i^{\text {eh}}\\ C2: 0 \le \tau _i^{\text {lo}} \le \tau _i^{\text {u}}\\ \end{array} \right. \end{array} \end{aligned}$$
(27)
To futher simplify the problem (P2), we obtain the following problem (P3)
$$\begin{aligned} \begin{array}{cl} (P3) &{} \mathop {\min }\limits _{{\varvec{{{\overline{f}}}}}} \frac{1}{K}\left\{ \sum _{i=1}^K {\kappa C(M_i-m_i)({\overline{f}}_i)^2}\right\} \\ &{} s.t. \left\{ \begin{array}{l} C1: e_i^{\text {vn}} + {\kappa C(M_i-m_i)({\overline{f}}_i)^2} \le e_i^{\text {eh}}\\ C2: 0 \le \frac{C(M_i-m_i)}{{\overline{f}}_i} \le \tau _i^{\text {u}}\\ \end{array} \right. \end{array} \end{aligned}$$
(28)
where C2 indicates that \(\frac{C(M_i-m_i)}{\tau _i^{\text {u}}}\) is the lower limit of \({\overline{f}}_i\) as well as the optimal CPU frequency \(f_i^{\text {opt}}\).
2.2.2 Communication optimization
We obtan the rewritted problem (P4) by substituting the optimal CPU frequency \(f_i^{\text {opt}}\) into (P1).
$$\begin{aligned} \begin{array}{cl} (P4) &{} \mathop {\max }\limits _{{\varvec{p}, \varvec{m},\varvec{r}}} \frac{1}{K}\left\{ \sum _{i=1}^K \frac{r_i}{e_i^{\text {vn}}+e_i^{\text {lo}}}\right\} \\ &{} s.t. \left\{ \begin{array}{l} C1: e_i^{\text {vn}} + e_i^{\text {lo}} \le e_i^{\text {eh}}\\ C2: e_i^{\text {eh}} \le e_i^{\text {an}}\\ C3: p_{\text {min}} \le p_i \le p_{\text {max}}\\ C4: 0 \le m_i \le M_i\\ C5: 0 \le r_i \le r_i^{\text {max}}\\ C6: \tau _j^{\text {d}} \le \tau _i^{\text {u}}, j = i-1\\ C7: 0 \le \sum _{i=1}^K \tau _i^{\text {u}} \le {\text {T}}\\ C8: 0 \le \sum _{j=1}^K \tau _j^{\text {d}} \le {\text {T}}\\ C9: \sum _{i=1}^{K_{tmp}} \tau _i^{\text {u}} \le {\text{ T }}-\sum _{j=K_{tmp}}^{K} \tau _j^{\text {d}} \end{array} \right. \end{array} \end{aligned}$$
(29)
Since the problem (P4) is still a NP-hard problem, we continue to decompose it into three subproblems, which are denoted as (P4.1) \(\sim\) (P4.3), respectively.
$$\begin{aligned} \begin{array}{cl} (P4.1) &{} \mathop {\max }\limits _{{\varvec{p}}} \frac{1}{K}\left\{ \sum _{i=1}^K \frac{r_i}{e_i^{\text {vn}}+e_i^{\text {lo}}}\right\} \\ &{} s.t. \left\{ \begin{array}{l} C1: e_i^{\text {vn}} + e_i^{\text {lo}} \le e_i^{\text {eh}}\\ C2: e_i^{\text {eh}} \le e_i^{\text {an}}\\ C3: p_{\text {min}} \le p_i \le p_{\text {max}}\\ C4: \tau _j^{\text {d}} \le \tau _i^{\text {u}}, j = i-1\\ C5: 0 \le \sum _{i=1}^K \tau _i^{\text {u}} \le {\text {T}}\\ C6: 0 \le \sum _{j=1}^K \tau _j^{\text {d}} \le {\text {T}}\\ C7: \sum _{i=1}^{K_{tmp}} \tau _i^{\text {u}} \le {\text{ T }}-\sum _{j=K_{tmp}}^{K} \tau _j^{\text {d}} \end{array} \right. \end{array} \end{aligned}$$
(30)
The problem (P4.1) is only related to \(\varvec{p}\), which can be tackled by classical interior-point algorithm.
$$\begin{aligned} \begin{array}{cl} (P4.2) &{} \mathop {\max }\limits _{{\varvec{m}}} \frac{1}{K}\left\{ \sum _{i=1}^K \frac{r_i}{e_i^{\text {vn}}+e_i^{\text {lo}}}\right\} \\ &{} s.t. \left\{ \begin{array}{l} C1: e_i^{\text {vn}} + e_i^{\text {lo}} \le e_i^{\text {eh}}\\ C2: e_i^{\text {eh}} \le e_i^{\text {an}}\\ C3: 0 \le m_i \le M_i\\ C4: \tau _j^{\text {d}} \le \tau _i^{\text {u}}, j = i-1\\ C5: 0 \le \sum _{i=1}^K \tau _i^{\text {u}} \le {\text {T}}\\ C6: 0 \le \sum _{j=1}^K \tau _j^{\text {d}} \le {\text {T}}\\ C7: \sum _{i=1}^{K_{tmp}} \tau _i^{\text {u}} \le {\text{ T }}-\sum _{j=K_{tmp}}^{K} \tau _j^{\text {d}} \end{array} \right. \end{array} \end{aligned}$$
(31)
As same as the problem (P4.1), interior-point algorithm is used to address the problem (P4.2) to achieve the optimal \(\varvec{m}\).
$$\begin{aligned} \begin{array}{cl} (P4.3) &{} \mathop {\max }\limits _{{\varvec{r}}} \frac{1}{K}\left\{ \sum _{i=1}^K \frac{r_i}{e_i^{\text {vn}}+e_i^{\text {lo}}}\right\} \\ &{} s.t. \left\{ \begin{array}{l} C1: e_i^{\text {vn}} + e_i^{\text {lo}} \le e_i^{\text {eh}}\\ C2: e_i^{\text {eh}} \le e_i^{\text {an}}\\ C3: 0 \le r_i \le r_i^{\text {max}}\\ C4: \tau _j^{\text {d}} \le \tau _i^{\text {u}}, j = i-1\\ C5: 0 \le \sum _{i=1}^K \tau _i^{\text {u}} \le {\text {T}}\\ C6: 0 \le \sum _{j=1}^K \tau _j^{\text {d}} \le {\text {T}}\\ C7: \sum _{i=1}^{K_{tmp}} \tau _i^{\text {u}} \le {\text{ T }}-\sum _{j=K_{tmp}}^{K} \tau _j^{\text {d}} \end{array} \right. \end{array} \end{aligned}$$
(32)
Similarly, the optimal variable \(\varvec{r}\) is obtained by solving the problem (P4.3) using the interior-point algorithm.
Each subproblem of (P4.1) \(\sim\) (P4.3) is regarded as an approximate convex problem of the corresponding variable, while the other variable are fixed. In order to solve the problem (P4), each subproblem is addressed by classical interior-point algorithm. After that, the whole problem is solved by alternate iterative sheme, which is denoted as Algorithm 1.