An Efficient Reliable Communication Scheme in Wireless Sensor Networks Using Linear Network Coding

We address the modeling and design of linear network coding (LNC) for reliable communication against multiple failures in wireless sensor networks (WSNs). To fulfill the objective, we design a deterministic LNC scheme RDLC based on the average number of path failures simultaneously happening in the network other than the maximum number of path failures. The scheme can significantly improve the network throughput comparing with the traditional approaches. In our study, we also investigate the potential of random linear code RRLC for providing reliable communication in WSNs and prove the low bound of the probability that the RRLC can provide the reliable communication. Finally, extensive simulation experiments have been conducted, and the results demonstrate the effectiveness of the proposed LNC schemes.


Introduction
In recent years, wireless sensor network (WSN) has attracted significant attention for future generations of wireless applications in industry, agriculture, and military [1][2][3][4][5].Despite its salient potentials, there are still many challenges to be addressed.In this paper, we will investigate how to provide reliable data transmissions in WSNs, which is very challenging because not only the wireless medium is vulnerable to severe channel fading and interference but also the sensor node always faces to energy exhaustion and physical damage.
Clearly, how to provide reliable communication in WSNs can be studied from multiple layers, including the physical layer and the MAC layer [6][7][8][9].In this work, we will focus on the network layer and transport layer.Particularly, we will study how to provide reliable communication in WSNs against loss of data packets.
To provide reliable communication against node or link failures, there are two kinds of traditional approaches [10]: the proactive recovery and the reactive recovery, which aim at recovering the data transmission when node or link failures happen.The proactive recovery approaches can recover data transmission immediately when a link or node failure occurs, because it reserves the bandwidth (in backup paths) between the source node and the destination node in advance and the data flow is simultaneously transmitted on both primary paths and backup paths.On the other hand, the proactive recovery approaches do not provide any immediate recovery in advance.When the failure occurs on the routing paths of the data flow, the affected flow will be retransmitted to the destination by using available bandwidth in the network.Therefore, although the proactive recovery approaches can recover data transmission immediately when the link or node failures happen, network resources (e.g., bandwidth on the backup paths) are wasted when no failure happens.For the proactive recovery approaches, although network resources are used efficiently (no network resource is reserved in advance), the procedure of transferring the data traffic from the failed paths to the new routing paths incurs a considerable delay to data communications.
Following its success in maximizing network throughput [11][12][13][14][15], linear network coding (LNC) has recently been shown to be a promising approach that can achieve reliable communication with much better efficiency, because it can be used to provide protection in a proactive manner with the bandwidth cost in a reactive manner [16][17][18][19][20]. LNC has International Journal of Distributed Sensor Networks been first introduced by Kamal [16,19] to provide 100% protection against single link failures in optical network.Recently, the design of reliable communication based on LNC has attracted an increasing amount of attention in optical networks [16], wireless networks [18], and hybrid wireless-optical access networks [20], respectively.However, in these studies, the LNC scheme, which can generate large number of linear combinations of original data packets to provide reliable communication when link or node failures happen, is designed according to the maximum number of failures ( f max , i.e., the worst case) happening simultaneously.In this case, with such LNC schemes, the destination can receive sufficient coded data packets and recover the original data packets, as long as the number of failures happening simultaneously is no more than f max .However, the number of failures happening simultaneously in WSNs varies at different times in practice.When the number of failures happening simultaneously in the network is less than f max , the network throughput decreases because the capacity of the WSN is wasted by the redundant coded data packets transmitted in the WSN.
Therefore, our key idea is to increase the number of original data packets transmitted and recovered in the transmission rounds with large number of failures happening simultaneously, by utilizing the redundant coded data packets transmitted in the transmission rounds with fewer failures happening simultaneously in the network to improve the network throughput.Figure 1 gives an example to compare the network throughput that can be achieved by LNC scheme based on the maximum number of failures f max and the LNC scheme based on the average number of failures f exp (denoted in Section 2.1).Specifically, in the WSN, there are 4 edgedisjoint paths between the source S and the destination (sink) D. Suppose that f max = 2 and f exp = 1.Without loss of generality, we assume that 2 path failures happen in time slot 1 and no failure happens in time slot 2. Different LNC schemes are shown in Figures 1(a) and 1(b), in which the notation "S 1 : x 1 + x 2 " on a link denotes the link is used to transmit a coded symbol x 1 + x 2 at time slot 1.Moreover, for LNC schemes shown in both Figures 1(a) and 1(b), the coded data packets transmitted on the links belonging to the same path are same in given time slot.
Since the f max = 2, in Figure 1(a), the LNC scheme designed based on f max can ensure that the destination can decode and recover even if 2 path failures happen.However, no failure happens in time slot 2, which decreases the network throughput because the capacity of the WSN is wasted by the redundant coded data packets transmitted in time slot 2. On the other hand, in Figure 1(b), the LNC scheme was designed based on f exp , in which part of original data packets sent previously is still encoded into the following time slots.In this case, the network throughput can be improved by utilizing the redundant coded data packets transmitted in time slot 2. Specifically, with different LNC schemes, the sink can recover 4 original data packets in 2 time slots (i.e., the achieved network throughput is 2) in the case shown in Figure 1(a), while the sink can recover 6 original data packets in 2 time slots (i.e., the achieved network Sink Source The LNC scheme based on the maximum number of failures Sink Source The LNC scheme based on the average number of failures throughput is 3) in the case shown in Figure 1(b).Obviously, the LNC scheme based on the average number of path failures can significantly improve the network throughput.
In this paper, we will design an efficient LNC scheme based on the average number of path failures, to provide reliable communication in WSNs.It must be noted that our study in this paper is different to our previous work in [21], where we have investigated the LNC design for providing N + k protection in the wireless mesh networks.Specifically, as we can see from the rest of the paper, the main differences include the following.
Firstly, different LNC designs are given to provide reliable communication in this paper.The deterministic LNC scheme proposed in Section 3 achieves the network throughput N = L − f exp (L denotes the number of edge-disjoint paths between the source and the destination and f exp is the expected number of path failures per time slot), while the LNC scheme proposed in [21] does not ensure that the network throughput can achieve N = L − f exp .Therefore, the deterministic LNC scheme proposed in this paper can achieve higher network throughput than our previous work in [21].Moreover, in this paper, we also investigate the potential of standard random LNC to thwart path failures in WSNs and analyze the lower bound of the probability that a random LNC can provide reliable communication.On the other hand, the work in [21] only considered the deterministic LNC design.
Secondly, comparing with the work in [21], we not only give the theoretical design of deterministic LNC scheme and random LNC scheme but also conduct considerable simulations with four parameters to demonstrate the effectiveness of the proposed LNC schemes, from view of both network throughput and recovery delay.We also show the impact of the size of finite field on the performance of the proposed random LNC schemes, which is not investigated in [21].
The rest of the paper is organized as follows.Section 2 describes the system models and problem description.In Section 3, we design a deterministic LNC scheme to provide reliable communication in WSNs and give the theoretically analysis to show the achieved network throughput.The analysis of the usage of random LNC to realize reliable communication in WSNs is shown in Section 4. Simulation results are given in Section 5. Finally, we conclude the paper in Section 6.

Reliable Communication against Multiple Failures in WSNs Based on LNC
In this section, we will describe the problem studied in this paper.Specifically, we first introduce the network model.We then give the description of the reliable communication problem.

The Network Model.
In this paper, we consider a multihop wireless sensor network as a directed acyclic graph G = (V , E), where V is the set of sensor nodes and E is the set of edges.We assume that each edge in G has the same unit capacity.Note that the capacity of different edges can be different in practice.However, we can always convert an edge with a certain capacity C (a nature number) data units to C edges with unit capacity.Suppose that all data packets have the same unit size.There are one source S, one destination D and L edge-disjoint paths between them.We assume that it will cost one time slot that the source sends L coded packets through L edge-disjoint paths and gets the feedback from the destination.
Although the wireless medium is vulnerable and the sensor node always faces energy exhaustion and physical damage, LNC can be designed to tolerate the link or node failures and provide reliable communications in WSNs.Specifically, L coded data packets are generated at the source node by linearly combining original data packets and transmitted through L edge-disjoint paths in each time slot.Since there will be different number of edge-disjoint paths failing simultaneously in different transmission rounds, we denote p i as the probability that i edge-disjoint paths are failed simultaneously, where 1 ≤ i ≤ L. Therefore, f exp = L i=1 ip i is the expected number of path failures per time slot.Let Suppose that the data stream arrive rate is N data packets per time slot; the data packets arrived are firstly buffered at the source S, waiting for encoding and transmission towards the destination D. We will design an LNC scheme to protect the data stream with arrive rate N.

The LNC Scheme.
In practical LNC schemes, the source node first divides the whole file into fix-size original packets.Then, the coded packets can be generated by encoding the original packets together.Moreover, each coded packet in the network corresponds to an encoding vector, which consists of the coding coefficients that it is produced with respect to the set of original packets.When the destination node received sufficient coded packets, it can decode and recover the original packets according to their encoding vectors.
Due to the limited computational capability of the sensor nodes in WSNs, we assume that the intermediate sensor nodes simply store and forward encoding packets.Such assumption is practical because coding operations require extra computation capability which imposes the processing overheads and may slow down the switching speed.

Problem Description.
To improve the network throughput, we design the LNC schemes based on the expected number of path failures per time slot ( f exp ).However, since the number of path failures may exceed f exp in some time slots, which may cause that the destination cannot decode the received coded data packets, it is desirable to utilize the redundant coded data packets transmitted in the transmission rounds with fewer failures (< f exp ) to improve the network throughput.
Therefore, in this paper, we aim to design an LNC scheme providing reliable communication in WSNs to achieve network throughput N = L− f exp , in which f exp is the expected number of path failures per time slot.We will show in the rest of the paper that the original data packets can be recovered by the destination and the network throughput N can be achieved, if only the average number of failures is no more than f exp .

Notations.
To facilitate further discussions, we summarize main notations to be used throughout the rest of the paper in Table 1.We also denote the L × iN dimensional matrix Λ i as follows: where λ i1 / = λ i2 , for all i 1 / = i 2 .

Reliable Communication Using Deterministic Linear Network Coding
In this section, we provide a deterministic LNC scheme to provide reliable communication (RDLC) for multiple failures in WSNs.
We assume that a buffer exists in the source to buffer the newly arrived data packets and parts of original data packets A finite field of size q, over which the LNC is defined A set of vector composed by i th to j th row vectors of matrix B [B] m,n i, j A matrix composed by the i th to j th row and m th to The i th row vector of matrix B [B] i, j The matrix composed by the i th to j th row vectors of matrix B [V] The matrix formed by vectors in the set V as its rows Rank (B) The rank of a matrix B m i, j The j th , j ≤ N original data packet arrived at time slot i The number of edge-disjoint paths between the source and the destination Linear span of a set of row vectors of a matrix Dim (•) Dimension of a linear space P(A) The probability that condition A is satisfied arrived previously.We also assume that the destination has a buffer to buffer the coded data packets which have not been decoded.At the end of each time slot, the destination sends an acknowledgment to the source in order to report the number of coded data packets received in this time slot.Then, according to the number of coded data packets received by the destination in the previously time slots, the source first removes some original data packets arrived perviously in its buffer and then generates L new coded data packets by encoding the original data packets arrived previously and the newly arrived data packets together.After that, the source sends the L new coded data packets to the destination.At the end of time slot t, for all t ≥ 1, if the destination has totally received no less tN coded data packet, it can decode and recover the tN original data packets, clear its buffer and send an acknowledgment to notify the source that all the received coded data packets are decoded.We denote the N original packets arrived at time slot t as M t = {m t,1 , . . ., m t,N }.The details of RDLC scheme is shown in Algorithms 1 and 2.
Suppose that c t denotes the number of coded data packets received by the destination at the end of time slot t; we have c t ≤ L, for all t > 0. Let ( Next, we will prove that the destination can decode and recover the TN original data packets once it receives no less than TN coded data packets.Lemma 1.When T = 1, the destination can decode and recover the N original data packets.
Proof.When T = 1, the destination can receive c 1 ≥ N coded data packets.The global encoding vector of each coded data packets is one row vector in the matrix Λ 1 .According to the matrix Λ 1 , any N rows can construct a square N × N dimensional Vandermonde matrix.Since λ i / = λ j , for all i / = j, the determinant of the N × N dimensional Vandermonde matrix is not equal to 0. Hence, the destination receives N coded data packets with N linearly independent global encoding vectors.Therefore, the destination can decode and recover the N original data packets.Lemma 2. When T = 2, the destination can decode and recover the 2N original data packets.
Proof.When T = 2, the destination receives no less than 2N coded data packets.We suppose that it receives c 1 coded data packets in time slot 1.Without loss of generality, let these coded data packets be [ . Since the destination receives no less than 2N coded data packets we can select 2N − c 1 coded data packets received by the destination in time slot 2. Without loss of generality, let these coded data packets be [ . Therefore, the matrix Y 2 composed by global encoding vectors of the coded packets as its rows can be represented by Next, we will prove that Rank( 1,c1 in the left upper corner of the matrix Y 2 is c 1 × c 1 dimensional and has full rank.Therefore, each column vector in [Λ 1 ] c1+1,N 1,c1 can be written as a linear combination of the column vectors in [Λ 1 ] 1,c1 1,c1 .Since the (2N − c 1 ) × c 1 dimensional block matrix in the left lower corner of the matrix Y 2 is zero matrix, the matrix Y 2 can be transformed to be matrix Y 2 by column transformation: and det(Y 2 ) = det(Y 2 ). . . .
Send each coded packet m t,i with encoding vector i through path i to the receiver, ∀i ∈ {1, . . ., L}; end if end if Algorithm 1: Encoding at the source.

At time slot t:
Received c t coded data packet in time slot t; If t i=1 c i ≥ tN then Extend each received encoding vector v i, j to its corresponding global encoding vector v i, j with length tN by adding (t − i)N zeros, i.e., v i, j = [v i, j 0 1×(t−i)N ]; Suppose that the matrix Y T is composed by the global encoding vectors of the received TN coded packets as its rows and the matrix M is composed by corresponding coded packets as its rows; Decode and recover the tN original data packets as follows: Clear the its buffer and send a ACK(−1) to the source; else Store the c t coded data packet to its buffer; Send a ACK(c t ) to the source; end if Algorithm 2: Decoding at the destination.

Theorem 3. The destination can decode and recover the TN original data packets as long as it totally receives no less than TN coded data packets at the end of T time slots.
Proof .According to Lemmas 1 and 2, the theorem holds when T = 1, 2. When T = t + 1, t > 1, it means that j i=1 c i < jN, for all j ≤ t and t+1 i=1 c i ≥ (t + 1)N.When t+1 i=1 c i = (t + 1)N, that is, c T = TN − t i=1 c i , without loss of generality, let these coded data packets be International Journal of Distributed Sensor Networks The matrix Y T composed by the global encoding vectors of these TN coded packets as its rows can be represented by Similarly to the proof of Lemma 2, the block matrix 1,c1 in the left upper corner of the above matrix is c 1 × c 1 dimensional and has full rank.Therefore, each column vector in [Y T ] c1+1,TN 1,c1 can be written as a linear combination of the column vectors in [Λ 1 ] 1,c1 1,c1 .Since the (TN − c 1 ) × c 1 dimensional block matrix in the left lower corner of the matrix Y T is zero matrix, the elements in between 1 to c 1 row and c 1 + 1 to TN − c 1 will be transformed to zeros in matrix Y T by column transformation.And then by using the full rank block matrix [Λ 2 ] 1,c2 1,c2 , the elements in between c 1 + 1 to c 1 + c 2 row and c 1 + c 2 + 1 to TN − c 1 will be transformed to zeros in matrix Y T by column transformation.
By step to step column transformation, the matrix Y T can be finally transformed to be Y T : Obviously, det 1,ci is a square Vandermonde matrix and x i / = x j , for all i / = j, we have det([Λ i ] 1,ci 1,ci ) / = 0, for all i ∈ {1, . . ., T}.Therefore, det(Y T ) / = 0. Since the column transformation on a matrix does not change the rank of the matrix, the matrix Y T has full rank, that is, the destination can decode and recover TN organical packets.
When c T > TN − t i=1 c i , the destination can randomly select TN − t i=1 c i coded data packets.Together with the t i=1 c i coded packets received from time slot 1 to time slot t, the destination have TN coded packets.Similarly to the above proof, we can have the destination that can decode and recover TN original packets.

Corollary 4.
If the average number of path failures is no more than f exp , then the network throughput N = L − f exp can be achieved.
Proof.When the average number of path failures is no more than f exp , we have the average number of coded packets received by the destination in each time slot is L − f exp .Therefore, there exists a time slot T that the destination totally receives T(L − f exp ) coded data packets at the end of T time slots.Since N = L − f exp < L − f exp , the destination totally receives T(L − f exp ) > TN coded data packets at the end of T time slots.Therefore, according to Theorem 3, we have that the destination can decode and recover the TN original data packets, that is, the network throughput N = L − f exp is achieved.

Reliable Communication Using Random Linear Network Coding
In the previous section, we have discussed how to construct linear network code at the source node in a deterministic manner to provide the reliable communication.In practice, random linear coding has been widely used in the literature [15,22], because of the simplicity of the coding scheme.With random linear coding, random linear combinations of the packets can be forwarded by a node, which the node received previously, to outgoing edges.It has been proved in pervious work that such a simple approach can obtain valid linear codes for multicast with probability (1 − d/q) η , where η is the number of edges with associated randomized coefficients, q is the size of the finite field, and d is the number of destination nodes.
In this section, we investigate the behavior of the random linear coding, when it is applied to the reliable communication problem we discuss in this paper.The usage of such linear code is similar to the one we discussed in Section 3. The coding operations are only done at the source node and destination node.The major difference is that, instead of computing the coding matrix Y i at the source node, the elements of L × iN dimensional coding matrix B i for time slot i are randomly chosen from the finite field F q according to the number of coded packets received by the destination in each time slot.We referred to such random linear coding scheme as reliable random linear coding RRLC.Since the destination does not need to send an acknowledgment to notify the source that the number of coded packets received in each time slot, the communication overhead of RRLC, is smaller than the RDLC.We also show that the RRLC can ensure that the destination can recover the iN original packets when it receives iN coded packets with high probability.
Specifically, the L coded data packets sent during time slot i can be represented by Suppose that the number of coded packets received within time slot i by the destination node d is c i , without loss of generality, let these coded data packets be Suppose the ( i w=1 c w ) × (iN) dimensional matrix B i is Therefore, the total coded packets received by the destination node D during i time slots can be represented by From above theoretical analysis, the destination D can decode and recover the set of iN original packets i t=1 M t , if and only if Rank(B i ) = iN.
Next, we will give the lower bound of the probability that the destination D can decode and recover the original packets once it totally receives no less than iN coded packets after time slot i.

Lemma 5. If i
w=1 c w ≤ i N, for all i ≤ i, the probability that the Proof.Obviously, the matrix B i has full rank, if and only if We first give the theoretical analysis on the first c 1 row vectors in the matrix B i .Suppose that the first j, ( j ∈ {1, . . ., c 1 − 1}) rows of B i are selected and , for all j {1, . . ., j}, that is, Rank([B i ] 1, j ) = j, for the j + 1th row vector of the matrix B i , the total number different vectors can be selected from the finite filed is q N , because [B i ] j+1 , forall j ∈ {1, . . ., c 1 − 1} that have the first N elements randomly selected in finite filed F q and other elements are 0. Let σ j+1 be the number of vectors which can be selected as the j + 1th row vector of the matrix Similarly, we then give the probability that the matrix B i has full rank.
Suppose that the first j, ( j , for all j ∈ {1, . . ., j}, that is, Rank([B i ] 1, j ) = j, for the j +1th row vector of the matrix B i , the total number different vectors can be selected from the finite filed which is q wN , because [B i ] j+1 for all j ∈ { w−1 k=1 c k +1, . . ., w k=1 c k − 1} have the first wN elements randomly selected in finite filed F q and other elements are 0. Let σ j+1 be the number of vectors which can be selected as the j + 1th row vector of the matrix Let σ be the number of matrix B i that can be constructed in the finite field which satisfies the condition shown in (14).We have The total number of different matrix B i with dimension ( i k=1 c k ) × (iN) is q i k=1 kckN , because there are i k=1 kc k N elements randomly selected in finite filed F q and other elements are 0 in matrix B i .
Therefore, the probability that the matrix B i has full rank is Theorem 6.If the total number of coded packets received by destination d during the first i time slots is no less than iN, that is, i w=1 c w ≥ iN and for all i < i, i w=1 c w < i N, the lower bound of the probability that can decode and recover the set of Proof.The destination node D can decode and recover the set of iN original packets i t=1 M t , if and only if Rank(B i ) = iN.Since i w=1 c w ≥ iN and for all i < i, i w=1 c w < i N, we have c i ≥ iN − i−1 w=1 c w .Obviously, if the first iN row vectors are linearly independent, Rank([B i ] 1,iN ) = iN, we have Rank(B i ) = iN.Therefore, the probability that Rank(B i ) = iN is lower bounded by the probability that Rank([B i ] 1,iN ) = iN.According to matrix [B i ] 1,iN , the number of row vectors in it belonging to time slot i is c i = iN − i−1 w=1 c w .Therefore, from the Lemma 5, the probability that Rank( 1 − 1 q wn− j+1 .(18) Since the probability that Rank(B i ) = iN is lower bounded by the probability that Rank(

Performance Evaluation
In this section, we conduct simulations to compare the scheme that without considering reliable communication (denoted as Unreliable Communication Scheme) the linear coding schemes are designed for recovering from maximum number of edge failures and the proposed linear coding schemes.
In the transmission scheme without network protection, the source sent totally L original packets along the L paths between the source node and the destination node in each time slot, until the destination node receive all the L original packets.Since each path may fail in each time slot, the destination may wait for some time slots to receive all the L original packets.
In the linear coding schemes designed for recovering from maximum number of edge failures, the scheme codes L − f max original packets in each time slot and makes sure that the destination can decode all of them even if the maximum number of edge failures happens in one time slot (i.e., the worst case).However, such a scheme will waste lots of throughput of the network, because the number of edge failures probably is less than the maximum number of edge failures.We denote such schemes as LCW scheme.
Therefore, in our coding scheme, we code the packets sent in the pervious time slots with the new packets together which can fully utilize the available paths in the network to achieve higher throughput.To achieve this goal, in the proposed linear coding scheme, the destination receives coded packets instead original packets in each time slot which may not be decoded immediately.Therefore, the destination may wait for some time slots to receive enough coded packets to decode and recover all the original packets sent by the source node in the past time slots.However, we will show in this section that we can decrease a bit of throughput to achieve a much low decoding delay.
The objectives of the simulation conducted in this work are as follows.
(i) To compare the throughput achieved when using different schemes under different parameter settings.
The throughput is referred to as the total number of original packets recovered (or reviewed) in the past time slots divided to the total number of time slots.
(ii) To compare the recovery delay using different schemes under different parameter settings.The delay will cause by different schemes to receive (or decode and recover) all the original packets sent by the source node in the past time slots.

Simulation Setup.
We have four parameters in our simulations.
(i) The number of paths between the source node and the destination node, L, which varies from 10 to 20.
(ii) The maximum number of paths between the source node and the destination node which can simultaneously fail, f max = αL , in which α varies from 0.2 to 0.7.
(iii) The number of original packets coded (or sent) in each time slots, N, which varies from 2 to L − F max /2 − 1.
(iv) The size of finite field, q = 2 r , in which r varies from 1 to 7.
In a network G, we suppose that there are L edge-disjoint paths between the source node S and the destination node D. In each time slot, there may be f , 0 ≤ f ≤ f max edges failure and the packets transmitted on these paths cannot be received by the destination node D. In the simulation, we randomly select f in {0, . . ., f max } and then select f paths in the L paths which will fail in the following one time slot.
For each combination of parameters L, f max , N and q, we generate 100 instances.For each instance, we evaluate the performance of the data transmission using unreliable communication scheme, the linear coding schemes designed for recovering from maximum number of edge failures, and the proposed linear coding schemes.

Simulation Results
. We compare the network throughput and the recovery delay of the proposed RDLC and RRLC schemes with LLW scheme and the unreliable communication scheme.
In Figure 2(a), the throughput of all the four schemes increases with the increase of the number of edge-disjoint paths between the source node and the destination node.The reason is that the more the number of edge-disjoint paths exist between the source node and the destination node the more packets can be transmitted successfully to the destination.The throughput of the LLW scheme is higher than the unreliable communication scheme, because the LLW scheme exploits the LNC to ensure that all the original packets sent in one time slot can be recovered by the destination node which limit the number of original packets transmitted in each time slot.On the other hand, the unreliable communication scheme will transmit the same set of original packets many times to make sure the destination node can successfully receive all of them.The throughput of the proposed RDLC and RRLC schemes are much higher (more than 25% compared with LLW and more than 40% compared with the unreliable communication scheme when L grows sufficiently large), because the proposed schemes fully utilize the unfailed paths to transmit coded packets.Since the number of original packets transmitted in each time slot is the same in the proposed RDLC and RRLC schemes, the two schemes has the same throughput.
In Figure 2(b), the recovery delay of the unreliable communication scheme is higher than the other three schemes.The unreliable communication scheme will transmit the same set of original packets many times to make sure the destination node can successfully receive all of them.The recovery delay of the LLW scheme is always one time slot because a limited number of original packets are transmitted in each time slot to make sure the destination can decode and recover them in one time slot.The recovery delay of the proposed RDLC and RRLC schemes are between the unreliable International Journal of Distributed Sensor Networks communication scheme and the LLW scheme.Therefore, we can observe that the proposed RDLC and RRLC schemes can achieve highest throughput and moderate recovery delay.The figure also shows that the recovery delay of the RRLC scheme is higher than the recovery delay of the RDLC scheme.The reason is that according to the theoretical analysis a destination may not be decode and recover the original packets when using the RRLC scheme, even if it totally received more than i * N coded packets during the past i time slots.Therefore, when using the RRLC scheme, the destination will wait more time slots to achieve the same throughput as the RDLC scheme.
In Figure 3(a), the throughput of all the four schemes decreases with the increase of α, because the number of edgedisjoint paths between the source node and the destination node is fixed but the number of failure paths increases.We can observe that the throughput of LLW scheme will be lower than the unreliable communication scheme when α grows sufficiently large.The reason is that when α grows sufficiently large, the throughput of of LLW scheme L − f max will decrease to zero, while the unreliable communication scheme can exploit unfailed paths to transmit packets.The throughput of the proposed RDLC and RRLC schemes are much higher (more than 60% compared with the unreliable communication scheme when α grows sufficiently large).
In Figure 3(b), the recovery delay of the proposed RDLC, RRLC schemes, and the unreliable communication scheme increase with the increase of α.Moreover, The recovery delay of the unreliable communication scheme is higher than the other three schemes.The recovery delay of the LLW scheme is always one time slot because a number of original packets transmitted in each time slot decreases when the α increase to make sure the destination can decode and recover them in one time slot.Thirdly, in Figure 4, we set L = 16, q = 2 2 , α = 0.4, In Figure 4(a), the throughput of the proposed RDLC, RRLC schemes increases with the increase of N, because the throughput of the proposed RDLC, RRLC schemes can achieve N only if N is no more than the total number of paths minus the average number of path failures each time slot.In our simulation, the condition is that N ≤ L − f max /2.Therefore, in Figure 4(a), the throughput of the proposed RDLC, RRLC schemes can achieve N. Obviously, N does not have impact on the throughput of the unreliable communication scheme and the LCW scheme.We can see in Figure 4(a) that the throughput of the proposed RDLC, RRLC schemes outperforms the other two schemes when N is sufficiently large.
Figure 4(b) shows that the values of N also do not have impact on the recovery delay of the unreliable communication scheme and the LCW scheme.On the other hand, the recovery delays of the proposed RDLC, RRLC schemes increase with the increase of achievable throughput.However, by selecting a suitable value of N, a transmission can achieve a higher throughput with a lower delay compared with the unreliable communication scheme and the LCW scheme.
In Figure 5(a), the throughput of the proposed RDLC, RRLC schemes, the unreliable communication scheme, and the LCW scheme do not change because the throughput of them does not related with the size of the finite field.However, as we showed in Section 4, the size of the finite field has impact on the decoding probability that the destination to recovery the original packets when using the RRLC scheme.Therefore, the increase of the size of the finite field will increase the decoding probability and reduce the recovery delay.The trends of the recovery delay of the RRLC scheme shown in Figure 5  theoretical analysis.The recovery delay of the other three schemes does not related with the size of the finite field.

Conclusion
In this paper, we have explored the power of LNC to provide reliable communication for multiple failures in WSNs.The key idea is to design the LNC scheme based on average number of path failures, in which part of original data packets sent previously is still encoded into the following time slots, in order to improve the network throughput by utilizing the redundant coded data packets transmitted in the transmission rounds with fewer failures happening simultaneously in the WSN.Specifically, we first give the design of deterministic LNC scheme based on the average number of path failures, by which the network throughput is significantly improved comparing with the traditional approaches designed based   on the maximum number of path failures.We also have investigated the behavior of the random LNC, when it is applied to the reliable communication problem studied in this paper.We have given the performance evaluation, which demonstrates the effectiveness of the proposed LNC schemes.
(a) are consistent with our International Journal of Distributed Sensor Networks

Table 1
At time slot t:N original data packets M t = {m t,1 , . . ., m t,N } are arrived and stored into its buffer; if t = 1 then Generate L coded packets: Λ 1 [M 1 ] and send them to the destination through L edge-disjoint paths;