Buffer Space Management in Intermittently Connected Internet of Things: Sharing or Allocation?

—The efﬁcient buffer space management in intermittently connected Internet of Things (IC-IoT) is of great importance for data delivery performance guarantee in such networks. This article considers two typical buffer space management policies for IC-IoT, i.e., buffer-space sharing (BS) and buffer-space allocation (BA). The BS policy allows the buffer space of each device to be fully shared by the exogenous packets and the packets from other devices, while the BA policy divides the buffer space into the source buffer and relay buffer for storing the two kinds of packets separately. With the help of the queueing theory and Markov chain theory, we develop a theoretical framework to capture the sophisticated queueing processes for the buffer space under either BS or BA policy, which enables the limiting distribution of the buffer occupation state to be determined. We then provide theoretical modeling for throughput and expected end-to-end delay to evaluate the fundamental performance of the IC-IoT under the BS and BA policies. Finally, extensive simulation and numerical results are presented to validate theoretical models and to demonstrate the effects of BS and BA policies on the IC-IoT performance.


I. INTRODUCTION
I NTERNET of Things (IoT) represents a revolutionary advance promoted by the rapid development of wireless communication technologies [1], [2].The inherent nature of IoT is to deploy billions of interconnected smart objects that are capable of sensing the surroundings, and transmitting and processing acquired data without human intervention [3].Recent years have witnessed a booming of IoT, and it is predicted that there will be approximately 40 billion IoT devices across the globe by 2023 [4].As an emerging technology paradigm, IoT is playing an increasingly important role in human life, and its application has expanded to more and more domains, such as smart homes [5], smart cities [6], intelligent healthcare [7], industrial automation [8], and geohazard prevention [9], to name a few.
To accelerate the commercialization process of IoT, both academia and industrial communities have been making great efforts to investigate the underlying technologies as well as the application paradigms from a variety of perspectives.Among these studies, the performance modeling/evaluation/enhancement of IoT systems remains a central focus, because they reveal the critical performance (e.g., throughput, latency, energy efficiency, and so on) that can be achieved or pursued by the IoT systems theoretically, laying substantial foundations for practical design and implementation to satisfy the various Quality-of-Service (QoS) requirements.
To evaluate the throughput of narrowband IoT (NB-IoT) with random access systematically, Sun et al. took the first attempt to develop a Markov chain (MC)-based theoretical framework in [10].Al-Kaseem et al. [11] implemented a proof-of-concept real-time testbed to study the programmable network technologies for the end-to-end delay enhancement in IoT devices.Andres-Maldonado et al. [12] proposed an analytical evaluation framework to study the performance of NB-IoT in terms of uplink packet transmission latency and battery lifetime.Considering IoT networks with the successive interference cancellation-based pure Aloha strategy and This work is licensed under a Creative Commons Attribution 4.0 License.For more information, see https://creativecommons.org/licenses/by/4.0/ the irregular repetition slotted ALOHA strategy, respectively, Wang and Fapojuwo [13] investigated the throughput and packet delivery ratio performance, while Noori et al. [14] determined the capacity region as well as the average and maximum delay of packet delivery.Zhang et al. [15] developed a multigroup analytical framework based on the double-queue model to evaluate and optimize the throughput and mean access delay performance in industrial IoT.Wang et al. [16] proposed a distributed stochastic optimization framework for multipath transmission control and throughput maximization in information-centric networking IoT.More recently, considering a QoS-constrained IoT system operating with finite blocklength codes to support low-latency communications, Hu et al. [17] studied the throughput performance evaluation and optimization under two typical data arrival models.To fulfill the QoS requirements of various IoT services, Montazerolghaem and Yaghmaee [18] designed a control and management framework based on the software-defined networking technique.For cellular IoT networks with massive devices, Jang et al. [19] developed a versatile access control mechanism that can effectively satisfy various performance metrics, such as access throughput, access delay, and energy efficiency.

A. Motivations
Note that the above existing works represent great progress in the performance study of IoT; however, they are not omnipotent methodologies applicable to all network scenarios and do not take into consideration the buffer space constraint on practical IoT devices.Specifically, in a wide range of practical IoT applications, e.g., wireless sensor networks and drone networks, mobile devices with low transmit power employ short-range communication techniques, such as Bluetooth low energy, wireless fidelity, and ZigBee to realize autonomous communication and plug-and-play characteristics [20].In this context, the mobility and short transmit range of devices could lead to intermittent wireless connectivity, and thus, there does not exist a stable and complete path from a source device to a destination device.To accomplish end-to-end information delivery, the source can send its packets to an intermediate device, called a relay, if they are within the transmit range; the relay stores and carries the packets, and can forward the packets later when encountering the destination.To support the store-carry-forward function, it is essential to equip intermediate devices with buffers.Since IoT devices are mostly lightweight, the equipped buffer resource will be limited, and thus, how to utilize efficiently the buffer space has a strong impact on the performance and QoS that can be achieved by IoT systems.Therefore, understanding the efficiency of buffer space management policies in intermittently connected IoT (IC-IoT) is of great significance.However, there are rare studies on this aspect to the best of our knowledge.

B. Contributions
As an attempt to fill this void, in this article, we focus on a buffer-limited IC-IoT system with two typical buffer space management policies, and investigate the performance modeling and evaluation in terms of the throughput and expected end-to-end delay by developing novel and general analytical frameworks theoretically as well as establishing network simulations.The main contributions of this article are threefold.
1) We consider two buffer space management policies, i.e., buffer-space sharing (BS) and buffer-space allocation (BA), to support efficient end-to-end data delivery in buffer-limited IC-IoT.Based on the queueing theory and MC theory, we capture the sophisticated queueing processes for the buffer space of devices in IC-IoT under the BS and BA policies, respectively, which enable the limiting distribution of the buffer occupation state (BOS) to be determined.2) Based on the capture of queueing processes, we develop theoretical performance modelings under the BS and BA policies, respectively, to evaluate the fundamental performance of IC-IoT accurately, including the throughput and expected end-to-end delay.The proposed performance modelings are applicable to any media access control (MAC) schemes and any mobility models that lead to the uniform distribution of devices' locations.3) We establish network simulations to verify the validity of our theoretical performance modelings.In addition, extensive numerical results are presented to demonstrate the performance behaviors of IC-IoT under the BS and BA policies comprehensively.Some insightful findings are revealed, which can serve as important guidelines for the configuration and operation in practical IC-IoT.The remainder of this article is organized as follows.We survey related works in Section II.Section III introduces the system models involved in this study.We develop the performance modelings under the BS and BA policies in Sections IV and V, respectively.Section VI presents the simulation and numerical results, followed by the conclusion in Section VII.

II. RELATED WORKS
In the literature, some studies on the utilization of buffers in wireless communication systems can be found.Cui et al. [21] considered a two-hop network and proposed a delay optimal link selection approach to minimize the average sum queue length based on a buffered decode-and-forward protocol.Focusing on the resource allocation in the downlink of wireless relay networks, Hajipour et al. [22] designed a stochastic network optimization scheme with the aid of buffers to maximize the system energy efficiency while maintaining the queue stability.In [23], an MC-based framework was developed to evaluate the throughput performance of twohop links with an energy buffer-aided IoT source and a data buffer-aided relay.The performance evaluation of buffer-aided cooperative nonorthogonal multiple access in IoT was recently investigated in [24] and [25], where the expressions of system throughput and average delay were derived theoretically based on the buffer state analysis.Although these works provide insights into the usage of buffers in wireless systems, they considered the buffer space capacity is infinite and thus, cannot apply to the buffer-limited scenarios.
Considering limited buffer constraints, the performance modeling and evaluation of mobile ad hoc networks was investigated in [26] for the throughput-delay scaling laws, and in [27] and [28] for the exact expressions of performance metrics.In [29] and [30], the buffer-constrained throughput performance was analyzed in multiuser wireless-powered communication systems.Ren et al. [31] proposed an enabling technique for the Lyapunov optimization of fog computing to operate under finite buffers of IoT devices without the loss of asymptotic optimality.More recently, the delay performance of buffer-limited wireless sensor networks with different queueing principles was evaluated experimentally in [32].However, the performance modeling and evaluation of buffer space management policies in IC-IoT still remain an open problem.

III. SYSTEM MODELS
In this section, we present the network model, routing scheduling, buffer space management policies, and performance metrics involved in this study.

A. Network Model
As illustrated in Fig. 1, N(N ≥ 3) devices with limited transmit range randomly move in a torus area, composing an IC-IoT network.The motion of devices follows the timeslotted uniform mobility model [33]- [35], which indicates that the stochastic process of a device's location is stationary and ergodic with stationary distribution uniform on the network area, and the trajectories of different devices are independent and identically distributed. 1 There are N unicast traffic flows in the IoT, and each device is the source of one traffic flow and meanwhile, the destination of another traffic flow.Such traffic pattern is also termed the permutation model and it is widely adopted in the literature, such as [33], [35], [36].Without loss 1 The uniform mobility model is general in the sense that it covers several typical mobility models as special cases, including the i.i.d.mobility model, the RW model, the random way-point model, etc. of generality, the amount of data that can be delivered by a device during one time slot is bounded and normalized to one packet.The exogenous packet arrival (i.e., packet generation) at each device is considered to be an independent identically distributed (i.i.d.) Bernoulli process with the mean rate λ e .That is, at the end of every time slot, there is a new exogenous packet arriving with probability λ e .We consider that every device possesses a buffer space of size B packets for storing its exogenous packets and the packets from other devices.

B. Routing Scheduling
Due to the transmit range limitation, a device's data (exogenous packets) may not be delivered to the destination directly.Note that in the IC-IoT, a stable multihop path (route) from a source to the destination does not exist.Therefore, we employ the two-hop relaying opportunistic routing (2HR-OR) algorithm for end-to-end data delivery.The 2HR-OR algorithm takes advantage of network mobility to acquire multiuser diversity gain and has been demonstrating its high efficiency in mobile ad hoc networks [33], [35].
To mitigate wireless interference, a MAC scheme, such as Aloha, CSMA, and 802.11DCF, is required to determine which device within a certain area can get access to the wireless channel in a time slot.It is worth mentioning that our framework is applicable to any MAC schemes, so we do not specify the MAC scheme in the sequel, but only in Section VI we adopt a typical MAC scheme for simulation demonstration.Without loss of generality, we focus on a tagged flow and denote its source and destination as S and D, respectively.S executes the 2HR-OR algorithm once it obtains the channel access at the beginning of a time slot, as summarized in Algorithm 1. Fig. 1 illustrates the data delivery process when executing the 2HR-OR algorithm.The 2HR-OR algorithm leads to out-of-order delivery, but such an issue can be easily solved at the destination by identifying the sequence number or time information carried on the packets.
In Algorithm 1, let p sd , p sr , and p rd denote the probabilities that a device executes the Source-to-Destination, Source-to-Relay, and Relay-to-Destination operations, Note that these probabilities are MAC-dependent and will be regarded as known parameters when we develop the general framework for the IC-IoT performance modeling in Sections IV and V.In the simulations, we will specify the MAC scheme and calculate the corresponding p sd , p sr , and p rd .

C. Buffer Space Management Policies
Note that the role of a device in the IC-IoT is not only the source or destination of exogenous packets but also the relay that stores and forwards packets for other devices.Therefore, to support efficient end-to-end packet delivery among devices, appropriate buffer space management policies are required.In this work, we consider the following two policies.

1) Buffer-Space Sharing Policy:
As illustrated in Fig. 2(a), the BS policy indicates that the buffer space of each device is fully shared by its exogenous packets and the packets from other devices.When either an exogenous packet or a packet of other devices arrives, this packet will be dynamically assigned a storage space if the entire buffer space does not overflow.The packets belonging to the same traffic flow (i.e., destined to the same device) constitute a virtual buffer queue, and thus, there are in total N − 1 virtual queues, i.e., one source queue used for its own flow, and N − 2 relay queues used for other N − 2 flows (one queue corresponds to one flow).All queues follow the first-in-first-out (FIFO) discipline.When the buffer space overflows, the new arrival packets will be dropped.When a packet leaves its queue, the storage space is released to the entire buffer space.
2) Buffer-Space Allocation Policy: As illustrated in Fig. 2(b), different from the BS policy, the BA policy divides the entire buffer space into two parts, i.e., the source buffer of size B S packets, and the relay buffer of size B R packets.There is B S + B R = B.The source buffer is used for storing the packets of its own flow (exogenous packets) and works as a FIFO source queue.The relay buffer is used for storing packets of other N − 2 flows and works as N − 2 FIFO virtual relay queues (one queue corresponds to one flow).When the source (resp.relay) buffer overflows, the new arrival exogenous packets (resp.packets of other devices) will be dropped.When a packet leaves the source (resp.a relay) queue, the storage space is released to the source (resp.relay) buffer space.It is intuitive that different network performance can be achieved by adjusting the BA, i.e., the value of B S .

TABLE I MAIN NOTATIONS
Note that when packets are dropped, we do not consider retransmission due to the following reasons: 1) the retransmission mechanism will increase the complexity of interactive control between the transmitter and receiver, which could not be suitable for the resource-limited IoT devices; 2) the retransmission will exacerbate network congestion, which causes a heavier burden on the buffer space of IoT devices; and 3) the information carried on the dropped packets is old compared with that carried on new arrival packets, and the fresh information is preferred for most practical applications.

D. Performance Metrics
We consider two fundamental metrics for the system performance evaluation under the BS and BA policies, i.e., per-flow throughput and expected end-to-end delay, which are defined as follows.
Per-Flow Throughput: Let T denote the throughput of a traffic flow, which is defined as the time-average number of exogenous packets of the source device delivered to its destination (in units of packets/slot).
Expected End-to-End Delay: Let W denote the end-to-end delay of a packet, which is defined as the number of time slots it takes the packet to reach its destination after it enters the source queue.Let E{W} denote the expectation of W. Note that the end-to-end delay of dropped packets is infinite and does not make sense, and we only count the delay performance of the packets that are successfully delivered to their destinations.
The main notations are listed in Table I.

IV. PERFORMANCE MODELING UNDER BS POLICY
In this section, we develop an MC-based theoretical framework for the IC-IoT performance modeling under the BS policy.We first analyze the BOS transitions.Then, we determine the limiting distribution of BOS, based on which we further derive the expressions of performance metrics.Due to the symmetry of devices and traffic flows, we can focus on a general tagged flow with the source S and the destination D in the following analysis.

A. Buffer Occupation State Transitions
We use a two-tuple H(t) = K(t), L(t) to denote the BOS of device S in time slot t, where K(t) denotes the number of exogenous packets occupying the buffer space (i.e., in the source queue), and L(t) denotes the number of packets of other devices occupying the buffer space (i.e., in the relay queues); here K(t) ≥ 0, L(t) ≥ 0, and Note that for a device in any time slot, the Source-to-Destination, Source-to-Relay, and Relay-to-Destination operations are mutually exclusive.Therefore, as illustrated in Fig. 3, suppose that the current BOS of S is k, l , and then one of the following transitions may happen in the next time slot.
Case 1 ( k, l → k, l ): Case 1 can be divided into two subevents: 1) no packet enters the buffer space and no packet leaves the buffer queues and 2) S delivers the Head-of-Line (HoL) packet in the source queue to the destination or a relay device, and then a new exogenous packet arrives at S and enters its source queue.Case 2 ( k, l → k, l + 1 ): Another device (except the source of S) delivers a packet to S and the packet enters the corresponding relay queue, and then no exogenous packet arrives at S.  then a new exogenous packet arrives at S and enters its source queue.Case 7 ( k, l → k − 1, l ): S delivers the HoL packet in its source queue to the destination or a relay device, and then no exogenous packet arrives at S. Let P z denote the probability that Case z happens.To determine P z , we denote μ S the service rate of the source queue, μ (l) R the service rate of the relay queues conditioned on that there are l packets in the relay queues, and λ R the packet arrival rate at the relay queues, which are given in the following lemma.
Lemma 1: μ S , μ (l) R , and λ R are expressed as μ S = p sd + p sr (1) where se denotes the probability that the source queue is empty (i.e., there is no exogenous packet occupying the buffer space).Proof: See Appendix A. With the help of Lemma 1, P z can be determined as

B. Limiting Distribution of Buffer Occupancy State
Based on the above analysis, we know that the BOS of S at time slot t + 1 depends only on that at time slot t.Therefore, as time evolves, the buffer occupancy process {H(t), t = 0, 1, 2, . ..} forms an MC.According to the BOS transition cases in Fig. 3, the state transition diagram of the buffer occupancy process can be summarized in Fig. 4. From the state transition diagram, we can see that: 1) each state is recurrent; 2) the period of each state is 1, so each state is aperiodic; and 3) the MC is irreducible.With these properties, it can be concluded that the MC is ergodic, and thus, the limiting distribution of the BOS exists and is unique, which is equal to the stationary distribution [37].We arrange all the BOSs in a left-to-right and top-to-down way, i.e., { 0, 0 , . . ., 0, B , 1, 0 , . . ., 1, B − 1 , . . ., B, 0 }, and define the following matrices. 1) According to the analysis of BOS transition cases in Section IV-A, the structures of A k , B k , and C k can be respectively, determined as . . . . . . . . .
Let P denote the one-step state transition matrix of the buffer occupancy process.Then, we have Let k,l denote the probability that the buffer occupancy is at state k, l when the time slot tends to infinity.Then, the limiting distribution of the BOS, denoted as lim = [ 0,0 , . . ., 0,B , 1,0 , . . ., 1,B−1 , . . ., B,0 ], is given by lim where 1 is a column vector of size (0.5B 2 + 1.5B + 1) × 1 with all elements being 1, and (10) follows from the normalization property of a probability vector.By substituting ( 5)-( 7) into ( 9), we can determine the limiting distribution of the BOS lim .

C. Performance Evaluation
With the help of BOS limiting distribution, we further derive the throughput and expected end-to-end delay of the IC-IoT under BS policy.We have the following theorems.
Theorem 1: For the IC-IoT under BS policy, the per-flow throughput T BS is given by Proof: Let Ṫ and T denote the packet receive rates at the destination device D through the one-hop delivery (Source-to-Destination) and the two-hop delivery (Source-to-Relay and then Relay-to-Destination), respectively.Let λ o denote the packet departure rate of the source queue of S. Note that with ratio (p sd /μ S ), the packets leaving from the source queue of S are sent to D directly, so we have With ratio (p sr /μ S ), the packets leaving from the source queue of S are sent to relay devices, and they can enter the relay queues (i.e., are not dropped) when the corresponding buffer space is not overflow.Let x(t) denote the number of packets occupying the relay queues of all devices at time slot t.Thus, according to the definition, T can be expressed as Since 0 ≤ x(t) ≤ NB, lim t→∞ ([x(t)]/Nt) = 0.Then, we have Note that the source queue is a Bernoulli/Bernoulli queue, which satisfies the property of reversibility [38], and the packet departure process of the source queue is also a Bernoulli process with the rate λ o being determined as Substituting ( 15) into ( 12) and ( 14), and then (11) follows from T BS = Ṫ + T. This completes the proof.Theorem 2: For the IC-IoT under BS policy, the expected end-to-end delay of a packet is given by where k,l represents the probability that the buffer occupancy is at state k, l conditioned on that the buffer space is not overflow, which is determined as Proof: Without loss of generality, we focus on a tagged exogenous packet p, which enters the source queue of S and is eventually delivered to D successfully.Let n S denote the expected number of packets in the source queue of S when packet p enters, then n S is determined as Therefore, the expected number of time slots it takes packet p to experience in the source queue, denoted as W S , is given by Note that when packet p is sent out by S, with probability ( Ṫ/[ Ṫ + T]) it is delivered to D directly, and with probability ( T/[ Ṫ + T]) it is sent to a relay device R, where Ṫ and T are given by ( 12) and ( 14), respectively.For the case that packet p is sent to R, let n R denote the expected number of packets in the relay queues of R when p enters its corresponding relay queue.Then, we have Due to the symmetry of the relay queues, the expected number of packets in a relay queue is ), and the service rate of each relay queue is (p rd /[N − 2]).Therefore, the expected number of time slots it takes packet p to experience in the relay queue, denoted as W R , is given by Based on the above results, the expected end-to-end delay of packet p can be determined as By performing algebra operations on ( 22), ( 16) is obtained.This completes the proof.

V. PERFORMANCE MODELING UNDER BA POLICY
In this section, we conduct performance modeling for the IC-IoT under BA policy.Note that for a given BA the size of source/relay buffer space is fixed, we can analyze their buffer occupancy processes separately.Same as the analysis in Section IV, we focus on a general tagged flow with the source S and the destination D.

A. Limiting Distribution of Source BOS
Regarding the source buffer space of S, in every time slot, a new exogenous packet arrives with probability λ e , and a packet in the source buffer can be served (i.e., sent out) with probability μ S = p sd + p sr .Therefore, the occupancy process of source buffer space can be modeled as a Bernoulli/Bernoulli queue of size B S .
Let k denote the probability that there are k packets occupying the source buffer space as the time slot tends to infinity, and lim = [ 0 , 1 , . . ., B S ] denote the limiting distribution of the source BOS.According to [38], k can be determined as and H is the normalization constant.Note that lim •1 = 1, where 1 is a column vector of size (B S + 1) × 1 with all elements being 1.Then, we have

B. Limiting Distribution of Relay BOS
We use R(t) to denote the relay BOS of S in time slot t, which is on the state space {0, 1, . . ., B R }.Note that when S serves as a relay in any time slot, the Source-to-Relay and Relay-to-Destination operations are mutually exclusive.Therefore, suppose that the current relay BOS is l, and then one of the following transitions may happen in the next time slot.
Case 1 (l → l): No packet enters the relay buffer space and no packet leaves the relay queues.Case 2 (l → l + 1): Another device (except the source of S) delivers a packet to S and the packet enters the corresponding relay queue.Case 3 (l → l − 1): S delivers the HoL packet in one of its relay queues to the destination.Let Q l,l denote the one-step BOS transition probability from state l to state l .Similar to the proof of Lemma 1, we have the following proposition.
Proposition 1: The one-step BOS transition probability of the relay buffer space is given by Therefore, the occupancy process of the relay buffer space {R(t), t = 0, 1, 2, . ..} can be modeled as a birth-death chain, and its one-step state transition matrix Q is represented as From the structure of the state transition matrix Q, it can be determined that the birth-death chain is ergodic.Thus, the limiting distribution of the relay BOS exists and is unique, and it is equal to the stationary distribution.Let l denote the probability that there are l packets occupying the relay buffer space as the time slot tends to infinity, and lim = [ 0 , 1 , . . ., B R ] denote the limiting distribution of the relay BOS.Then, we have where 1 is a column vector of size (B R + 1) × 1 with all elements being 1.
By solving equations ( 27) and ( 28), the limiting distribution of the relay BOS is determined as

C. Performance Evaluation
With the help of the source and relay BOS limiting distributions, we have the following proposition for the performance evaluation of the IC-IoT under BA policy.
Proposition 2: For the IC-IoT under BA policy, the perflow throughput T BA and the expected end-to-end delay of a packet E{W BA } are given by where n S (resp.n R ) denotes the expected number of packets in the source queue (resp.relay queues) conditioned on that the source (resp.relay) buffer space is not overflow, which is determined as Proof: The proof is similar to that of Theorems 1 and 2, so we omit the details.
Based on Proposition 2, we have the following corollary for the theoretically provable properties of the per-flow throughput under BA policy.
Corollary 1: For the IC-IoT under BA policy, the per-flow throughput T BA increases monotonically as the exogenous packet arrival rate λ e increases, and its supremum, denoted as T BA sup , is given by When α = 0.5, expression (34) can be reduced to

VI. SIMULATION RESULTS
In this section, we first conduct simulations to verify the efficiency of our theoretical performance modelings for the IC-IoT under the two buffer space management policies.Then, we present numerical results to demonstrate the performance behaviors impacted by the network parameters.

A. Simulation Settings
In the simulations, we adopt a cell-partitioned structurebased MAC scheme to specify the wireless media access for the devices, which is widely applied in the studies on autonomous wireless networks [34], [35], [39], [40].As illustrated in Fig. 5, the network area is partitioned into M × M nonoverlapping cells of equal size.In every time slot, each cell can support one pair of devices for packet delivery, devices in different cells cannot deliver packets to each other.Wireless interference caused by concurrent transmissions in different cells is mitigated by requiring devices in neighboring cells to transmit over orthogonal frequency bands.At the beginning of each time slot, all devices in the same cell compete for access to wireless media by employing the IEEE 802.11DCF mechanism [41].Under such a MAC scheme, the probabilities that a device executes the Source-to-Destination, Source-to-Relay, and Relay-to-Destination operations in a time slot are determined as follows (see Appendix C for the details): To validate our theoretical performance modelings, we developed a dedicated network simulator [42] based on C++ programming, which can simulate the processes of device moving, exogenous packet arrival, packet queueing, and packet delivery in an IC-IoT.The simulator allows various system parameters (such as the number of devices N, the size of buffer space B, and the exogenous packet arrival rate λ e ) to be adjusted, and two typical specific mobility models belonging to the uniform mobility type to be implemented as follows.
1) I.i.dModel: At the beginning of each time slot, each device independently selects a cell among all cells with equal probability and then stays in it during this time slot.2) Random Walk (RW) Model: At the beginning of each time slot, each device independently selects a cell among its current cell and its eight adjacent cells with equal probability 1/9 and then stays in it during this time slot.The duration of each task of simulation is set to be 2 × 10 8 time slots.In each task, we begin to observe after 10 8 time slots.This is because the system will enter the stable state, which ensures the accuracy of the simulation results.The simulation settings are summarized in Table II.

B. Validation of Performance Modelings
We summarize in Fig. 6 the theoretical and simulation results of the throughput performance in the considered IC-IoT.Fig. 6 shows that the simulation results match nicely with the theoretical ones for all the cases, which demonstrates that our theoretical modelings are highly efficient for the throughput performance evaluation of IC-IoT under both the BS and BA policies.We can observe that when the exogenous packet arrival rate λ e is relatively small (i.e., the network traffic load is light), the throughput performance under the BS policy is superior to that under the BA policy.This is because the BS policy allows packets to occupy the buffer space of any devices unrestrainedly, which leads to more packets being injected into and then delivered through the IoT.On the other hand, when λ e is large (i.e., the network traffic load is heavy), the throughput performance under the BS policy is degraded and the BA policy can receive a higher per-flow throughput.It indicates that a scheduled BA plan can cope with a heavy network load in the terms of throughput guarantee.Fig. 7 presents the theoretical and simulation results of the expected end-to-end delay performance in the considered IC-IoT.It can be observed from Fig. 7 that all the simulation results are in accordance with the corresponding theoretical curves well, which verifies that our theoretical modelings are also highly efficient for the delay performance evaluation of IC-IoT under both the BS and BA policies.Fig. 7 shows that when λ e is small, the BS policy incurs a larger end-to-end delay compared with the BA policy.The reason is that the BS policy allows more packets to be stored in the network, and a new exogenous packet is expected to experience a longer time for the queueing processes in both the source and relay devices.

C. Performance Discussions
With the help of the proposed theoretical modelings, numerical results can be provided accordingly to show diverse performance behaviors of the IC-IoT under the two buffer management policies.
We plot Fig. 8 to show how the network performance varies with the size of buffer space, where we set N = 18, M = 3, λ e = 0.2 (packets/slot), and α = 0.5.For the BA policy, we consider three allocation cases, i.e., the size of source buffer space B S is set to be 0.3, 0.5, and 0.7B rounded to the nearest integers, respectively.Fig. 8(a) shows that under both the BS and BA policies, the throughput performance can be improved by expanding the buffer space, but a more careful discovery is that the throughput gains gradually diminish as the buffer space becomes large.This is because the throughput performance of the IC-IoT depends not only on the buffer space of devices but also on the transmission opportunity that is constrained by the wireless media access and routing scheduling.We can also observe that when B is very small, the BA policy with any allocation plans can achieve higher throughput than that of the BS policy; as B increases, the throughput under the BS policy gradually overtakes that under the BA policy, unless the BA policy has a reasonable allocation plan, i.e., allocating more buffer space to the relay buffer.Fig. 8(b) shows the expected end-to-end delay under both the BS and BA policies increases monotonically as the buffer space grows up.This is because when B becomes larger, more packets can be stored in devices, leading to a higher queueing delay.It can be observed that the delay under the BA policy is smaller than that under the BS policy, which indicates that by adopting a reasonable allocation plan, the BA policy has the potential to receive advantages on both the throughput and delay performance simultaneously.
We summarize in Fig. 9 the network performance behaviors under the variation of the exogenous packet arrival rate λ e , where we set N = 18, M = 3, and α = 0.5.It is interesting to find the two buffer management policies lead to very different throughput and delay behaviors.In Fig. 9(a), as λ e increases, the throughput under the BA policy monotonically grows up (as proved in Corollary 1); however, the throughput under the BS policy first increases and then decreases, and converges to the same value regardless of the size of buffer space.This is due to the reason that as λ e increases, more exogenous packets occupy a larger source buffer space, and thus, there remains less space for the relay buffer, leading to the impairment of multiuser diversity gain brought by the device mobility.When λ e → 1, the exogenous packets occupy the entire buffer space, however, any exogenous packet cannot be delivered to a relay device even the Source-to-Relay operation is executed.Accordingly, the exogenous packets are delivered to the destination only by the direct Source-to-Destination operation, i.e., no multiuser diversity gain.Then, we have lim Fig. 9(a) also shows that under the BA policy, the throughput could be higher if the relay buffer is allocated with a relatively large space.Therefore, an insight revealed here is: to enable the IC-IoT to receive a good throughput performance, reserving sufficient space for the relay buffer to support the multiuser diversity gain is very essential, especially when the network traffic load is heavy.In Fig. 9(b), as λ e increases, the expected end-to-end delay under the BS policy increases first and then decreases, while the trend under the BA policy is somewhat complicated, which depends on the specific allocation plans.The effects of increasing traffic load on the delay performance are two folds.On one hand, more packets occupy the buffer space, which leads to longer queueing processes; on the other hand, the relay buffer is more likely to overflow, which leads to a lower ratio for a packet to be delivered in a two-hop way and thus, the decrease of end-to-end delay.Another interesting observation from Fig. 9(b) is that when λ e → 0, E{W} is the same for all the cases.Actually, based on our theoretical modelings, we can easily derive lim We plot Fig. 10 to show how the network performance varies with the parameter α, which represents the ratio of executing the Source-to-Relay operation if a device gets the channel access but cannot deliver a packet to its destination, i.e., α/(1 − α) = p sr /p rd .We set N = 18, M = 3, and λ e = 0.2 (packets/slot).It can be observed from Fig. 10(a) that the per-flow throughput for all the cases first increases and then decreases with the growth of α.It indicates that the throughput performance of the IC-IoT can be improved by setting α appropriately.Fig. 10(b) shows that the variation of α also greatly impacts the delay performance, especially for the BS policy.When α → 1, the expected end-to-end delay under the BS policy increases sharply.An important finding here is that if α is set to be too small or too large, not only the throughput performance is degraded but also a longer delay is incurred at the same time.
In Fig. 11, we further show the joint effects of λ e and α on the throughput and delay performance of the IC-IoT, where we set N = 18, M = 3, B = 10, and B S = B R = 5.We can observe from Fig. 11(a) and (b) that under both the BS and BA policies, for any given exogenous packet arrival rate λ e the per-flow throughput is a unimodal function w.r.t.α.It indicates that there always exists a unique optimal setting of α, which enables the IC-IoT to achieve a corresponding maximal throughput.It is interesting to find that as λ e increases, the optimal setting of α under the BS policy increases significantly, while that under the BA policy does not change so much, which is always less than 0.5.Moreover, we can see that for any given α, T BS is a unimodal function w.r.t.λ e , while T BA is an increasing function w.r.t.λ e .Fig. 11(c  shows that for a wide range of λ e , e.g., roughly from 0.0001 to 0.9, E{W BS } increases greatly when α becomes relatively large.Fig. 11(d) shows that E{W BA } can be large when α → 1 only for a very small range of λ e , e.g., roughly from 0.0001 to 0.1.It indicates that when adopting the BS policy, the network parameters need to be set more carefully, such that satisfactory network performance can be received.We summarize in Fig. 12 the optimal throughput performance of the IC-IoT with different traffic loads, where we set N = 18 and M = 3. Fig. 12(a) shows that the optimal setting of α for throughput maximization becomes larger if the buffer space is expanded under the BS policy, or the relay buffer is allocated with more space under the BA policy.It indicates that if there is a larger buffer space used for storing the packets from other devices, it is reasonable to adjust the ratio of executing the Source-to-Relay operation to a higher value.In Fig. 12(b) and (c), we can see that when the network traffic load is light, e.g., λ e = {0.05,0.1}, the maximal achievable throughput under the BS policy can be higher than that under the BA policy, and meanwhile, there is little difference between the corresponding delay performance under the two policies.As the traffic load becomes heavy, the BA policy with B S = 3 and B R = 7 outperforms all other buffer space management policies in terms of both throughput and delay.It demonstrates that the BA policy with a larger relay buffer space reservation can cope with the heavy network load much better.
We finally plot Fig. 13 to show the variation of network performance as the IC-IoT scales up, where we set B = 10 for the BS policy, B S = 3 and B R = 7 for the BA policy, λ e = 0.2 (packets/slot), and α = 0.3.We consider two cases: 1) device density fixed, i.e., the number of devices and the network area (the number of cells) scale up proportionally, and we set the device density N/M 2 = 2 and 2) device density increased, i.e., the network area is fixed and only the number of devices scales up.We can observe from Fig. 13 that the throughput and delay performances deteriorate for all the cases.For the device density fixed case, the reason is that as the network scales up, the probability that the destination is within the same cell of the source or the relays that are storing its packets becomes lower.For the device density increased case, it is because as the number of devices in a cell gets larger, the probability of each device getting channel access becomes lower.

VII. CONCLUSION
In this article, we have investigated the fundamental performance of the buffer-limited IC-IoT under two buffer space management policies, i.e., BS and BA.By analyzing transition cases of the BOS and deriving its limiting distribution based on the MC theory, we have developed theoretical performance modelings that enable the throughput and expected end-to-end delay of the IC-IoT to be evaluated accurately.Simulations have been implemented to demonstrate the efficiency of the performance modelings.From this study, some interesting findings that would be helpful for the practical IoT configuration and implementation are summarized as follows.
1) The achievable performance of an IC-IoT system is influenced by the buffer space management policy adopted as well as its compatibility with the system parameter settings.The BS policy and BA policy present different performance characteristics in terms of per-flow throughput and expected end-to-end delay.
As the network load increases, the throughput under the BS policy first increases and then decreases (unimodality), while the throughput under the BA policy monotonically increases (monotonicity); the expected delay under the BS policy first increases and then linearly decreases, while the expected delay under the BA policy first increases, then decreases and tends to a constant.2) When the system traffic load is light, the throughput performance under the BS policy can be superior to that under the BA policy, due to a more adequate and flexible utilization of the buffer space.However, as the traffic load gets heavier, the throughput improvement in the IC-IoT is mainly guaranteed by the multiuser diversity gain, and thus, it is more essential to reserve sufficient space for the relay buffer to support the store-carry-forward function.Therefore, when the traffic load is heavy, the BA policy, which allocates a relatively large space to the relay buffer, can outperform the BS policy in terms of both the throughput and delay performance.
3) The throughput performance can be improved by equipping IoT devices with a larger buffer space, while it deteriorates when either the network topology scales up or the device density increases.In addition, to receive a satisfactory throughput performance, the parameter α in the 2HR-OR scheme is a critical factor that needs to be appropriately set according to the system configuration.Under the BS policy, the optimal setting of α increases as either the buffer space is expanded or the traffic load gets heavier; while under the BA policy, the optimal setting of α is always less than 1/2, and it becomes larger as the relay buffer is allocated with more space.
APPENDIX A PROOF OF LEMMA 1 Note that once device S gets the chance to conduct the Source-to-Destination or Source-to-Relay operation, the HoL

Algorithm 1 : 2 S 3 - 6 ); 3 if S has exogenous packets in its buffer then 4 S transmits such a packet to D; 5 else 6 Sthen 8 9 S
Two-Hop Relaying Opportunistic Routing Algorithm 1 if D is within the transmit range of S then executes Source-to-Destination operation (lines remains idle; 7 else if There exist other devices within the transmit range of S With equal probability, S selects one device R as the receiver; chooses a value x from [0, 1] uniformly, α is a predetermined value that satisfies 0 < α < 1; if x ≤ α then S executes Source-to-Relay operation (lines 12-15); if S has exogenous packets in its buffer then S transmits such a packet to R; else S remains idle; else S executes Relay-to-Destination operation (lines 18-21); if S has packets destined to R in its buffer then S forwards such a packet to R; else S remains idle; respectively. 2α (resp. 1 − α) represents the ratio of executing the Source-to-Relay (resp.Relay-to-Destination) operation if S gets the channel access but cannot execute the Source-to-Destination operation, i.e., p sr /p rd = α/(1 − α).

Fig. 3 .
Fig. 3. Transition cases from a general state i, j .
Case 3 ( k, l → k, l − 1 ): S delivers the HoL packet in one of its relay queues to the destination, and then no exogenous packet arrives at S. Case 4 ( k, l → k + 1, l ): No packet leaves the source queue, no packet enters or leaves the relay queues, and then a new exogenous packet arrives at S and enters its source queue.Case 5 ( k, l → k+1, l+1 ): Another device (except the source of S) delivers a packet to S and the packet enters the corresponding relay queue, and then a new exogenous packet arrives at S and enters its source queue.Case 6 ( k, l → k + 1, l − 1 ): S delivers the HoL packet in one of its relay queues to the destination, and

Fig. 4 .
Fig. 4. State transition diagram of the buffer occupancy process.

Fig. 5 .
Fig. 5. Snapshot of the IC-IoT scenario used in the simulations.

Fig. 6 .
Fig. 6.Validation of per-flow throughput in IC-IoT under BS and BA policies.

Fig. 7 .
Fig. 7. Validation of expected end-to-end delay in IC-IoT under BS and BA policies.