Network Coding
Network Coding
net/publication/255505013
Article
CITATIONS READS
0 2,003
1 author:
Louai Al-Awami
King Fahd University of Petroleum and Minerals
11 PUBLICATIONS 72 CITATIONS
SEE PROFILE
Some of the authors of this publication are also working on these related projects:
All content following this page was uploaded by Louai Al-Awami on 04 June 2014.
Louai Al-Awami
Queen’s University
Abstract
1
Contents
1 Introduction 3
2 Mathematical Formulation 6
2.1 Encoding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
2.2 Decoding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
4 Summary 20
2
1 Introduction
In today’s networks coding is done at the end nodes while intermediate nodes
route packets without altering their contents. Network coding changes this
folklore by allowing intermediate nodes to combine incoming packets into one
or many outgoing packets. The main goal behind doing so is to exploit more
potential for increasing the information content of each transfer. This in
be eliminated by combining both packets and sending them during the third
transfer. Since node A and node B have part of the information, they can
extract the rest of it from the combined packet.
3
compared to traditional routing. The following are among the most impor-
tant ones:
not only from the perspective of the nodes employing it, but also to the
whole network since reducing the number of transfers means that there
is more bandwidth available for other nodes to use. Another benefit
which can be seen in the example is reducing the delay since node B
has received the data during the third transfer using network coding
as opposed to waiting till the fourth transfer when using traditional
routing.
4
enough number of packets regardless of which packets. This flexibility
helps in tackling different problems more easily, e.g acknowledgments
and error correction. This will be illustrated when describing an appli-
ARQ on the other hand, achieves optimal rate at the cost of delay.
Network coding can optimize both delay and rate resulting in a better
reliability scheme.
This can be seen from different angles. Since the information about
each packet is distributed on different nodes, packets can be acquired
from different nodes even when the node to which the packet corre-
sponds disappears. This is going to be clearer when considering using
from the fact that any packet has been used to construct many en-
copies of every packet can be retrieved and used to check the integrity
5
2 Mathematical Formulation
coding as it has been shown that the bestbenefits of network coding can be
achieved with linear codes [4]. At the end of the section we will present an
2.1 Encoding
let g1 , g2 , ..., gn be a set of coefficient drawn from the field F2s . For example,
n
X
X= gi M i
i=0
n
X
Xk gi Mki
i=0
6
called the encoding vector, and the encoded information X, called the infor-
mation vector. The receiver use the encoding vector to decode the informa-
tion vector to get the original information.
2.2 Decoding
Clearly, if we have some equations which are dependent, we will need m > n.
This problem is solved by choosing the right linear code as we will see next.
To clarify how decoding can be done, let’s see one way of doing it. Each
node can have a decoding matrix that contains encoded words received so
far as well as code words sent by the node itself, in addition to the encoding
coefficients.. This matrix can be viewed as a system of equations. Now, we
can perform Gaussian elimination on the matrix to solve for the unknowns,
i.e. M1 , M2 , ..., Mn .
This brings many design issues regarding size of decoding matrix and the
delay till enough independent vectors are received to decode.
Delay: It is obvious that decoding will result in some delay because received
7
to be decoded. But note that it is not always necessary to wait for
all packets to decode as whenever Gaussian elimination results in a
raw of the form (ei , Mi ) where ei is the vector with all zeros except
in the ith location. Thus in the worst case the average delay over
important to keep in mind that the size of the matrix imposes a tradeoff
since larger matrix means larger generation and hence longer history
that speeds decoding and boosts throughput but at the cost of bigger
memory requirements.
8
2.3 Practical Implementation
It might seem difficult to implement network coding. In this part one possible
approach will be discussed. The approach might not be the best, but it is
simple and enough to illustrate the main idea.
such that the original symbols can be recovered from a subset of the encoded
symbols.
There is a clear harmony between fountain codes and network coding
plest coding scheme in the fountain family. Let’s see how the encoding and
decoding is done for this code.
(s1 , s2 , ..., sK ) each with length l. Then, we prepare each encoded packet
sent out using a linear combination of all original packets. Let tn be the nth
9
generated packet. tn can be encoded as
K
X
tn = sk G(k)
n
k=1
where
G(k)
n = a randomly generated bit (0 or 1)
The sum over all packets is a bitwise modulo 2 sum which can be cal-
culated using simple bitwise XOR. Now, for each encoded packet tn , a new
(1) (2) (K)
K-bits vector Gn = {Gn , Gn , ..., Gn } is generated and used to generate
tn . Note that for this simple scheme, tn is just the result of XORing all
packets (sk ) for which the corresponding bit location in the vector Gn is 1.
In order for the receiver to be able to recover the data, it must have the
encoding matrix G. There are two strategies for that: either the receiver
and sender maintain synchronized random number generators, or the sender
appends the encoding vector to the packet header. The former reduces the
overhead but maintaining synchronization is costly while the latter is simple
but implies some overhead. Obviously, adding the encoding vector to the
header seems more attractive when noting that overhead can be reduced by
10
Figure 2: Encoding/Decoding Random Linear Fountain Codes.
Figure 2 shows that the receiver can build a generator matrix using the
generator vectors for the received packets. This generator matrix can be in
turn utilized to recover the original file using Gaussian elimination. In other
words, the decoding is simplified to solving a system of linear equations.
N
X
sk = tn (G(k)
n )
−1
n=1
Recall that K is the number of packets constituting the original file. Now
let N be the number of received packets. How large should N be in order
11
for the decoder to be able to recover the original file? Clearly, for N < K
the system of equations is not solvable. However, for N = K the system is
solvable provided that all N packets are linearly independent. It can be easily
analytically shown that for K > 10, the probability of all first N received
12
equals almost zero. This equivalent to saying that receiving seven more
packets can assure having enough number of independent packets (equations)
and hence successful decoding. Moreover, the dotted curve shows the upper
1
N ≈ K + log2 ( )
δ
Because of its potential efficiency, network coding has been proposed for
many applications in computer networks. Next, we will see some of these
applications and show how network coding can improve the way networking
is done.
13
3.1 P2P Networks
original blocks.
In Avalanche, the server divides the original file into smaller blocks B1 , B2 , ..., Bn .
E2 , it will be sent
where cij are chosen randomly from the base field F . Along with each
block, a coefficient vector u is sent for the client to be able to decode the
original blocks.
instead of raw blocks. So, if a client is to send out the blocks E1 and E2 it
has just received, the output block (E3 ) with be formed using
E3 = c31 E1 + c32 E2
14
Note that in terms of the original blocks, E3 can be written as
n
X
E3 = (c31 .c1i + c32 .c2i )Bi
i=0
Since all the coefficients are sent with data blocks, recovering the original
This paradigm of P2P networks can have several advantages over tradi-
tional P2P systems. First, minimizing download time. This is mainly due
to the fact that existing P2P systems depend on knowing the topology of
the distributed file, i.e. which pieces are available where, or who has which
the file is disseminated all over the network, the system is robust against
situations where the server disappears before completing the download or in
case of high churn rates, where clients join just to download and leave im-
mediately after finishing. Third, Avalanche does not suffer mush when some
15
cast nature of wireless medium. As it was shown in Figure 1, the
throughput can be increased for bidirectional transfers when using a
shared base station. Let’s extend the picture to a bigger scenario where
middel router will be transferring two packets per transfer to two ad-
messages.
This scheme can be useful for so many applications that require infor-
mation exchange between two nodes such as telephony, video confer-
encing, and instant messaging. In [13], a distributed implementation
has been discussed overcoming cases where transmissions in a lossy
works. In the same paper a coding scheme called COPE has also been
shown to double the throughput of the IEEE 802.11 wireless mesh net-
work standard.
16
packets they have. Since nodes within the vicinity of each other re-
ceive similar packets, they can decode new packets. In the big picture,
intermediate nodes encode packets corresponding to multiple unicast
flows.
17
In [17], the authors propose replacing the expensive antennas used to
build sensor networks with low-cost ones resulting in a huge cost saving.
However, low cost chips might not guarantee that all neighboring nodes
can tune to each other and consequently might not be able communi-
cate. This problem can be overcome using network coding since nodes
do not need to communicate with all other nodes but rather only few
since the data stored by each node represents the data of many nodes.
The only condition for this to work is having a very dense network to
any node in the network and gets the required data. One problem
with such networks is the increased memory requirements imposed by
requiring each node to have big amount of data.
node is required to have only a memory space for one data element
plus the coefficients used to encode data. Nodes keep overhearing their
dom coefficients along with their own data so the data stored in each
node represents a linear combination of data over all other nodes. To
collect data from the network, sink node needs only to contact any n
18
nodes on the network to be able to decode n pieces of data.
[18][7][6]. Given that the probe knows the coefficients used by each node to
encode, it can analysis the received messages to check the state of nodes. In
this way, explicit monitoring of traffic eliminatedted and the status of nodes
can be inferred from the received packets.
Network coding has been shown to improve security against many types
Since data does not exist on one node but rather is distributed, overhearing
data packets will not result in getting the information except by getting all
the required blocks which makes it harder for the eavesdropper [2][3].
19
any piece was changed. This prevents against modification data attacks[11].
This can also serve in correcting errors happening to data. On the other
hand, network coding suffer a lot when it comes to jamming attacks where
the whole network. A solution for this problem has been suggested in [10]
where nodes can check received blocks on-the-fly and inform each other if a
4 Summary
20
References
[3] Ning Cai and R.W. Yeung. Secure Network Coding. In the Proceedings of
the 2002 IEEE International Symposium on Information Theory, 2002.
in sensor networks, page 15, Piscataway, NJ, USA, 2005. IEEE Press.
21
International Zurich Seminar (IZS) on Communications, pages 82–83,
ETH, Zurich, Feb. 2006.
36(1):63–68, 2006.
[9] C. Gkantsidis and P. Rodriguez. Network Coding for Large Scale Dis-
[11] Tracey Ho, Ben Leong, Ralf Koetter, Muriel Médard, Michelle Effros,
[12] S. Katti; D. Katabi; Wenjun Hu; and Rahul Hariharan. The Impor-
22
View publication stats
[18] Ho T.; Leong B.; Change Y.; Wen Y.; Koetter R. Network Monitoring
in Multicast Networks Using Network Coding. In the Proceeding of the
ISIT 2005.
23