Resource Allocation and Computation Offloading for Wireless Powered Mobile Edge Computing

In this paper, we investigate a resource allocation and computation offloading problem in a heterogeneous mobile edge computing (MEC) system. In the considered system, a wireless power transfer (WPT) base station (BS) with an MEC sever is able to deliver wireless energy to the mobile devices (MDs), and the MDs can utilize the harvested energy for local computing or task offloading to the WPT BS or a Macro BS (MBS) with a stronger computing server. In particular, we consider that the WPT BS can utilize full- or half-duplex wireless energy transmission mode to empower the MDs. The aim of this work focuses on optimizing the offloading decision, full/half-duplex energy harvesting mode and energy harvesting (EH) time allocation with the objective of minimizing the energy consumption of the MDs. As the formulate problem has a non-convex mixed integer programming structure, we use the quadratically constrained quadratic program (QCQP) and semi-definite relaxation (SDR) methods to solve it. The simulation results demonstrate the effectiveness of the proposed scheme.


Introduction
It is expected that future wireless networks can not only provide data and voice services to a massive number of MDs but also bring computational and artificial intelligence (AI) capabilities to the MDs. However, due to the size limitation, the MDs are typically constrained by computing capacity, storage capacity and battery capacity, which will prevent MDs from performing seamless computational tasks. Therefore, tackling the energy and battery capacity challenges urgently demand for developing new wireless network paradigms [1].
With the development of Internet technology and mobile network, the data generated by MDs and application have significantly increased [1]. In addition, the increasing demand for computing and data service from massive MDs have urged the development of a wireless network, which integrates the computing capability into the wireless network. Cloud computing emerges as a new computing paradigm which provides computing services to a large amount of MDs. The cloud computing server has powerful computing processing capacity, and MDs can offload computing tasks to the cloud server for computing processing. However, the cloud computing servers are usually distant from the MDs [2]. Therefore, during the process of task transmission, a large delay and a large amount of energy consumption will be induced, which is unfavorable to solving real-time task processing with the low time delay requirement of MDs.
In order to provide MDs with more proximity, lower latency and reduced energy consumption for computing services, MEC has been attracted considerable attention. MEC has the potential to provide computing capabilities close to the MDs within the radio access • In the proposed MEC system, we consider full-duplex and half-duplex WPT modes and analyze the energy consumption problems under these two different energy transfer modes separately with the aim to derive the optimal mode selection strategy. • In particular, we design a three-tier heterogeneous MEC offloading network architecture that considers the multi-level computational task offloading problem, where the tasks of MDs can be executed locally, offloaded to a server with energy source for computing, or transformed to a remote MEC server for processing; • In addition, we investigate an optimization problem involving the minimization of transmission and computational energy consumption based on complete time and energy constraints, which is a non-convex mixed-integer programming problem. We derive the optimal offloading decision strategy and WPT mode by adopting QCQP and SDR methods; • Moreover, we analyze the optimal time of EH for MDs under the half-duplex energy transfer mode with a linear form of WPT. Finally, we propose an iterative algorithm with the aim to solve the joint optimal offloading decision, time allocation of WPT under the half-duplex EH mode, as well as the mode selection.
The reminder of this paper is organized as follows. Section 2 is concerned with giving a brief review of relevant research work. In Section 3, we present the system model. The problem formulation and constraints are proposed in Section 4. In Section 5, we demonstrate the simulation results. Finally, Section 6 concludes this research and discusses future directions.

Related Work
MEC technology has been widely used in the communication field and different scenarios to provide services to network edge users by taking advantage of mobile edge computing servers closer to users and abundant computing resources [13]. To solve the resource allocation problem in a dynamic computational offload environment, in [14], the authors used a deep reinforcement learning-based approach and proposed a deep deterministic policy gradient (DDPG) dynamic policy to solve the dynamic offload, computational offload and resource allocation problems. With the development of blockchain technology [15], MEC technology is used in blockchain, and MEC technology can be used to solve the challenge of insufficient computational power of MDs in mining tasks [16]. MEC technology has been further applied to vehicle networking for driver assistance services to improve the safety and intelligence of vehicle driving [17]. However, how to ensure that MDs in the MEC network system perform a long time computing task offloading, maintain the MDs with enough power for computing task offloading, and guarantee that the MEC network system can operate for a long time is also one of the main challenges currently faced.
More recently, there has been a growing research interest in exploring the application of EH and WPT in MEC systems [1]. In [18], the authors proposed an actor-critic learning algorithm based on mixed decision making, and a deep reinforcement learning algorithm of multi-MD mixed actor-critic for dynamic computing and offloading was proposed. Similarly, in [19], a deep reinforcement learning-based online offloading algorithm was proposed with the goal of maximizing the weighted sum of computational rates and optimizing the time allocation for the user task offloading decisions scheme and wireless EH. In the single-user MEC system, the authors propose an energy-efficient resource allocation scheme for WPT and task allocation for the local and offloading computation of MDs. Considering the unpredictability of EH and the situation of dynamic offloading of computation tasks, in [6], the authors presented an online algorithm of the Lyapunov method to optimize the stability of the battery queue and minimize the power consumption. Considering the nonlinear energy collection mode [20], the authors investigated the resource allocation to maximize the computational efficiency and optimized the EH time, the CPU cycle frequency of the local computation, the offloading time, and the power allocation to obtain the optimal solution. In [21], in order to minimize the system cost, the authors proposed a distributed optimization problem to solve the optimal offloading, charging and discharging energy and renewable energy utilization rate of MBSs. In [22], the authors investigated the computational offloading and resource allocation problem in IoT networks, which simultaneously support end-device mobility and energy harvesting, and they proposed a Lyapunov optimization and semi-definite programming (SDP)-based online mobility-aware offloading and resource allocation algorithm.
Several studies have revealed that wireless information and power transfer technology provides a potential solution to increase the data transmission rate and long-term service of user equipment in the wireless network. Meanwhile, EH technology can also be implemented to enhance the energy efficiency of network [23,24]. In [23], the au-thors investigated resource allocation for the orthogonal frequency division multiplexing (OFDM)-based nonorthogonal multiple access (NOMA) system empowered by WPT technology with the aim to obtain secure and energy efficient transmission. Similar to [24], the authors researched an energy-efficient resource allocation for the WPT-enabled orthogonal frequency division multiple access (OFDMA) multicell networks. In order to achieve long battery life, in [25], the authors introduce an online learning algorithm with a distributed execution approach for computational offloading in WP-MEC networks, which aims to minimize the long-term average task completion delay of mobile clients. In [26], the authors combined social networking techniques and EH techniques for enhancing the performance of fog computing systems. In [27], the authors introduced a wireless energy harvesting (WEH)-based industrial Internet of Things (CIIoT) to harvest RF energy from primary user signals, and they proposed energy-efficient resource allocation under different spectrum access methods to maximize the average transmission rate of the CIIoT while maintaining energy-saving requirements. In [28], the authors proposed an MEC offloading scheme for cellular IoT networks with a large number of NOMA-assisted energy harvesting MDs based on social relationships among the user communication devices to optimize the processing mode selection, device clustering, channel and power allocation for the purpose of maximizing the total network rate and under the constraints of power, energy and delay.
With the application and development of wireless networks, it has become an important research field to apply full-duplex and half-duplex technology to the current communication system based on wireless energy transform technology. To solve the resource allocation problem in multi-access edge computation offloading, the full-duplex assisted multi-access edge computation offloading system is investigated in [29], and they proposed a step-wise resource allocation method for enhancing the performance of the computation offloading subject to data rate constraint. In [30], the authors studied an unmanned aerial vehicle (UAV) wireless communication system with EH, where the UAV transmits energy to MDs in half-duplex or full-duplex manner, and the user first collects energy and then offloads the data to the UAV, with the goal of minimizing the total energy consumption of the UAV and achieving minimal delay requirement of the data transmission of the user. Considering the security of wireless communication system, in [31], the authors examined the energy-constraint secrecy performance of a wireless network with passive eavesdroppers and wireless information and power energy transmission, and they proposed a full-duplex automatic jamming scheme. In [32], the authors investigate the problem of opportunity mode selection and user scheduling in both single-carrier and multi-carrier OFDM full-duplex systems with the objective of maximizing the system utility (e.g., sum rate) for long-term and short-term time fairness.

System Model
The three-tier WPT MEC system model is shown in Figure 1. The system model consists of multiple MDs, WPT BS, and MBS. The WPT BS transmits energy to the neighboring users in a broadcast mode, and each MD has a wireless energy-harvesting capability, and the harvested energy is stored. The MD is closer to the WPT BS, while the distance to the MBS is relatively long. Throughout this paper, we use U = { 1, 2, 3 . . . , i, . . . , U} , i ∈ U to represent the set of MDs. Each MD i is equipped with an EH battery, and the computing capacity of i is defined as ]. Furthermore, MDs have full/half-duplex EH modes, and the harvested energy will be stored in the battery. The WPT BS is represented by WPT BS and adopts full-duplex or half-duplex mode to carry out WPT for MDs, and it can also provide computing services with computing capacity F R . In order to enhance the computing capacity of the system, a server with powerful computing capacity is integrated into MBS, and the computing capacity of the MBS server is represented by F M . In the three-tier heterogeneous MEC system, MDs are able to choose to perform local computing, either offloading computing tasks to a server at the WPT BS for executing or offloading to a remote MBS server for processing. The uplink between the MD and the WPT BS or MBS employs a wireless connection for the communication and offloading of computation tasks, while in the downlink, the WPT BS and MBS return the processed computation task results to the MD, and since the data size of the computation results is relatively small, hence, we ignore the transmission delay and communication energy consumption of the computation result return in the downlink in this case.

MBS WPT BS Mobile device
Task offloading Energy harvesting Self-interference In the proposed MEC system, we suppose that the task of MD i is completed within a time interval t i . We assume that MDs take the EH and task processing simultaneously based on full-duplex mode. In half-duplex mode, the MD i performs EH during time slot τ i firstly, and then, the task will be processed within time slot t i − τ i . We express the data size of the computing task for MD i in terms of d i , and w represents the number of CPU cycles required to calculate each bit of data. The term A i = [a i,l , a i,R , a i,M ], i ∈ U will be used in this paper to refer the set of computing task offloading decision factors. The computational tasks of each MD can be optionally computed locally or be offloaded to the wPT BS or MBS server for computing. Specifically, a i,l = 1 represents the selection factor calculated locally by the MDs, a i,R = 1 means that the MD i chooses the WPT BS for offloading computation, and a i,M = 1 indicates that the MDs choose the MBS server for the offloading process; otherwise, a i,l = a i,R = a i,M = 0. The key notation can be found in Table 1. Due to the fact that the computation task of the MDs can only choose one of the offloading decisions for computing, we can obtain the offloading decision strategy constraints as follows: (1)

U
The set of MDs in the system

Local Computing Mode
When the local computing is adopted, the processing capacity of MDs can be dynamically adjusted according to the size of the task and the completion time of the task by employing dynamic voltage and frequency expansion technology [18,33]. We assume that the computing capability F l i of the MD i remains unchanged. Accordingly, the time for local computation processing can be defined as follows: Furthermore, the energy consumption of local computing of the MD i can be expressed as follows: where ω is the number of effective capacitors related to chip structure [34], and w represents the number of CPU cycles required to calculate each bit of data.

WPT BS Server Model
Given that the WPT BS is capable of transmitting energy to the MDs via wireless transmission during the computation offloading, in the current system, we consider the use of half-duplex and full-duplex methods for energy transmission. The distance between MD i and WPT BS is D R i , and the channel gain between MD i and WPT BS is g i,R = (D i,r ) σ , where σ = −4 is the path loss factor.

Half-Duplex Mode
In the half-duplex mode [30], WPT BS firstly transmits energy to the MD i in the time τ i , where 0 < τ i < t i is the time allocation for EH under half-duplex mode. Then, the computational task of MD i will be processed locally or offloaded to the server during the remaining time (t i − τ i ).
With the half-duplex mode, the achievable uplink transmission rate between the MD i and the WPT BS can be given by: where p i,R is the transmit power of MD i and and P i,R ≤ P max i . I is the noise power, B i,R is the transmission bandwidth. The harvested energy and transmission energy consumption in half-duplex mode are respectively calculated by [35],

Full-Duplex Mode
In full-duplex mode, WPT BS transmits wireless energy to the MD i, and the transmit power is P R . Meanwhile, the MD i can choose to offload the task to the base station for computing within the time through the harvested energy. We consider linear EH in the proposed MEC network system; thus, during time t i , the energy harvested by the MD i can be given by [35] e FD i = ςP R t i .
In full-duplex WPT mode, the WPT BS can simultaneously transmit to and receive task offloading from the MDs. In this case, self-coherent interference is generated. Then, the achievable uplink transmission rate between the MD i and the WPT BS becomes: P R denotes the transmit power of the WPT BS, and σ denotes the effective selfinterference coefficient in full-duplex mode [30]. The transmission energy consumption of MD i for transmitting to WPT BS can be expressed by

MBS Server Model
In the considered system, MDs can also choose to offload computation tasks to an MBS server. The server of MBS is integrated with powerful computing units. Let us assume that the distance between the MD i and the MBS is D i,M , and the channel gain between the MD i and MBS is g i,M = (D i,M ) σ . The uplink transmission rate is given as follows: where p i,M represents the transmit power of MD i, and B i,M is the transmission bandwidth. The transmission energy consumption is given by: The computing energy consumption of the MBS server can be expressed by: where ϕ represents the amount of energy consumed per CPU cycle by the MBS server to perform computing tasks for MDs.

Problem Formulation
In this section, we formulate an optimization problem with the aim to minimize the overall energy consumption of computation tasks of MDs. We optimize the offloading decision strategy A i , EH time allocation {τ i }, and full/half-duplex mode optimal decision x HD i , x FD i based on the energy constrained of MD i and the delay of the computation task. Mathematically, the optimization problem is shown as follows: where indicates that the MD i selects a full-duplex EH mode, and only one of the EH modes decision can be selected. C5 makes sure that the energy consumption is less than the harvested energy. C6 denotes the time allocation for EH with half-duplex mode. C7-C9 are utilized to guarantee that the computing resources allocated to an MD should be limited. C10 indicates that the task processing latency for different task computation and offloading methods under the selected full-duplex mode by the MD i is lower than the maximum allowable time slot t i . C11 denotes that in half-duplex mode, the MD performs EH first before the task processing in time τ i ; i.e., the delay of the task processing cannot exceed the remaining time slot t i − τ i .
The computation offloading decision factor A i = {a i,l , a i,R , a i,M } and the full-duplex and half-duplex mode decision strategy x i = {x FD i , x HD i } are integer variables, and the EH time allocation τ i is a continuous variable. In this case, we note that the formulated problem P1 is a mixed integer programming problem. The computational complexity of addressing this problem is high. Therefore, we employ an iterative method to solve the optimization problem P1. Firstly, the optimization problem P1 can be transformed into separable QCQP, and then, the method of SDR is used to obtain the binary computing offloading decision and the optimal mode selection [36]. Then, we will use the convex optimization program method to solve the time τ i for EH based on the half-duplex mode.

Computation Offloading Decision Strategy
We assume that x i = {x FD i , x HD i } and τ i are given. Initially, we can convert the problem P1 with an equivalent QCQP form so as to achieve the SDR formulation finally according to [37].

QCQP Form and SDR
The variable set of A i is integer variable. Thus, we rewrite constraint C2 as follows: P1 can be formulated as follows: P2 : min The problem P2 is still non-convex, and it is difficult to be solved as C2 a are non-convex quadratic constraints. In the following, the problem is transformed into a convex problem based on QCQP transformation, and then, we adopt SDR to obtain the fractional solution.
We vectorized the parameters and variables in P2 as v = [a 1,l , a 1,R , a 1,M , . . . , a U,l , a U,R , a U,M ] T , x HD U p U,R d U r HD Accordingly, the problem P2 is converted into an equivalent QCQP problem as follows: where However, the formulated problem of P3 is still a non-convex separable QCQP problem which results in the problem remaining intractable. For the purpose of finding approximate solutions, we utilize SDR, which is an effective method to simplify the QCQP problem [36].

Semi-Definite Relaxtion
We define a semi-definite matrix V = [v T ,1] T [v T , 1] of rank one. The problem P3 will be relaxed into a separable semi-definite programming problem as shown below: Tr(ZV) C1 : Tr(Z i V) = 1, ∀i ∈ U, C2 : Tr(Z j V) = 1, j = 1, 2, . . . , 3U, where P3 is still non-convex due to the rank constraint C14. The problem can be relaxed to a semi-positive definite programming problem by discarding the rank constraint as follows: Therefore, the original problem is reformulated to the standard convex optimization problem, and we adopt standard CVX tools to address problem P3 [38].

Extracting Offloading Decision
Hereafter, we extract a feasible solution v for P3 from the global optimal solution V * of P3 , and we obtain the optimal offloading decision from the feasible solution v according to [39,40].
According to the definition of V, we know that only the submatrix of V * topmost coordinates 3N × 3N, defined as V *, is necessary to obtain the offloading decision A i , and that all diagonal elements of V * are positive numbers from 0 to 1. Let us define pr= [pr 1,l , pr 1,R , pr 1,M , . . . , pr U,l , pr U,R , pr U,M ] T ∆ = diag(V * ), where each of these terms pr represents the probability of corresponding entry of A i being 1. We to satisfy the constraint a i,l + a i,R + a i,M = 1. According to the probabilities of local computing, the WPT BS server execution and the MEC server execution are expressed as , respectively. The computation task offloading decision of MD i is given in the following: O n = (1, 0, 0) means that the computation task will be calculated with probability Pr i,l in local computing.
O n = (0, 1, 0) shows that the computation task can be calculated with probability Pr i,R in the WPT BS server.
O n = (0, 0, 1) defines the computation task will be computed with probability Pr i,M in the MBS server.
As a result, by randomly setting the value of the vector according to (25), P3 can be resolved and the offloading decisions a i,l , a i,R , a i,M can be obtained.

Time Allocation on the Half-Duplex Mode
In this part, we will dedicate to solve the EH time allocation in half-duplex mode based on a given offloading decision A i and EH pattern x i . Based on half-duplex mode, x HD i = 1. The MD performs EH and task calculation independently. Considering that in the half-duplex mode, the time of τ i is used for EH, and that the remaining time of (t i − τ i ) is used for task offloading and computing, the energy consumption includes the energy consumption of local computation and the energy consumption of computation task processing. The energy consumption problem is shown below: where Due to the fact that the objective function is independent of the time variable τ i , we represent the energy consumption in the objective function of P4 with ψ HD i , thus The constraint C3 can be expressed as: Problem P4 can be rewritten to the problem P4 as follows: P4 : min To resolve the problem P4', so that ψ HD i achieves the minimum value and the transmission and computation time constraints of the computation task are met, we use tight operation, let Then, problem P4 can be transformed into the following form of problem P4 : P4 : min From the constraints C3 and C9, the dominant of τ i can be expressed as: The objective function and constraint conditions in P4 are linear about the variables τ i , so it is a convex optimization problem. The minimum optimal value is obtained at the boundary point, and the optimal value of τ i is:

Full/Half-Duplex Mode Selection
For the given solution of A i and τ i , we can solve the selection decision of full/halfduplex EH model. Similar to the optimize offloading decision strategy, the variables of the full/half-duplex EH mode decision are still integer variables. Thus, we determine the main objective problem, which is related to variables about x i = {x FD i , x HD i }; then, the objective problem will be converted to the QCQP form, and we adopt the SDR to obtain the fractional solution.
We can reformulate the constraint of C4 as follows: The problem P5 can be formulated as shown: Due to the fact that the constraint C4 (b) is a non-convex quadratic constraint, the problem P6 is still non-convex and challenging to solve. In order to obtain the optimum decision strategy, we transform the problem into QCQP form initially and SDR to obtain the fractional solution.

QCQP Form
By defining x = [x HD 1 , x FD 1 , . . . , x HD U , x FD U ], the problem can be converted into an equivalent QCQP problem as below: where Similarly, the QCQP formulation is still a non-convex separable QCQP problem and hard to be solved. Therefore, we take the SDR method to simply the QCQP problem.

Semi-Definite Relaxtion
In order to utilize the SDR method, we define where However, in problem P7 , the rank constraint (45) is the only non-constraint. Therefore, we will relax problem P7 into a semi-definite programming problem by dropping the rank constraint as follows: P7 : min X Tr(QX) Now, we have reformulated the problem into a standard convex optimization problem, and it can be solved in polynominal time with standard CVX tools such as SeDuMi [36].

Full/Half-Duplex Mode Decision Extraction
In this part, we extract a feasible solution x from the global optimal solution X * of the above problem, and we obtain the optimal offloading decision in feasible solution x according to the method proposed in [39,40].
According to the definition of X, we know that only the submatrix of X * whose topmost coordinate is 2N × 2N, defined as X * , is necessary to obtain the optimal full/half-duplex decision x, and that all diagonal elements of X * are positive numbers from 0 to 1. We define , where each term of p represents the probability of corresponding term of x i being 1.
In order to satisfy x HD i , and based on this, the probabilities of full/half-duplex are According to the above solution, the full/half-duplex EH mode decision of MD i is given by the following formula: Ω i = (1, 0) means that we choose half-duplex mode with probability p i, f ; Ω i = (0, 1) means that we choose full-duplex mode with probability p i,h . By randomly setting the value of the vector according to the probabilities in (47), P6 can be resolved, and we can obtain the offloading decisions x HD i , x FD i .

Algorithm Analysis
To this end, we design an algorithm for optimizing the offloading decision strategy, EH time allocation and full/half-duplex mode optimization based on the proposed approach. First of all, the system parameters of computation tasks and network are initialized. Since the offloading decision is randomly obtained based on the obtained probability, we can run the aforementioned procedure several times to obtain a more precise decision. Based on the given EH mode x i and EH time allocation τ i , we can obtain A n i , which is denoted as the offloading decision for the nth time. Then, based on the A n i and τ i , we can perform EH mode optimization. After that, based on A n i and x i n , we can carry out half-duplex EH time allocation, and the solution with smallest energy consumption target value is the final solution. Compare the objective value of all the N solutions, and select the solution with minimum objective value. 14: end for 15: Output: The optimal solutions of the offloading strategy A * i , EH time allocation τ * i and the EH mode scheme x * i .

Numerical Results
In this section, we conduct extensive simulations to verify the feasibility and superiority of the proposed scheme. In this simulation, we used a hardware setup with a desktop computer with 8 G memory capacity, hard disk data size of 1 T, 3.20 GHz CPU frequency, and 64-bit Windows system as the operating system. The software used was MATLAB software for the simulation experiments. We set the number of MDs to 10, one WPT BS, and a macro base station with an integrated powerful server. We set the data size for any task between 10 and 110 KB, and the maximum transmission power of MDs was 30 dbm. The bandwidth size between the MDs and the WPT BS was set to be 20 MHZ, and the bandwidth between the MDs and the MBS was 50 MHZ. The average distance between the MDs and the WPT BS was 100 m, and the maximum distance between the MDs and the MBS is 500 m. We set the transmission power of the WPT BS as 40 dbm.
In Figure 2, we plot the energy consumption of the computation tasks with different data sizes when adopting different computing strategies. From Figure 2, we can see that the energy consumption of all different computation methods increases as the size of the task keeps increasing. Under the local computing approach, the MD is limited by the battery capacity and computing capability, which consumes more energy compared to offloading the task to WPT BS and the MBS server for computing. Self-interference will be generated when MDs employ full-duplex EH technology, which affects the transmission rate of task offloading, thus increasing the transmission energy consumption during task offloading. In Figure 3, we show the effect of the distance between the MD and the BSs on the energy consumption of MD. As shown in this figure, it can be found that the computational energy consumption of the task does not vary with distance when the MD chooses to compute locally. On the contrary, when the MD chooses to offload to the WPT BS or the MBS for computing, the transmission energy consumption during task offloading increases as the distance between the MDs and the BS increases. When the MD selects full-duplex mode for EH, it will reduce the data transmission rate and thus requires more transmission energy consumption because the full-duplex mode receives and transmits wireless signals at the same time. However, under the half-duplex mode, MDs will harvest energy at first, and then, the task will be offloaded to servers for computing. It can also be found that the MDs that offload to the MBS consume less energy because the channel bandwidth between the MDs and the MBS is larger than the bandwidth between the WPT BS and the MD. Moreover, in Figure 4, we present a three-dimensional diagram of the energy consumption by changing the distance between the MDs and WPT BS as well as the task data size. Such a phenomenon indicates that the energy consumption of the computation task becomes larger as the distance between the MD and the WPT BS increases. Meanwhile, as the data size of the computation task increases, the energy consumption for computation task offloading and task processing tends to increase. In Figures 5 and 6, we describe the transmission rate of computation task offloading data and the EH by MD regarding the number of MDs in the network system proposed in the paper under the full-duplex EH technique based on the MD. We assume that the transmission power of the WPT BS is P R = {8w, 10w, 12w}. From Figure 5, we can observe that as the number of MDs increases, the task offloading rate between the MDs and the WPT BS decreases subsequently. This is because under the full-duplex EH model, selfinterference is easily generated, which increases the interference of computation task offloading in the wireless channel and thus decreases the rate of data transmission. It can be seen from Figure 6 that as the number of MDs increases, the offloading transmission rate decreases, which increases the offloading time. In order to complete the task within the maximum allowed delay, the MDs need to harvest more energy provided by the WPT BS. It can be seen from both Figures 5 and 6 that in order to increase the offloading rate, the transmission power between the MDs and the WPT BS needs to be increased.  In Figure 7, we plot the harvested energy of the MDs based on full-duplex and half-duplex mode. From Figure 7, we can see that the harvested energy by the MDs in fullduplex and half-duplex modes increases linearly with the increment of time. In full-duplex mode, the MDs can perform task offloading at the same time or perform EH during local computation, while in half-duplex mode, the MDs performs EH before task offloading and computation, which will reduce the time for EH, so more energy is harvested in full-duplex mode than in half-duplex mode. In the half-duplex mode, when the MD adopts local computing, the time for task processing increases due to the limited computing capacity of MD, thus reducing the time for EH. On the contrary, when the MDs choose to offload to the WPT BS and MBS server for task computation, the MBS server has a powerful task processing capacity and the time for offloading and computation is reduced; then, the time for EH will increase, and more energy can be obtained.

Conclusions
In this paper, we have considered a three-tier heterogeneous MEC based on an intelligent network system for offloading energy harvesting. The system model consists of MDs, WPT BS, and MBS integrated with powerful servers, where tasks generated by the user's MD can be computed locally or offloaded to the wireless energy supply base station servers and the MBS server for computation. In this work, the full/half-duplex energy harvesting-based technology is adopted. To minimize the overall energy consumption for task offloading and computation in heterogeneous network systems, the computation task offloading decision, the energy-harvesting time in full/half-duplex mode, and the energy-harvesting mode selection decision for full/half-duplex is optimized. We show that this optimization problem is a non-convex separable QCQP, which is an NP-hard problem, and the SDR method and the binary recovery method are employed to obtain the optimal decisions while solving for the optimal time resource allocation in different energyharvesting modes. Simulation results showed that the proposed method and algorithm can achieves the optimal solution. Furthermore, the joint dynamic computation offloading of the computation task and mobility of MDs which based on WPT-based MEC network system is one of the interest for future research.