reinforcement learning based multi-access control …1 reinforcement learning based multi-access...

12
1 Reinforcement Learning based Multi-Access Control and Battery Prediction with Energy Harvesting in IoT Systems Man Chu, Hang Li, Member, IEEE, Xuewen Liao, Member, IEEE, and Shuguang Cui, Fellow, IEEE Abstract—Energy harvesting (EH) is a promising technique to fulfill the long-term and self-sustainable operations for Internet of things (IoT) systems. In this paper, we study the joint access control and battery prediction problems in a small-cell IoT sys- tem including multiple EH user equipments (UEs) and one base station (BS) with limited uplink access channels. Each UE has a rechargeable battery with finite capacity. The system control is modeled as a Markov decision process without complete prior knowledge assumed at the BS, which also deals with large sizes in both state and action spaces. First, to handle the access control problem assuming causal battery and channel state information, we propose a scheduling algorithm that maximizes the uplink transmission sum rate based on reinforcement learning (RL) with deep Q-network (DQN) enhancement. Second, for the battery prediction problem, with a fixed round-robin access control policy adopted, we develop a RL based algorithm to minimize the prediction loss (error) without any model knowledge about the energy source and energy arrival process. Finally, the joint access control and battery prediction problem is investigated, where we propose a two-layer RL network to simultaneously deal with maximizing the sum rate and minimizing the prediction loss: the first layer is for battery prediction, the second layer generates the access policy based on the output from the first layer. Experiment results show that the three proposed RL algorithms can achieve better performances compared with existing benchmarks. Index Terms—Internet of things, energy harvesting, reinforce- ment learning, access control , battery prediction. I. I NTRODUCTION The Internet of things (IoT) has a crucial need for long-term or self-sustainable operations to support various applications [1] [2]. In recent years, energy harvesting (EH) has been recognized as an emerging technique that may significantly increase the network lifetime and help reduce the greenhouse gas emissions in general wireless applications [3] [4] [5]. This technology trend provides a promising energy solution This work was accepted in part at the IEEE GLOBECOM, Abu Dhabi, UAE, 2018. The work was supported in part by grant NSFC- 61629101, by NSF with grants DMS-1622433, AST-1547436, ECCS- 1659025, and by Shenzhen Fundamental Research Fund under Grants No. KQTD2015033114415450 and No. ZDSYS201707251409055. M. Chu and X. Liao are with the Department of Information and Communi- cation Engineering, Xi’an Jiaotong University, Xi’an, 710049, China (e-mail: cmcc [email protected], [email protected]). H. Li is with the Shenzhen Research Institute of Big Data, Shenzhen, China (e-mail: [email protected]). S. Cui is with the Shenzhen Research Institute of Big Data and School of Science and Engineering, the Chinese University of Hong Kong, Shen- zhen, China. He is also affiliated with Department of Electrical and Com- puter Engineering, University of California, Davis, CA, 95616. (Email: [email protected]). Corresponding author: S. Cui. for IoT applications [6] [7]. Accordingly, EH has been being intensively discussed for supporting the future IoT systems, in D2D communications, wireless sensor networks, and fu- ture cellular networks [8] [9]. Fundamentally, the amount of harvested energy may be unpredictable due to the stochastic nature of energy sources, i.e., energy arrives at random times and in arbitrary amounts, which poses great challenges to researchers [5] [10]. It can be expected that how to handle the dynamics of the harvested energy would be a key design issue in EH based wireless communication systems. A. Related Works and Motivations In general, the related research works on EH based systems could be categorized into two classes based on the availabil- ity of the knowledge about energy arrivals. The first class comprises offline approaches that require complete non-causal knowledge of the considered stochastic system, which are usually adopted to derive the performance upper bounds [11] [12] [13]. In particular, the optimal uplink resource allocation was investigated in [12] for the scenario where two EH users first harvested energy from the wireless signals and then cooperatively sent information to the access point. Also, the optimal packet scheduling over multiple access channels was studied in [13], with the goal of minimizing the time by which all packets from both users are delivered to the destination. The second class comprises online approaches [14] [15] [16]. Authors in [14] studied a multi-access wireless system with EH transmitters, and the access problem was modeled as a partially observable Markov decision process (POMDP). In [15], the optimal power control policies for EH nodes in a multi-access system was considered, where a dam model was constructed to capture the dynamics of the EH process. In these approaches, some statistic knowledge regarding the dynamic system should be known at the transmitters [16]. In many practical applications, the complete non-casual knowl- edge or even statistical knowledge of the system dynamics (including both the channel and energy parts) might not be available, especially when the EH processes are non-stationary or from sources with unknown distributions. For example, in a wireless network with solar EH nodes distributed randomly over a geographical area, the characteristics of the harvested energy at each node depend on the node location, and change over time in a non-stationary fashion [17]. In such cases, the priori knowledge about dynamics of energy sources is very difficult to obtain. arXiv:1805.05929v2 [eess.SP] 21 Sep 2018

Upload: others

Post on 16-Jul-2020

6 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Reinforcement Learning based Multi-Access Control …1 Reinforcement Learning based Multi-Access Control and Battery Prediction with Energy Harvesting in IoT Systems Man Chu, Hang

1

Reinforcement Learning based Multi-AccessControl and Battery Prediction with Energy

Harvesting in IoT SystemsMan Chu, Hang Li, Member, IEEE, Xuewen Liao, Member, IEEE, and Shuguang Cui, Fellow, IEEE

Abstract—Energy harvesting (EH) is a promising technique tofulfill the long-term and self-sustainable operations for Internetof things (IoT) systems. In this paper, we study the joint accesscontrol and battery prediction problems in a small-cell IoT sys-tem including multiple EH user equipments (UEs) and one basestation (BS) with limited uplink access channels. Each UE hasa rechargeable battery with finite capacity. The system controlis modeled as a Markov decision process without complete priorknowledge assumed at the BS, which also deals with large sizesin both state and action spaces. First, to handle the access controlproblem assuming causal battery and channel state information,we propose a scheduling algorithm that maximizes the uplinktransmission sum rate based on reinforcement learning (RL) withdeep Q-network (DQN) enhancement. Second, for the batteryprediction problem, with a fixed round-robin access control policyadopted, we develop a RL based algorithm to minimize theprediction loss (error) without any model knowledge about theenergy source and energy arrival process. Finally, the joint accesscontrol and battery prediction problem is investigated, where wepropose a two-layer RL network to simultaneously deal withmaximizing the sum rate and minimizing the prediction loss: thefirst layer is for battery prediction, the second layer generates theaccess policy based on the output from the first layer. Experimentresults show that the three proposed RL algorithms can achievebetter performances compared with existing benchmarks.

Index Terms—Internet of things, energy harvesting, reinforce-ment learning, access control , battery prediction.

I. INTRODUCTION

The Internet of things (IoT) has a crucial need for long-termor self-sustainable operations to support various applications[1] [2]. In recent years, energy harvesting (EH) has beenrecognized as an emerging technique that may significantlyincrease the network lifetime and help reduce the greenhousegas emissions in general wireless applications [3] [4] [5].This technology trend provides a promising energy solution

This work was accepted in part at the IEEE GLOBECOM, AbuDhabi, UAE, 2018. The work was supported in part by grant NSFC-61629101, by NSF with grants DMS-1622433, AST-1547436, ECCS-1659025, and by Shenzhen Fundamental Research Fund under Grants No.KQTD2015033114415450 and No. ZDSYS201707251409055.

M. Chu and X. Liao are with the Department of Information and Communi-cation Engineering, Xi’an Jiaotong University, Xi’an, 710049, China (e-mail:cmcc [email protected], [email protected]).

H. Li is with the Shenzhen Research Institute of Big Data, Shenzhen, China(e-mail: [email protected]).

S. Cui is with the Shenzhen Research Institute of Big Data and Schoolof Science and Engineering, the Chinese University of Hong Kong, Shen-zhen, China. He is also affiliated with Department of Electrical and Com-puter Engineering, University of California, Davis, CA, 95616. (Email:[email protected]).

Corresponding author: S. Cui.

for IoT applications [6] [7]. Accordingly, EH has been beingintensively discussed for supporting the future IoT systems,in D2D communications, wireless sensor networks, and fu-ture cellular networks [8] [9]. Fundamentally, the amount ofharvested energy may be unpredictable due to the stochasticnature of energy sources, i.e., energy arrives at random timesand in arbitrary amounts, which poses great challenges toresearchers [5] [10]. It can be expected that how to handlethe dynamics of the harvested energy would be a key designissue in EH based wireless communication systems.

A. Related Works and Motivations

In general, the related research works on EH based systemscould be categorized into two classes based on the availabil-ity of the knowledge about energy arrivals. The first classcomprises offline approaches that require complete non-causalknowledge of the considered stochastic system, which areusually adopted to derive the performance upper bounds [11][12] [13]. In particular, the optimal uplink resource allocationwas investigated in [12] for the scenario where two EH usersfirst harvested energy from the wireless signals and thencooperatively sent information to the access point. Also, theoptimal packet scheduling over multiple access channels wasstudied in [13], with the goal of minimizing the time by whichall packets from both users are delivered to the destination.

The second class comprises online approaches [14] [15][16]. Authors in [14] studied a multi-access wireless systemwith EH transmitters, and the access problem was modeledas a partially observable Markov decision process (POMDP).In [15], the optimal power control policies for EH nodes ina multi-access system was considered, where a dam modelwas constructed to capture the dynamics of the EH process.In these approaches, some statistic knowledge regarding thedynamic system should be known at the transmitters [16]. Inmany practical applications, the complete non-casual knowl-edge or even statistical knowledge of the system dynamics(including both the channel and energy parts) might not beavailable, especially when the EH processes are non-stationaryor from sources with unknown distributions. For example, ina wireless network with solar EH nodes distributed randomlyover a geographical area, the characteristics of the harvestedenergy at each node depend on the node location, and changeover time in a non-stationary fashion [17]. In such cases, thepriori knowledge about dynamics of energy sources is verydifficult to obtain.

arX

iv:1

805.

0592

9v2

[ee

ss.S

P] 2

1 Se

p 20

18

Page 2: Reinforcement Learning based Multi-Access Control …1 Reinforcement Learning based Multi-Access Control and Battery Prediction with Energy Harvesting in IoT Systems Man Chu, Hang

2

Given the above issues, learning based model-free ap-proaches become more attractive, where the requirements forthe priori knowledge are widely relaxed or even removed [18].In learning based methods, the learning agent may learncertain statistical information about an unknown environmentsystem by interacting [11]. In related works, the point-to-pointcommunication with an EH transmitter was studied in [19]and [20]. Specifically, a Q-learning based theoretic approachwas introduced in [19], where the transmitter makes a binarydecision, i.e., to transmit or not, in each time slot with theobjective of maximizing the total transmitted data. In [20],the authors studied a transmit power allocation policy tomaximize the throughput using reinforcement learning (RL)with linear function approximation. The RL algorithm state-action-reward-state-action (SARSA) was combined with non-linear function approximation in [20] to enable the use ofincoming energy and channel values, which were taken froma continuous range; thus the authors were able to improve theperformance in an EH point-to-point scenario. Unfortunately,the theoretical performance cannot be guaranteed and thelearning trends are unstable with non-linear function approxi-mation, as shown in [21].

Given the open nature of wireless systems, there is a crucialneed to study the multiuser systems. However, most of theexisting works have not provided any stable and efficient learn-ing based approaches for multiuser access control, especiallywhen the state space and action space of the considered systemare large. Fortunately, the recently proposed deep Q Network(DQN) technique [22] successfully adapted the deep neuralnetwork as a function approximator in Q-learning algorithmsdealing with large state spaces [23]. With DQN, there aretwo major changes to scale Q-learning: the network is trainedwith mini-batch samples from a replay buffer to minimize thecorrelations among samples; a target Q network is given toiteratively update the neural network weights [24].

Wireless access control strategies for EH nodes are usuallyproposed to make the full use of energy and maintain aperpetual lifetime. However, the uncertainty of ambient energyavailability poses new challenge to sustainable perpetual op-erations [25]. Thus, battery level prediction in such EH basedsystems is also worth investigating since a high battery pre-diction accuracy could potentially benefit the communicationperformance. For example, a novel solar energy predictionalgorithm with Q-learning based on the weather-conditionedmoving average (WCMA) algorithm was proposed in [26].Unfortunately, this algorithm is restricted to one type ofenergy sources and suffers from high computation complexity.In [27], an online energy prediction model for multi-sourceEH wireless sensor networks was proposed, which leveragesthe past observations to forecast the future energy availability.Nevertheless, this energy prediction model requires that theEH dynamics should be known in advance. On the other hand,instead of studying the access control and battery predictionproblems separately in EH based IoT applications, it has greatsignificance to design a joint scheme that feeds the energyprediction results to the access control design, which couldlead to better overall system performances. This is the focusof this paper.

B. Our Contributions

To tackle the aforementioned problems, we focus on anuplink wireless system with N EH user equipments (UEs) andone BS, where the BS may only use certain causal informationon system dynamics. We first apply a long short-term memory(LSTM) deep Q-network (DQN) based approach to designthe UE uplink access control. Then, by fixing the accesscontrol policy to be round-robin, we develop a deep LSTMneural network based battery prediction scheme to minimizethe prediction loss. Furthermore, we jointly consider the accesscontrol and battery prediction problem using a proposed two-layer LSTM based neural network with DQN enhancement.The main contributions are summarized as follows:

• We consider an uplink transmission scenario with multi-ple EH UEs and limited access channels, where neithernon-casual knowledge nor statistical knowledge of thesystem dynamics (including both the channel and energyarrival states) is assumed.

• On the condition that only user battery and channelstates of the current time slot are known at the BS, wepropose an LSTM DQN based algorithm as the UE uplinkaccess control scheme with the objective of maximiz-ing the long-term expected total discounted transmissiondata. Other than the traditional access control problemsthat usually consider maximizing the instantaneous sumrate [14], our goal is to achieve a more stable andbalanced transmission for a long time horizon.

• By fixing the access control policy to be round-robin andassuming that the scheduled users embed the informationof their true battery states in the transmission data, wepropose a deep LSTM neural network based battery pre-diction scheme to minimize the prediction loss (definedover the differences between the predicted battery statesand the true battery states within the selected UE set).

• We develop a joint access control and battery predictionsolution by designing a two-layer LSTM DQN network.The first LSTM based neural network layer is designedto generate the predicted battery levels, and the secondlayer uses such predicted values along with the channelinformation to generate the access control policy. Thetwo-layer LSTM based network is trained jointly withthe combined objective of simultaneously maximizing thetotal long-term discounted sum rate and minimizing thediscounted prediction loss of partial users.

• The proposed algorithms are designed with many practi-cal considerations without strong assumptions. In partic-ular, the BS has no prior knowledge on the UEs’ energyarrival distributions. We assume that only the scheduledusers embed the information of their true battery states inthe transmission data, which greatly reduces the systemsignaling overheads.

• Extensive simulations under different scenarios show thatthe proposed three algorithms can achieve much bettereffectiveness and network performance than the variousbaseline approaches.

The rest of this paper is organized as follows. In Section II,we introduce the system model with some basic assumptions,

Page 3: Reinforcement Learning based Multi-Access Control …1 Reinforcement Learning based Multi-Access Control and Battery Prediction with Energy Harvesting in IoT Systems Man Chu, Hang

3

BS…

K channelsPolicy

C 1B 0

C 2B0

0NBC

1E

2E

NE

K Nd

1UE

2UE

NUE

BS…

K channelsC 1B 0

C2B 0

0NBC

1E

2E

NE

K Nd

1UE

2UE

NUE

Fig. 1: System model: N EH users with finite-size batteries and Korthogonal access channels.

and also the preliminaries on deep Q-learning and LSTMnetworks. In Section III, we present the problem formulationfor access control, as well as the LSTM DQN based learningalgorithm. Section IV studies the battery prediction problem.Furthermore, in Section V, we introduce the joint designproblem and its solution. We provide simulation results inSection VI, and finally conclusions in Section VII.

Notations: s and St denote state and the state at time slot t,respectively; a and At denote action and the action at timeslot t, respectively; Rt denotes the reward at time slot t;min{m, n} denotes the minimum operator; Eπ [·] denotes theexpected value given that the agent follows policy π; log(·)denotes the log2(·) operator; |·| denotes the determinant or thecardinality of the set, depending on the context; ‖·‖ denotes thel2-norm; ∇ denotes the first-order derivative operator; RM×Ndenotes the space of real M ×N matrixes.

II. SYSTEM MODEL AND PRELIMINARIES

A. System Model

We consider an uplink wireless system with N EH basedUEs and one BS, as depicted in Fig. 1. The system operates ina time-slotted fashion with equal-length time slots (TSs), witha normalized slot length equal to one. The BS is able to pickK out of the N UEs to perform uplink access (K can alsobe viewed as the number of available orthogonal channels).The set of all the UEs and the selected subset of UEs at TS tare denoted by N and Kt, respectively, where |Kt| = K. Wedenote the channel power gain between UE i and the BS atTS t by Hit and let Ht = {H1t, · · · , HNt} be the set of allthe channel gains at TS t. We assume that at the beginning ofeach TS, the instantaneous channel state information (channelpower gain) can be obtained at BS. Besides, the channelstates remain constant during each TS and may change acrossdifferent TSs [11]. We assume that the UEs always have datafor uplink transmission in each TS. The location of the BSis fixed, while the UEs follow random walks across differentTSs and their locations remain unchanged during one TS.

We assume that all the UEs have no other power sourcesand they only use the harvested energy, which is collected

from the surrounding environment via some renewable energysources (i.e., wind power, solar power or hydropower). Manyenergy arrival processes based on such sources are shown tobe Markov processes [26] [27] [28], but this is not strictlyrequired in our paper. All the battery states are quantizedfor analysis convenience [14]. We assume that the batterycapacity is C, same for all the UEs. We use Eit ∈ R andBit ∈ {0, · · · , C} to denote the amount of harvested energyand the state of battery for UE i at the beginning of TSt, respectively. Let Bt = {B1t, · · · , BNt} denotes the setof all the UEs’ current battery states. We assume that thetransmission power for each selected UE is fixed to be P [14][19]. After Eit is harvested at TS t, it is stored in the batteryand is available for transmission in TS t+1. The rechargeablebattery is assumed to be ideal, which means that no energyis lost with energy storing or retrieving and the transmissionof data is the only source of UE energy consumption. Oncethe battery is full, the additional harvested energy will beabandoned. We assume that the power required to activate theUE EH circuit is negligible compared with the power used forsignal transmission [5] [29] [30], since the processing powerfor EH circuit activation is usually very small compared withthe transmit power in practice. For example, as shown in [31],the power consumption for transmission is about 23 times thepower consumption for activating the EH circuit.

We use a binary indicator Iit ∈ {0, 1} to describe the accesscontrol policy: If UE i is scheduled to access the channel atTS t (i.e., i ∈ Kt), Iit = 1; otherwise, Iit = 0. We useanother indicator zit ∈ {0, 1} to denote the transmission statussuch that: When P ≤ Bit, zit = 1, which means that thetransmission could be done successfully; otherwise, zit = 0,which means that at TS t, UE i cannot transmit data to theBS and the current transmission is failed. Based on the abovenotations, the battery evolution of UE i ∈ N over differenttime slots could be described as:

zitIitP ≤ Bit, (1)Bi(t+1) = min{C,Bit + Eit − zitIitP}. (2)

B. Preliminaries: Deep Q-Learning and LSTM

In this subsection, we briefly introduce the RL networkthat is used in this paper to solve the access control andbattery prediction problems. The detailed physical meaningsof the notations in the RL network will be introduced later.RL is developed over the Markov decision process (MDP)formulation, which includes: a discrete state space S, an actionspace A, an immediate reward function r : S ×A → R and atransition probability set P where p(s′, r|s, a) ∈ P satisfies theMarkov property p(s′, r|s, a) = Pr{St+1 = s′, Rt = r|St =s,At = a}, where St, At and Rt denote the state, action andreward at TS t, respectively.

Note that our paper studies a multiuser uplink scenario.When we use MDP to model such a system, the number ofsystem states is large since the state contains the channel gainand battery level for every UE, and the size of correspondingaction space is also large as it is proportional to the numberof UEs.

Page 4: Reinforcement Learning based Multi-Access Control …1 Reinforcement Learning based Multi-Access Control and Battery Prediction with Energy Harvesting in IoT Systems Man Chu, Hang

4

Based on the MDP formulation, the general goal of anRL agent is to find a good policy, which is a functionmapping from state space to the action space, denoted byπ : S → A. In this paper, the RL agent is the BS, whosegoal is to maximize/minimize the reward/loss in the long runby following the optimal policy. The total discounted rewardfrom TS t onwards can be written as:

Rγt =

∞∑k=t

γk−tRk+1, (3)

where γ ∈ (0, 1) is the discount factor.For a typical RL network, the state value function and action

value function are instrumental in solving the MDP, which aredefined as

Vπ(s) = Eπ[Rγt |St = s] = Eπ

[ ∞∑k=t

γk−tRk+1|St = s

], (4)

Qπ(s, a) =Eπ[Rγt |St = s,At = a]

=Eπ

[ ∞∑k=t

γk−tRk+1|St = s,At = a

], (5)

where Eπ [·] denotes the expected value given that the agentfollows policy π [32].

The optimal policy π∗ is the policy that can maximize(4) at any state, and we can observe from (4) and (5) thatVπ∗(s) = maxa′∈AQπ∗(s, a′). The corresponding action-value function for the optimal policy π∗ is denoted byQπ∗(s, a). A fundamental property of the value functions isthat the functions can be evaluated in a recursive manner byusing the Bellman equations. The general form of the Bellmanoptimality equation for the action value function is given as

Qπ∗(s, a) = E[Rt+1 + γmax

a′Qπ∗(St+1, a)|St = s,At = a

]=∑s′

p(s′, r|s, a)[r(s, a, s′) + γmax

a′Qπ∗(s

′, a′)],

(6)

where r(s, a, s′) = E [Rt+1|St = s,At = a, St+1 = s′] is theexpected value of the next reward given the current state s andaction a, together with the next state s′ [32].

In a system with large state and action spaces, it is oftenimpractical to maintain all the Q-values, i.e., all the functionvalues in (5) for all possible state-action pairs. Generally,nonlinear function approximation for learning Qπ(s, a) (Q-learning) is a popular approach [20]. However, it usuallycannot provide theoretical guarantees, producing unstable tra-jectories in many practical applications. Fortunately, the re-cently proposed DQN [22] successfully adapts the deep neuralnetwork as a function approximator in Q-learning over largestate spaces. In our work, we adopt the DQN to approximatethe action value function for all state action pairs.

In particular, we build the DQN based on Long Short-Term Memory (LSTM), which is a special recurrent neuralnetwork that can connect and recognize long-range correlatedpatterns over the input and output states. Specifically, anLSTM network is considered as multiple copies of the memory

Input of TS

Cell state from

previous TS

Cell state of

t

tanh

u

u

u

Hidden state from

previous TS

Output oft

t

Hidden state oft

Forget gate V Input

gate V Cell gate

VOutput gate

tanh

u

Fig. 2: LSTM unit.

blocks (LSTM units), each of which passes a message to itssuccessor as shown in Fig. 2. Such an LSTM unit has fourgates to control the flow of information. With the input fromthe current step t and the hidden state of the previous stept− 1, the unit firstly decides what information to throw awaythrough multiplying the forget gate output by the cell statefrom t − 1. The cell state runs straight down all the unitsin the LSTM network. The next procedure is to decide whatnew information is going to be stored in the cell state usingthe input gate and cell gate. Finally, the hidden state is updatedwith the new cell state and the output of the output gate.

C. Performance Metric

In this paper, we adopt two main metrics to measure theoverall performance of the network. The first is the sum rateof all the uplink transmissions to the BS. At time slot t, thenetwork uplink sum rate at the BS is given by

Rt =∑i∈Kt

zitF log

(1 +

PHit

σ2

), (7)

where F is the spectrum bandwidth and σ2 is the noisepower [33].

The second metric is the prediction loss, which is thedissimilarity between the predicted battery states and the truebattery states. It is worth mentioning that in our batteryprediction design, the BS does not know the full information ofBt (i.e., the battery states at each TS) for decision making. Inorder to avoid large signaling overheads for reporting batterystates to the BS at each TS, only the selected UEs send theirtrue battery states along with transmitted data to the BS. Thus,the instantaneous prediction loss only involves the selectedUE set. However, as the RL algorithm explores all the UEs,all the UEs will be taken into account in the long run. Theinstantaneous prediction loss Ploss(t) at time slot t is givenby

Ploss(t) =

√∑i∈Kt

|Bit − bit|2, (8)

where bit and Bit are the predicted battery state and truebattery state of UE i at time slot t, respectively.

Page 5: Reinforcement Learning based Multi-Access Control …1 Reinforcement Learning based Multi-Access Control and Battery Prediction with Energy Harvesting in IoT Systems Man Chu, Hang

5

III. ACCESS CONTROL WITH RL

In this section, we consider the access control problemdescribed in Fig. 1. It is assumed that the BS and UEs arecooperative such that the BS may obtain the knowledge ofcurrent channel gains and UEs’ current battery states [11].The system operates as follows. When the system enters anew time slot, the BS uses the current UE battery states andchannel information to compute its scheduling policy for thecurrent TS with a RL network, and then broadcasts the policyto all the UEs. Afterwards, the selected UEs transmit theirdata to the BS with transmission power P , while those whoare not selected remain idle. All the UEs execute the energyconversion process and store the energy into the battery forthe future use. The above process repeats in the next TS.

A. Problem Formulation

The BS needs to find a good access control policy withthe objective of maximizing the long-term expected uplinksum rate. In TS t, the system state St contains two parts: thecurrent channel state information Ht = {H1t, · · · , HNt} andthe current UE battery state Bt = {B1t, · · · , BNt}. That is,we have St = {Ht,Bt}. The action space A contains all thepossible UE selection choices, i.e., Kt ∈ A, with |Kt| = K,∑Ni=1 Iit = K. Here, the reward signal Rt is the received sum

rate at the BS, which is regarded as the reward at state St bytaking action At. The description of Rt is shown in (7) andthe total discounted sum rate (reward) can be calculated as

Rγt =

∞∑k=t

γk−tRk+1

=

∞∑k=t

γk−t∑

i∈Kk+1

zi(k+1)F log

(1 +

PHi(k+1)

σ2

). (9)

Our learning goal is to maximize the expected cumulativediscounted reward by following the access policy π from astarting state, which is given by

J1(π) = E(Rγt | π). (10)

As such, the access control optimization problem can beformulated as

maxπ

J1(π) (11a)

s.t. (1) and (2) (11b)N∑i=1

Iit = K. (11c)

B. LSTM-DQN based Access Control Network

In this subsection, we present the proposed learning frame-work and algorithm of uplink access control to solve prob-lem (11). In Fig. 3, we illustrate the architecture of our LSTM-DQN network for access control. The centralized controllerat the BS receives the state information s at the beginningof each TS. With the input s, the entire layer of the LSTMnetwork outputs the approximated Q-value in mini-batchQminibatch(s, a) ∈ Rbatchsize×L, where L is the size of the

LSTM unit

LSTM unit

LSTM unit

LSTM network layer

…w1 w2

Fully connected network layer

φA(θθθa)

wt

wf

θθθa = {w1,w2, . . . ,wn,wf}St

Q(St, a)

Qminibatch(St, a)

Fig. 3: LSTM based access control network φA(θa).

action space and a ∈ A. Then, we use a fully connectednetwork layer to adjust the size of the Q-value vector to makeit fit the action space, i.e., Q(s, a) ∈ R1×L. We use φA(θa)to represent our neural network in Fig. 3 with the input as thesystem state s and the output as Q(s, a). Here, θa denotesthe set of network weights which contains: the LSTM layerparameters {w1, · · · ,wn} and the fully connected networklayer parameters wf , where n is the number of LSTM units.

In the learning time slot t, Q(St, a) is estimated by φA(θa).We recall that given St, with Q(St, a) at hand the BS selectsAt that achieves the maximum Q(St, At), and the optimalpolicy is the greedy policy if Q(St, a) can be perfectlyestimated. However, the greedy policy is not optimal beforethe estimate ofQ(s, a) is accurate enough. In order to improvesuch estimates, the BS should balance the exploration ofnew actions and the exploitation of the known actions. Inexploitation, the BS follows the greedy policy; in explorationthe BS takes actions randomly with the aim of discoveringbetter policies. The balance could be realized by the ε-greedyaction selection method [34] (as given later in Algorithm 1) ateach time slot, which either takes actions randomly to explorewith probability ε or follows the greedy policy to exploit withprobability 1− ε, where 0 < ε < 1.

After executing the selected action At, the BS receives thereward Rt and the system changes to the new state. We utilizeexperience replay to store the BS’s experiences at each TS,which is denoted by tuple et = (St, At, Rt, St+1) in a data-set D = {e1, ..., et}. The replay memory size is set to beL, which means their we could store L experience tuples.Here, et is generated by the control policy π(a|s). In eachTS, instead of updating θa based on transitions from thecurrent state, we randomly sample a tuple (s, a, r, s) fromD. Updating network parameters in this way to avoid issuescaused by strong correlations among transitions of the sameepisode [22]. We parameterize an approximate value functionQ(s, a;θa) using the proposed learning network in Fig. 3with network parameters (weights) of θa. With the sampledtransitions, yt = r+ γmaxaQ(s, a;θ−a ) is the target Q-valuewith network weights θ−a obtained from previous iteration.

Page 6: Reinforcement Learning based Multi-Access Control …1 Reinforcement Learning based Multi-Access Control and Battery Prediction with Energy Harvesting in IoT Systems Man Chu, Hang

6

Accordingly, we have the following loss function to minimize:

Lt(θa) = (yt −Q(s, a;θa))2. (12)

Differentiating the loss function with respect to the weights,we arrive the following gradient:

∇θaLt(θa) =(

r + γmaxa

Q(s, a;θ−a )−Q(s, a;θa)

)∇θa

Q(s, a;θa),

(13)

where∇θaf(·) denotes the gradient vector of f with respect to

θa. By adopting the routine of stochastic gradient descent [22],the overall access control algorithm is summarized in Algo-rithm 1.

Algorithm 1 LSTM-DQN based Access Control Algorithm

1: Initialize the experience memory D,2: Initialize the parameters of action generator network φA

with random weights θa,3: Initialize the total number of episodes Ep,4: Initialize the environment and get initial observation S1,5: for t = 1, · · · ,∞ do6: if random() ≤ ε then7: Select a random action At ∈ A;8: else9: Compute Q(St, a) for all actions a ∈ A using φA,

10: Select At = argmaxa∈A

Q(St, a).

11: end if12: Execute At, observe reward Rt and new state St+1,13: Store transition (St, At, Rt, St+1) in D,14: Sample random mini-batch of transitions (s, a, r, s)

from D,15: Set yt = r if t + 1 is the terminal step of the episode

(t+ 1 = Ep); otherwise, yt = r + γmaxaQ(s, a;θ−a ),

16: Perform stochastic gradient descent step on the lossfunction Lt(θa) = (yt − Q(s, a;θa))

2 to update net-work parameters θa according to (13).

17: end for

IV. BATTERY PREDICTION WITH RL

In wireless EH network, it is important to keep energy-neutral, i.e., energy expenditure equals the harvested amountand operation permanently. An effective energy-neutral policymay benefit from an accurate prediction for the future har-vested energy. In this section, we consider reusing a similarLSTM method to the one used in the previous section for UEbattery state prediction. In our design, we do not need to knowthe UE energy model, as the method is purely data driven.

A. Problem Formulation

For the EH system in Fig. 1, we assume that the accesscontrol policy is fixed to be the widely used round-robinscheduling policy [14]. At the beginning of each TS t, theLSTM based predictor can output the predicted battery states

bit, i ∈ N . The BS then schedules the UE transmission basedon round-robin scheduling and broadcasts the schedule toall the UEs. After receiving the schedule, the selected UEstransmit data to the BS, along with their current ground-truthbattery states Bit, i ∈ Kt [14]. We use the difference betweenthe predicted battery states and the true battery states withinthe selected UE set as the performance metric for the designedpredictor, as shown in (8).

A memory component with a history window of W isequipped at the BS to store limited history information. At TSt, the state space contains three parts: the access schedulinghistory information Xt = {Iij} ∈ RN×W , where i ∈ Nand j ∈ [t −W + 1, t]; the history of predicted UE batteryinformation Mt = {bij} ∈ RN×W , where i ∈ N andj ∈ [t − W + 1, t]; and the history of selected UE truebattery information Gt = {Bij} ∈ RK×W , where i ∈ Kjand j ∈ [t−W + 1, t].

We use St = {Xt, Mt,Gt} to denote the system state, andbt = [b1t, · · · , bNt] to denote the battery prediction result,which is also called the prediction value v(St) = bt. Wedenote the predicted battery states of selected UEs as vectorvs(St) with elements {bit}i∈Kt

and the received true batterystates of selected UEs as vector Rt with elements {Bit}i∈Kt

.Thus, the prediction loss in (8) is equivalent to

Ploss(t) =√||Rt − vs(St)||2. (14)

The long-term prediction performance, i.e., the total dis-counted prediction loss, is given by

P γloss(t) =

∞∑k=t

γk−t√||Rk+1 − vs(Sk+1)||2. (15)

The goal of the learning algorithm is to obtain the optimalprediction policy π to minimize the cumulative discountedloss, which is given by

J2(π) = E(P γloss(t) | π). (16)

The battery prediction problem can be formulated as

minπ

J2(π) (17a)

s.t. (1) and (2). (17b)

B. Deep LSTM based Battery Prediction Network

In Fig. 4, we illustrate the architecture of our LSTMbased prediction network, which is denoted as the predictiongenerator. At the beginning of TS t, the BS first observes Stand imports it into the LSTM network layer, and the LSTMnetwork outputs the predicted battery states in multi mini-batch bminibatch ∈ Rbatchsize×N . Then we use a fully connectednetwork layer to adjust the size of the LSTM output vector asbt ∈ R1×N . The BS then announces the access policy basedon round-robin. After UEs’ transmissions, the BS receives thetrue battery states Rt. We use φB(θb) to denote the predictiongenerator with the input St = {Xt, Mt,Gt} and the outputv(St) = [b1t, · · · , bNt]. Here, θb is the set of network weights,which contains the LSTM layer parameters {w1, . . . ,wn}and the fully connected layer parameters wf , where n is thenumber of LSTM units.

Page 7: Reinforcement Learning based Multi-Access Control …1 Reinforcement Learning based Multi-Access Control and Battery Prediction with Energy Harvesting in IoT Systems Man Chu, Hang

7

LSTM unit

LSTM unit

LSTM unit

LSTM network layer

…w1 w2

Fully connected network layer

φB(θθθb)

bminibatch

v(St) = bt = [b1t, b2t, · · · , bNt]

wt

wf

θθθb = {w1,w2, . . . ,wn,wf}St

Fig. 4: LSTM based battery prediction network φB(θb).

A good policy in this case is the one minimizing thecumulative discounted prediction loss based on the observedstates. We utilize experience replay D (defined in previousSection) to store the BS experiences (St, v(St),Rt, St+1). Ineach TS, we randomly sample a tuple (Sj , v(Sj),Rj , Sj+1)from D to update the network parameters θb. Stochasticgradient descent is used to minimize the prediction loss byadjusting the network weight parameter θb after each sample inthe direction that would reduce the loss the most. The weightsare updated as

θb(j + 1)

= θb(j)−1

2α∇θb(j) [Vj − v (Sj ,θb(j))]

2

= θb(j) + α [Vj − v (Sj ,θb(j))]∇θb(j)v (Sj ,θb(j)), (18)

where α is a positive step size, v (Sj ,θb(j)) is the parame-terized prediction values with the network parameters θb(j),and ∇θb(j)f(·) denotes the gradient vector of f with respectto θb(j), and Vj is the target output of the jth trainingstep. We adopt the temporal-difference (TD) policy evaluationalgorithm [32], i.e., TD(0), where the TD error is describedas

δj = Rj+1 + γvs(Sj+1,θb(j))− vs(Sj ,θb(j)). (19)

The updating in (18) can be executed as θb(j + 1) =θb(j) + αδj∇θb(j)v(Sj ,θb(j)). The battery prediction algo-rithm based on the deep LSTM network is summarized inAlgorithm 2.

V. JOINTLY ACCESS CONTROL AND BATTERY PREDICTIONBASED ON RL

By jointly considering the access control and battery predic-tion, we could relax the requirements of the knowledge on theUE battery states of the current TS for access control, whichmeans that only current channel gains are needed at the BS ateach TS.

In particular, we propose a two-layer LSTM based DQNcontrol network, which is applied at the BS and operates as

Algorithm 2 Deep LSTM based Battery Prediction Algorithm

1: Initialize the experience memory D,2: Initialize the parameters of prediction generator networkφB with random weights θb,

3: Initialize the environment and get initial state S1,4: Initialize the total number of episodes Ep,5: for t = 1, · · · , Ep do6: Get prediction output v(St) = bt given by current

φB(θb(t)),7: Take bt as the input of BS access control center,8: BS schedules the UEs according to the round-robin

policy,9: BS broadcasts the access policy to all the UEs, the se-

lected UEs whose current battery states satisfy P ≤ Bitcould complete the transmissions and the others couldnot transmit,

10: The BS observes Rt and the new state St+1,11: Store transition (St, v(St),Rt, St+1) in D,12: Sample random mini-batch of transitions

(Sj , v(Sj),Rj , Sj+1) from D,13: Calculate the TD error

δj = Rj+1 + γvs(Sj+1,θb(j))− vs(Sj ,θb(j)),14: Perform stochastic gradient descent to update network

parameters θb based onθb(j + 1) = θb(j) + αδj∇θb(j)v(Sj ,θb(j)).

15: end for

follows. At the beginning of each TS t, the first LSTM basednetwork layer, which is used for battery prediction, outputsall the UEs’ predicted battery states based on the historyinformation. The predicted battery states are then input tothe second layer, which is designed to generate the accesscontrol policy. Next, with the output of the second layer, i.e.,the access control policy, the BS broadcasts the schedule toall the UEs. Afterwards, the selected UEs execute the policyand transmit their data to the BS, along with their current truebattery states Bit, i ∈ Kt, which will be stored into the historyinformation for future prediction usage; those UEs who are notselected remain idle. The BS finally receives rewards, i.e., themixture of the sum rate and the prediction loss. All the UEscomplete the energy conversion and store the energy to thebattery for future use. The above process repeats in the nextTS.

A. Problem Formulation

The BS operates as the centralized controller that predictsthe UE battery states and schedules the subset of users K ∈ Nto access the uplink channels at each TS. At TS t, the wholesystem state is denoted as St. We deploy a memory componentwith a window of W at the BS to store the history data, whichcontains: the access scheduling history information, i.e., accessindicators, Xt = {Iij} ∈ RN×W , where i ∈ N and j ∈[t−W +1, t]; the history of predicted UE battery informationMt = {bij} ∈ RN×W , where i ∈ N and j ∈ [t − W +1, t]; and the history of the true battery information within theselected UE sets Gt = {Bij} ∈ RK×W , where i ∈ Kj and

Page 8: Reinforcement Learning based Multi-Access Control …1 Reinforcement Learning based Multi-Access Control and Battery Prediction with Energy Harvesting in IoT Systems Man Chu, Hang

8

j ∈ [t−W +1, t]. The channel gain at TS t is Ht. Thus, wehave St = {Xt,Mt,Gt,Ht}. Given St and the schedulingpolicy π, the action At = π(St) is derived with the DQNcontrol network given in Fig. 5.

Since the performance of the joint solution relies on boththe access control policy and battery prediction results, theimmediate reward contains the received sum rate Rt in (7) andthe battery prediction loss Ploss(t) in (8), which is regardedas the penalty to the sum rate. The immediate reward receivedat TS t of state St by taking action At in the joint solution isset as

Rt = Rt − βPloss(t)

=∑i∈Kt

zitF log

(1 +

PHit

σ2

)− β

√∑i∈Kt

|Bit − bit|2,

(20)

where β denotes the penalty factor for balancing two differentphysical quantities. The long-term system performance, i.e.,total discounted reward, from TS t onwards, is given by

Rγt =

∞∑k=t

γk−tRk+1

=

∞∑k=t

γk−t

∑i∈Kk+1

zi(k+1)F log

(1 +

PHi(k+1)

σ2

)

−β√ ∑i∈Kk+1

|Bi(k+1) − bi(k+1)|2 . (21)

The objective of our joint learning algorithm is to obtainthe optimal scheduling policy π to maximize the cumulativediscounted reward is given by

J3(π) = E(Rγt | π). (22)

The joint problem can then be formulated as

maxπ

J3(π) (23a)

s.t. (1) and (2) (23b)N∑i=1

Iit = K. (23c)

B. Two-Layer LSTM-DQN based Joint Network

In this subsection, we present the proposed learning RLnetwork and the algorithm to solve problem in (23), whereFig. 5 shows the architecture of the proposed new hybridcontrol network combining the LSTM neural network anddeep Q-learning enhancement.

The network in Fig. 5 can be divided into two layers.The first is the LSTM layer based network to perform thebattery prediction, which is called the prediction generator.In a practical scenario with unknown energy sources, theBS has no information about the UE EH processes andbattery states. At the beginning of TS t, the input of theprediction generator is the history knowledge within certaintime window, which contains: Xt, Mt and Gt. We denotethe input as S1

t = {Xt, Mt,Gt}. With S1t , the first LSTM

Second LSTM layer

First LSTM layer

Fully connected layer

Fully connected layer

Processing unit

Second LSTM layer

First LSTM layer

Fully connected layer

Fully connected layer

Processing unit

UEs

… …

Time line

Broadcast access control policy to UEs

Q(St−1, a) Q(St, a)

Qminibatch(St−1, a) Qminibatch(St, a)

w2f w2

f

{w21, · · · ,w2

n } {w21, · · · ,w2

n }

{w11, · · · ,w1

n } {w11, · · · ,w1

n }

w1f w1

f

φA(θθθa)

bminibatch bminibatchφB(θθθb) Ht−1 Ht

St−1 = {S1t−1,Ht−1} St = {S1

t ,Ht}

S1t−1 S1

t

Fig. 5: Two-Layer LSTM-DQN based control network.

network outputs the predicted battery states in multi mini-batch bminibatch ∈ Rbatchsize×N . Then a fully connected net-work follows to adjust the size of the LSTM output vectorto be the expected bt ∈ R1×N . We use φB(θb) to denotethe prediction generator with the input S1

t and the outputbt = {b1t, · · · , bNt}. Here, the set of network weights θbcontains the LSTM network parameters {w1

1, . . . ,w1n} and

the fully connected network parameters w1f , where n is the

number of LSTM units.The second layer is the action generator for producing the

access control policy, which contains an LSTM layer and afully connected layer. At TS t, the input of the action generatorcontains: the output values of φB , i.e., bt = φB(S

1t ); and the

current channel states Ht. We denote the input of the actiongenerator as S2

t = {bt,Ht}. With S2t , the LSTM layer outputs

the approximated Q-value in mini-batch Qminibatch(S2t , a) ∈

Rbatchsize×L, where L is the size of the action space witha ∈ A. Then, the fully connected network layer adjusts thesize of the Q-value vector to Q(S2

t , a) ∈ R1×L. Finally, theaction generator outputs the approximated Q-value Q(S2

t , a).We represent the action generator as φA(θa) with the inputS2t and the output Q(S2

t , a) ∈ R1×L. Here, θa is the setof network weights containing the LSTM layer parameters{w2

1, · · · ,w2n} and the fully connected layer parameters w2

f .Therefore, by combining the prediction generator and ac-

tion generator, the proposed two-layer LSTM-DQN basedjoint network can be represented as φA(φB(Xt,Mt,Gt),Ht)with the entire input as St = {Xt,Mt,Gt,Ht} andthe output approximation of Q-value as Q(St, a) =Q ({φB(Xt,Mt,Gt),Ht}, a).

In the proposed RL network, we learn the parameters θb ofthe prediction generator and θa of the action generator jointly.

Page 9: Reinforcement Learning based Multi-Access Control …1 Reinforcement Learning based Multi-Access Control and Battery Prediction with Energy Harvesting in IoT Systems Man Chu, Hang

9

The parameters of the two-layer joint network is denoted byθ = {θa,θb}. At the beginning of TS t, the BS receivesSt. The prediction generator φB firstly outputs bt, and theBS then stores bt by updating its history memory. With thepredicted battery states and channel gains, the action generatorthen outputs the Q-value Q(St, a). As explained in SectionIII, the balance between the exploration of new actions andthe exploitation of the known actions is realized by the ε-greedy action selection method [34]. With ε-greedy, the BSeither takes actions randomly with probability ε or follows thegreedy policy (chosing the action At by maxAt∈AQ(St, At))with probability 1− ε, where 0 < ε < 1.

After executing the selected action At, the BS receives theimmediate reward Rt. We keep tracking the BS’s previousexperience in a replay memory data set D = {e1, · · · , et},with et = (St, At, Rt, St+1). Instead of performing updatesto the Q-values using transitions from the current episode, wesample a random transition (s, a, r, s) from D [22]. Followingthe Q-learning approach, we obtain the target Q-value yt = r+γmaxaQ(s, a;θ−), where Q(s, a;θ−) is the parameterizedapproximate value function with network parameters θ− ={θ−a ,θ−b } obtained from the previous iteration.

We can get the following loss function Lt(θ) to minimize:

Lt(θ) =(yt −Q(s, a;θ))2

=

(r + γmax

aQ(s, a;θ−)−Q(s, a;θ)

)2

. (24)

The updates on θ can be performed using the stochasticgradient of ∇θLt(θ). It is worth mentioning that, in thisgradient, θ contains both two-layer network parameters, i.e.,θ = [θa,θb], which means that the prediction generator andaccess control policy network are trained in a joint way [35][36]. The overall joint access control and battery predictionalgorithm is summarized in Algorithm 3.

VI. SIMULATION RESULTS

In this section, we demonstrate the performance of the twoproposed RL based algorithms by simulations. All the resultsare performed in a simulated LTE uplink scenario with oneBS and 30 randomly walking UEs with the speed of 1m/s.The UEs’ energy arrival processes are modeled as Possionarrival processes with different arrival rates. The cell range is500m×500m with pathloss = 128.1+37.6 log(d), where d isthe transmission distance [37]. The system total bandwidth isF = 5MHz and the penalty factor β is 102. All the batterystates are quantized into integer units with 5dBm per unit andthe transmit power is at 2 units.

The LSTM network consists of 128 units and the fullyconnected layer uses a tanh activation function. The learningrate α is fixed as 10−4 and the discount factor γ is set to be0.99. We train the deep RL network with a mini-batch size of16 and a replay buffer size of 105. All simulation results areobtained based on the deep learning framework in TensorFlow1.2.1.

To compare the performance of our proposed algorithms,we consider the following alternative approaches: 1) an offlinebenchmark provides an upper bound where the BS is assumed

Algorithm 3 Algorithm for Joint Problem (23)

1: Initialize the experience memory D,2: Initialize the parameters of prediction generator networkφB with random weights θb,

3: Initialize the parameters of action generator network φAwith random weights θa,

4: Initialize the total number of episodes Ep,5: for eposode = 1, · · · , Ep do6: Initialize the environment and get initial observation

state S1 = {S1t ,H1}, S1

t = {X1,M1,G1},7: for t = 1, · · · , T do8: Get the predicted battery states bt = φB(S

1t ),

9: Get the input state S2t = {φB(S1

t ),Ht} for φA,10: if random() ≤ ε then11: Select a random action At ∈ A;12: else13: Compute Q(St, a) for all actions using φA,14: Select At = argmax

a∈AQ(St, a;θ).

15: end if16: Execute At, observe reward Rt,17: Get new state St+1 = {S1

t+1,Ht+1},18: Store transition (St, At, Rt, St+1) in D,19: Sample random mini-batch of transitions (s, a, r, s)

from D,20: Set yt = r if t+1 is the terminal step of the episode

(t+1 = Ep); otherwise, yt = r+γmaxaQ(s, a;θ−a ),

21: Perform the stochastic gradient descent step on theloss function Lt(θa) = (yt−Q(s, a;θa))

2 to updatethe network parameters θ.

22: end for23: end for

to have perfect non-causal knowledge on all the randomprocesses; 2) a myopic policy (MP), which is a widely useddata-driven approach in the multi-armed bandit model [14];3) the round-robin scheduling; and 4) random scheduling. Itis worth mentioning that the presented rewards are averagedby taking the mean over a fixed moving reward subset with awindow of 200 training steps to achieve smoother and moregeneral performance comparison.

Firstly, we investigate the performance of Algorithm 1 com-pared with other methods. As shown in Fig. 6, the proposedlearning algorithm always achieves a higher average rewardthan round-robin and random scheduling. This is intuitivesince round-robin only considers the access fairness among allthe UEs, and random selection makes the decision even moreblindly. With the increase of training steps, the proposed DQNscheme at first stays in an unstable exploration stage. Then,it gradually outperforms MP after 1.8 × 104 training steps.Finally, it converges and becomes stable. This is because thatMP always focus on the current sum rate optimization basedon the battery beliefs [14], while the DQN algorithm takes thelong-term performance into consideration, resulting in a moreefficient resource utilization and higher sum rate. Furthermore,we observe that the performance gap between our proposed

Page 10: Reinforcement Learning based Multi-Access Control …1 Reinforcement Learning based Multi-Access Control and Battery Prediction with Energy Harvesting in IoT Systems Man Chu, Hang

10

0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5Training steps 104

3

3.5

4

4.5

5

5.5

6

6.5

7

7.5

8Av

erag

e re

ward

s (k

bps)

OfflineDQNMyopic PolicyRound-Robin SchedulingRandom Scheduling

Fig. 6: Average reward vs. training steps.

2 4 6 8 10 12 14 16 18 20The number of available channels

2

4

6

8

10

12

14

Aver

age

rewa

rds

(kbp

s)

OfflineDQNMyopic PolicyRound-Robin SchedulingRandom Scheduling

C=10

C=5

Fig. 7: Average reward vs. battery capacity and available channels.

algorithm and the offline upper bound gets smaller as thetraining step increases. We also compare the average sumrates under different numbers of available channels and batterycapacities. We can also see from Fig. 6 that after getting stable,the average reward of the proposed DQN based algorithmachieves a value that is 11.93% higher than that with theMP approach, 19.47% higher than the round-robin approach,and 26.05% higher than the random scheduling approach.Meanwhile, the average reward of the proposed DQN basedapproach is 3.3% lower than the upper bound (i.e., the offlinescheduling). It can be seen in Fig. 7 that the proposed DQNalgorithm always beats the counterparts when the numberof available channels changes from 2 to 20 and the batterycapacity changes from 5 to 10 units. Furthermore, the averagesum rate increases with the number of available channels. Byincreasing the battery capacity from 5 to 10 units, the batteryoverflow is reduced, which results in a higher average sumrate.

For Algorithm 2, we perform simulations for the totalbattery prediction loss of all the UEs with the proposed DQNalgorithm, shown in Fig. 8. It can been seen from Fig. 8(a)

0 5000 10000(a) Training steps

0

20

40

60

80

100

120

140

160

Batte

ry p

redi

ctio

n lo

ss o

f all

the

user

s

1000 1500 2000(b) Training steps

0

0.002

0.004

0.006

0.008

0.01

0.012

0.014

0.016

0.018

0.02

Batte

ry p

redi

ctio

n lo

ss o

f all

the

user

s

Fig. 8: Battery prediction loss vs. training steps.

0 0.5 1 1.5 2 2.5Training steps 105

3

3.5

4

4.5

5

5.5

6

6.5

7

7.5

8

Aver

age

sum

rate

(kbp

s)

OfflineDQNMyopic PolicyRound-Robin SchedulingRandom Scheduling

Fig. 9: Average sum rate vs. training steps.

that the prediction loss is quite large at the beginning. With theincrease of training steps, the loss becomes smaller and goesto a stable value after about 1000 training steps. We zoom inover the loss values between 1000 and 2000 training steps inFig. 8(b). The average UE battery prediction loss shown inFig. 8 is about 0.0013 units. It is obvious that the predictionloss is small enough and the proposed deep LSTM predictionnetwork provides good prediction performance.

At last, the performance of the proposed joint scheme inAlgorithm 3 is investigated. The average sum rate and thecorresponding battery prediction loss are shown in Fig. 9 -Fig. 11, respectively. It can be seen from Fig. 9 that the data-drive approaches, i.e., MP and DQN, always perform betterthan the round robin and random scheduling, which is intuitiveand obvious since the last two have no consideration over sumrate optimization. The proposed DQN based algorithm staysin an exploration stage at the beginning, which is unstableand resulting in a worse performance compared with the MPapproach. With more training steps, as expected, the averagesum rate of the proposed DQN algorithm arises to be betterthan MP and remains stable after about 2.2 × 104 training

Page 11: Reinforcement Learning based Multi-Access Control …1 Reinforcement Learning based Multi-Access Control and Battery Prediction with Energy Harvesting in IoT Systems Man Chu, Hang

11

2 4 6 8 10 12 14 16 18 20The number of available channels

2

4

6

8

10

12

14Av

erag

e su

m ra

te (k

bps)

OfflineDQNMyopic PolicyRound-Robin SchedulingRandom Scheduling

C=5

C=10

Fig. 10: Average sum rate vs. battery capacity and available channels.

0 2 4 6(a)Training steps 104

0

20

40

60

80

100

120

140

160

Batte

ry p

redi

ctio

n lo

ss o

f all

the

user

s

3 3.1 3.2(b)Training steps 104

0

0.05

0.1

0.15

Batte

ry p

redi

ctio

n lo

ss o

f all

the

user

s

Fig. 11: Battery prediction loss vs. training steps.

steps. Compared with the offline upper bound, we can observethat though the average sum rate of the proposed DQN cannotachieve the upper bound, the performance gap between the twogets smaller as the training step increases. It can be seen in Fig.9 that after getting stable, the average reward of the proposedjoint algorithm is 9.96% higher than that of the MP approach,21.1% higher than the round-robin approach, 24.7% higherthan the random scheduling approach, and 4.14% lower thanthe offline scheduling. The average sum rates under differentnumbers of available channels and battery capacities are shownin Fig. 10. It can be observed that the proposed DQN algorithmalways defeats the MP, round-robin and random approacheswhen the number of available channels changes from 2 to 20and the battery capacity changes from 5 to 10 units. Besides,it is obvious that the average sum rate of the proposed DQNalgorithm is close to the upper bound. Furthermore, we seethat the average sum rate increases with the increase of batterycapacity and the number of available channels, owing to thereduction of battery overflow.

The performance of the corresponding battery predictionnetwork for the joint scheme is shown in Fig. 11. Comparedwith Fig. 9, we see that the battery prediction loss goes to a

stable stage earlier than the average sum rate. This is becausethat the output of battery prediction network is the maininput for the access control network; only after the batteryprediction is accurate enough, the BS could generate goodscheduling policies that achieve high sum rates. It can beenseen from Fig. 11 (a) that the prediction loss is quite large atthe beginning, becomes smaller as the training step increases,and gets stable after about 22000 training steps. We zoom intothe loss values from the 30000th to 32000th training steps inFig. 11 (b). The average UE battery prediction loss shown inFig. 11 is about 0.0175 units. It is obvious that the predictionloss is small enough and the proposed deep LSTM predictionnetwork provides good prediction values.

VII. CONCLUSION

In this paper, we developed three RL based methods to solvethe user access control and battery prediction problems in amulti-user EH based communication system. With only causalinformation regarding the channel and UE battery states, theLSTM-DQN based scheduling algorithm was designed to findthe optimal policy with the objective of maximizing the long-term discounted uplink sum rate, driven by only instantaneoussystem information. The battery state prediction algorithmbased on deep LSTM was proposed to minimize the predictionloss. Furthermore, the joint problem was considered, wherewe proposed a two-layer LSTM based network which istrained jointly with deep Q-learning to maximize the long-term discounted sum rate and minimize the cumulative batteryprediction loss simultaneously. The simulation results underdifferent conditions were also provided to illustrate the effec-tiveness of our proposed RL based methods.

REFERENCES

[1] P. Kamalinejad, C. Mahapatra, Z. Sheng, S. Mirabbasi, V. C. Leung,and Y. L. Guan, “Wireless energy harvesting for the internet of things,”IEEE Commun. Mag., vol. 53, no. 6, pp. 102–108, June 2015.

[2] Z. Ni, R. V. Bhat, and M. Motani, “On dual-path energy-harvestingreceivers for IoT with batteries having internal resistance,” IEEE InternetThings J., pp. 1–1, Mar. 2018.

[3] S. Ulukus, A. Yener, E. Erkip, O. Simeone, M. Zorzi, P. Grover, andK. Huang, “Energy harvesting wireless communications: A review ofrecent advances,” IEEE J. Sel. Areas Commun., vol. 33, no. 3, pp. 360–381, Mar. 2015.

[4] W. Wang, R. Wang, H. Mehrpouyan, N. Zhao, and G. Zhang, “Beam-forming for simultaneous wireless information and power transfer intwo-way relay channels,” IEEE Access, vol. 5, no. 6, pp. 9235–9250,May. 2017.

[5] M. Chu, B. He, X. Liao, Z. Gao, and V. C. Leung, “On the designof power splitting relays with interference alignment,” IEEE Trans.Commun., vol. 66, no. 4, pp. 1–12, Dec. 2017.

[6] D. T. Thien D. Nguyen, Jamil Y.Khan, “A self-sustainable RF energyharvesting algorithm for WSN-based IoT applications,” in Proc. IEEEGlobeCom, Singapore, Dec. 2017, pp. 168–172.

[7] Z. Yang, W. Xu, Y. Pan, C. Pan, and M. Chen, “Energy efficient resourceallocation in machine-to-machine communications with multiple accessand energy harvesting for IoT,” IEEE Internet Things J., vol. 5, no. 1,pp. 229–245, Nov. 2017.

[8] K. Han and K. Huang, “Wirelessly powered backscatter communicationnetworks: Modeling, coverage, and capacity,” IEEE Trans. WirelessCommun., vol. 16, no. 4, pp. 2548–2561, Apr. 2017.

[9] K. Tutuncuoglu and A. Yener, “Optimum transmission policies for bat-tery limited energy harvesting nodes,” IEEE Trans. Wireless Commun.,vol. 11, no. 3, pp. 1180–1189, Mar. 2012.

Page 12: Reinforcement Learning based Multi-Access Control …1 Reinforcement Learning based Multi-Access Control and Battery Prediction with Energy Harvesting in IoT Systems Man Chu, Hang

12

[10] J. Ren, J. Hu, D. Zhang, H. Guo, Y. Zhang, and X. Shen, “RF energyharvesting and transfer in cognitive radio sensor networks: Opportunitiesand challenges,” IEEE Commun. Mag., vol. 56, no. 1, pp. 104–110, Jan.2018.

[11] A. Ortiz, H. Al-Shatri, T. Weber, and A. Klein, “Multi-agent reinforce-ment learning for energy harvesting two-hop communications with fullcooperation,” arXiv preprint arXiv:1702.06185, Feb. 2017.

[12] X. Di, K. Xiong, P. Fan, H.-C. Yang, and K. B. Letaief, “Optimalresource allocation in wireless powered communication networks withuser cooperation,” IEEE Trans. Wireless Commun., vol. 16, no. 12, pp.7936–7949, Dec. 2017.

[13] J. Yang and S. Ulukus, “Optimal packet scheduling in a multiple accesschannel with energy harvesting transmitters,” J. Commun. and Netw.,vol. 14, no. 2, pp. 140–150, Apr. 2012.

[14] P. Blasco and D. Gunduz, “Multi-access communications with energyharvesting: A multi-armed bandit model and the optimality of themyopic policy,” IEEE J. Sel. Areas Commun., vol. 33, no. 3, pp. 585–597, Mar. 2015.

[15] M. B. Khuzani and P. Mitran, “On online energy harvesting in multipleaccess communication systems,” IEEE Trans. Inf. Theory, vol. 60, no. 3,pp. 1883–1898, Mar. 2014.

[16] P. Blasco, D. Gunduz, and M. Dohler, “Low-complexity schedulingpolicies for energy harvesting communication networks,” in Proc. IEEEISIT, Istanbul, Turkey, July 2013, pp. 1601–1605.

[17] C. Wang, J. Li, Y. Yang, and F. Ye, “Combining solar energy harvestingwith wireless charging for hybrid wireless sensor networks,” IEEE Trans.Mobile Comput., vol. 17, no. 3, pp. 560–576, Mar. 2018.

[18] P. Sakulkar and B. Krishnamachari, “Online learning schemes forpower allocation in energy harvesting communications,” IEEE Trans.Inf. Theory, pp. 1–1, Nov. 2017.

[19] P. Blasco, D. Gunduz, and M. Dohler, “A learning theoretic approachto energy harvesting communication system optimization,” IEEE Trans.Wireless Commun., vol. 12, no. 4, pp. 1872–1882, Apr. 2013.

[20] A. Ortiz, H. Al-Shatri, X. Li, T. Weber, and A. Klein, “Reinforcementlearning for energy harvesting point-to-point communications,” in Proc.IEEE ICC, Kuala Lumpur, Malaysia, May. 2016, pp. 1–6.

[21] G. J. Gordon, “Reinforcement learning with function approximationconverges to a region,” in Proc. NIPS, San Francisco, USA, Nov. 2001,pp. 1040–1046.

[22] V. Mnih, K. Kavukcuoglu, D. Silver, A. A. Rusu, J. Veness, M. G.Bellemare, A. Graves, M. Riedmiller, A. K. Fidjeland, G. Ostrovskiet al., “Human-level control through deep reinforcement learning,”Nature, vol. 518, no. 7540, pp. 529–534, Feb. 2015.

[23] V. Mnih, K. Kavukcuoglu, D. Silver, A. Graves, I. Antonoglou, D. Wier-stra, and M. Riedmiller, “Playing atari with deep reinforcement learn-ing,” arXiv preprint arXiv:1312.5602, Dec. 2013.

[24] S. Gu, T. Lillicrap, I. Sutskever, and S. Levine, “Continuous deep Q-learning with model-based acceleration,” in Proc. Intl. Conf. on MachineLearning, New York, USA, June 2016, pp. 2829–2838.

[25] M. Deruyck, D. Renga, M. Meo, L. Martens, and W. Joseph, “Account-ing for the varying supply of solar energy when designing wirelessaccess networks,” IEEE Trans. on Green Commun. and Netw., vol. 2,no. 1, pp. 275–290, Mar. 2018.

[26] S. Kosunalp, “A new energy prediction algorithm for energy-harvestingwireless sensor networks with Q-learning,” IEEE Access, vol. 4, no. 7,pp. 5755–5763, Sep. 2016.

[27] A. Cammarano, C. Petrioli, and D. Spenza, “Online energy harvestingprediction in environmentally powered wireless sensor networks,” IEEESensors J., vol. 16, no. 17, pp. 6793–6804, Sep. 2016.

[28] H. U. Yildiz, V. C. Gungor, and B. Tavli, “A hybrid energy harvestingframework for energy efficiency in wireless sensor networks basedsmart grid applications,” in 2018 17th Annual Mediterranean Ad HocNetworking Workshop (Med-Hoc-Net). Capri, Italy: IEEE, June 2018,pp. 1–6.

[29] A. A. Nasir, X. Zhou, S. Durrani, and R. A. Kennedy, “Relayingprotocols for wireless energy harvesting and information processing,”IEEE Trans. Wireless Commun., vol. 12, no. 7, pp. 3622–3636, Jul.2013.

[30] R. Zhang, J. Wang, Z. Zhong, C. Li, X. Du, and M. Guizani, “Energy-efficient beamforming for 3.5 GHz 5G cellular networks based on 3Dspatial channel characteristics,” Elsevier Comput. Commun., vol. 121,no. 5, pp. 59–70, Mar. 2018.

[31] X. Zhou, B. Bai, and W. Chen, “Greedy relay antenna selection for sumrate maximization in amplify-and-forward mimo two-way relay channelsunder a holistic power model,” IEEE Trans. Wireless Commun., vol. 19,no. 9, pp. 1648–1651, Jun. 2015.

[32] R. S. Sutton and A. G. Barto, Reinforcement learning: An introduction,2nd ed. MIT press Cambridge, 2014.

[33] S. Verdu, “Fifty years of shannon theory,” IEEE Trans. Inf. Theory,vol. 44, no. 6, pp. 2057–2078, Apr. 1998.

[34] K. Narasimhan, T. Kulkarni, and R. Barzilay, “Language understandingfor text-based games using deep reinforcement learning,” arXiv preprintarXiv:1506.08941, June 2015.

[35] K. Cho, B. Van Merrienboer, C. Gulcehre, D. Bahdanau, F. Bougares,H. Schwenk, and Y. Bengio, “Learning phrase representations usingRNN encoder-decoder for statistical machine translation,” arXiv preprintarXiv:1406.1078, June 2014.

[36] T. Mikolov, S. Kombrink, L. Burget, J. Cernocky, and S. Khudanpur,“Extensions of recurrent neural network language model,” in Proc.ICASSP, Prague, Czech Republic, May. 2011, pp. 5528–5531.

[37] R. Zhang, X. Jiang, T. Taleb, B. Li, H. Qin, Z. Zhong, and X. Zhang,“Connecting a city by wireless backhaul: 3d spatial channel characteri-zation and modeling perspectives,” IEEE Commun. Mag., vol. 55, no. 5,pp. 62–69, May. 2017.