36
Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy 22 May 2013 Marco Calderini (University of Trento) NC Problem 22 May 2013 1 / 21

Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

  • Upload
    others

  • View
    3

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Network Coding Problem - An Introduction

Dott. Marco Calderini

University of Trento, Italy

22 May 2013

Marco Calderini (University of Trento) NC Problem 22 May 2013 1 / 21

Page 2: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Flow Network

DefinitionA directed graph, with sources and sinks, where each edge e has a capacity ce,where each edge receives a non-negative flow fe (limited by ce), and where thenet flow into any non-source non-sink vertex is zero.

S

source

n1

n2

n3

T1

sink T2

sink

T3

sink

32

2

3

1

21

1

13

2

Figure : Flow NetworkMarco Calderini (University of Trento) NC Problem 22 May 2013 2 / 21

Page 3: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

The Min-Cut Max-Flow Theorem

Let G = (V,E) be a graph (network), and let S be the source a T a sink.

DefinitionA cut between S and T is a set of graph edges whose removal disconnects S fromT . A min-cut is a cut with the smallest (minimal) value. The value of the cut isthe sum of the capacities of the edges in the cut.

We will consider unit capacity edge.

Marco Calderini (University of Trento) NC Problem 22 May 2013 3 / 21

Page 4: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Example

S

T

S

T

S

T

Marco Calderini (University of Trento) NC Problem 22 May 2013 4 / 21

Page 5: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Example

S

T

S

T

S

T

Marco Calderini (University of Trento) NC Problem 22 May 2013 4 / 21

Page 6: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Example

S

T

S

T

S

T

Marco Calderini (University of Trento) NC Problem 22 May 2013 4 / 21

Page 7: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Theorem (Min-Cut Max-Flow Theorem)

Consider a graph G = (V,E) with unit capacity edges, a source vertex S, and areceiver vertex T . If the min-cut between S and T equals h, then the informationcan be send from S to T at a maximum rate of h. Equivalently, there existexactly h edge-disjoint paths between S and T .

S

T

Corollary: max-flow from a single sourceS to a single sink T over network ofunit-capacity edges is achievable viarouting

Marco Calderini (University of Trento) NC Problem 22 May 2013 5 / 21

Page 8: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Theorem (Min-Cut Max-Flow Theorem)

Consider a graph G = (V,E) with unit capacity edges, a source vertex S, and areceiver vertex T . If the min-cut between S and T equals h, then the informationcan be send from S to T at a maximum rate of h. Equivalently, there existexactly h edge-disjoint paths between S and T .

S

T

Corollary: max-flow from a single sourceS to a single sink T over network ofunit-capacity edges is achievable viarouting

Marco Calderini (University of Trento) NC Problem 22 May 2013 5 / 21

Page 9: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Theorem (Min-Cut Max-Flow Theorem)

Consider a graph G = (V,E) with unit capacity edges, a source vertex S, and areceiver vertex T . If the min-cut between S and T equals h, then the informationcan be send from S to T at a maximum rate of h. Equivalently, there existexactly h edge-disjoint paths between S and T .

S

T

Corollary: max-flow from a single sourceS to a single sink T over network ofunit-capacity edges is achievable viarouting

Marco Calderini (University of Trento) NC Problem 22 May 2013 5 / 21

Page 10: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Butterfly Network

Network: one source, two sinks,unit-capacity edges

can route two packets to one sink,one to the other

and vice-versa. Time-sharingbetween these two strategies canachieve a multicast rate of 1.5packets per use of the network.

We can do better?

Yes! Perform coding at thebottle-neck

S

T1 T2

a and b are packets of bits; a⊕ b is the modulo-two sum (XOR) of a and b. Sincea⊕ (a⊕ b) = b, and b⊕ (a⊕ b) = a, both sinks can recover both messages!Network coding achieves a multicast rate of 2 packets per use of the network (thebest possible).

Marco Calderini (University of Trento) NC Problem 22 May 2013 6 / 21

Page 11: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Butterfly Network

Network: one source, two sinks,unit-capacity edges

can route two packets to one sink,one to the other

and vice-versa. Time-sharingbetween these two strategies canachieve a multicast rate of 1.5packets per use of the network.

We can do better?

Yes! Perform coding at thebottle-neck

S

T1 T2

a b

a

b

b

b b

a and b are packets of bits; a⊕ b is the modulo-two sum (XOR) of a and b. Sincea⊕ (a⊕ b) = b, and b⊕ (a⊕ b) = a, both sinks can recover both messages!Network coding achieves a multicast rate of 2 packets per use of the network (thebest possible).

Marco Calderini (University of Trento) NC Problem 22 May 2013 6 / 21

Page 12: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Butterfly Network

Network: one source, two sinks,unit-capacity edges

can route two packets to one sink,one to the other

and vice-versa. Time-sharingbetween these two strategies canachieve a multicast rate of 1.5packets per use of the network.

We can do better?

Yes! Perform coding at thebottle-neck

S

T1 T2

a b

a

ba

a a

a and b are packets of bits; a⊕ b is the modulo-two sum (XOR) of a and b. Sincea⊕ (a⊕ b) = b, and b⊕ (a⊕ b) = a, both sinks can recover both messages!Network coding achieves a multicast rate of 2 packets per use of the network (thebest possible).

Marco Calderini (University of Trento) NC Problem 22 May 2013 6 / 21

Page 13: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Butterfly Network

Network: one source, two sinks,unit-capacity edges

can route two packets to one sink,one to the other

and vice-versa. Time-sharingbetween these two strategies canachieve a multicast rate of 1.5packets per use of the network.

We can do better?

Yes! Perform coding at thebottle-neck

S

T1 T2

a b

a

a

b

b?

? ?

a and b are packets of bits; a⊕ b is the modulo-two sum (XOR) of a and b. Sincea⊕ (a⊕ b) = b, and b⊕ (a⊕ b) = a, both sinks can recover both messages!Network coding achieves a multicast rate of 2 packets per use of the network (thebest possible).

Marco Calderini (University of Trento) NC Problem 22 May 2013 6 / 21

Page 14: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Butterfly Network

Network: one source, two sinks,unit-capacity edges

can route two packets to one sink,one to the other

and vice-versa. Time-sharingbetween these two strategies canachieve a multicast rate of 1.5packets per use of the network.

We can do better?

Yes! Perform coding at thebottle-neck

S

T1 T2

a b

a

a

b

ba⊕ b

a⊕ b

a and b are packets of bits; a⊕ b is the modulo-two sum (XOR) of a and b. Sincea⊕ (a⊕ b) = b, and b⊕ (a⊕ b) = a, both sinks can recover both messages!Network coding achieves a multicast rate of 2 packets per use of the network (thebest possible).

Marco Calderini (University of Trento) NC Problem 22 May 2013 6 / 21

Page 15: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Butterfly Network

Network: one source, two sinks,unit-capacity edges

can route two packets to one sink,one to the other

and vice-versa. Time-sharingbetween these two strategies canachieve a multicast rate of 1.5packets per use of the network.

We can do better?

Yes! Perform coding at thebottle-neck

S

T1 T2

a b

a

a

b

ba⊕ b

a⊕ b

a and b are packets of bits; a⊕ b is the modulo-two sum (XOR) of a and b. Sincea⊕ (a⊕ b) = b, and b⊕ (a⊕ b) = a, both sinks can recover both messages!Network coding achieves a multicast rate of 2 packets per use of the network (thebest possible).

Marco Calderini (University of Trento) NC Problem 22 May 2013 6 / 21

Page 16: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Some Lessons Learned from The Butterfly Example

The information superhighway is not like a real superhighway;a bit is not a car!

Nodes in a network are allowed to form outgoing streams from incoming streamsin any way (not only time-multiplexing).

The aim of network coding is to provide a receiver with sufficient ”evidence” Yabout the message X; we want H(X|Y ) = 0. It is not necessary to to supply thereceiver with X itself.

Marco Calderini (University of Trento) NC Problem 22 May 2013 7 / 21

Page 17: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Linear Network Coding

A combinational packet network N = (G,S, T,A) comprises:

a finite directed acyclic graph G = (V,E) where V is the set of vertices andE is the set of directed edges;

a distinguished set S ⊂ V of sources;

a distinguished set T ⊂ V of sinks;

and a finite packet alphabet A with |A| ≥ 2.

Vertices: communication nodesEdges: error-free communication channels of unit capacity (one symbol from A).Packets transmitted on non-source edges from a node v are functions of packetsreceived at v.Does not model errors, delay, cycles, etc., but suffices to capture main ideas.

Marco Calderini (University of Trento) NC Problem 22 May 2013 8 / 21

Page 18: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Packets are length-m vectorsover a finite field Fq

Nodes create outgoing packetsas Fq-linear combinations ofincoming packets

Original packets can berecovered by solving a linearsystem of equations

Xi = [xi1, . . . , xim] ∈ Fmq

u

P1

P2

∑2i=1 aiPi

Y1...Yn

=

A11 . . . A1n

......

An1 . . . Ann

transfer matrix

X1

...Xn

Marco Calderini (University of Trento) NC Problem 22 May 2013 9 / 21

Page 19: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Theorem (Linear Network Multicasting Theorem)

Let N = (G, s, T,Fq). A multicast rate of R(s, T ) = mint∈Tmincut(s, t) isachievable, for sufficiently large q, with linear network coding.

Algebraic proof: Koetter and Medard, 2003. (Can show that q > |T |suffices.)

Linear Information Flow Algorithm: Jaggi, Sanders, et al., 2005. (Requiresonly q ≥ |T |.)

Marco Calderini (University of Trento) NC Problem 22 May 2013 10 / 21

Page 20: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Proof Sketch: Linear Network Multicasting Theorem

S

t2

t1 t3

P1 P2

a1P1 + a2P2

a3P1 + a4(a1P1 + a2P2)

Marco Calderini (University of Trento) NC Problem 22 May 2013 11 / 21

Page 21: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

A1 =

[1 0

a3 + a1a4 a2a4

]A2 =

[0 1a1 a2

]A3 =

[a1 a2

a3 + a1a4 a2a4

]Condition for decoding: det(Ai) 6= 0 for 1 ≤ i ≤ 3.This is an algebraic condition: we require a nonzero value for the polynomial

p(a1, a2, a3, a4) = det(A1) · det(A2) · det(A3).

Lemma (Sparse Zeros Lemma)

Over a sufficiently large finite field, a nonzero polynomial takes on a nonzero value.

(Here, one can show that q > |T | suffices.) Thus linear network coding achievesthe multicast capacity.

Marco Calderini (University of Trento) NC Problem 22 May 2013 12 / 21

Page 22: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Linear Information Flow Algorithm

S

t1 t2 t3

Network: one source, threesinks, multicast capacity 3

find 3 edge-disjoint paths tot1

find 3 edge-disjoint paths tot2

find 3 edge-disjoint paths tot3

discard unused vertices andedges

process edges in topologicalorder (i.e., upstream beforedownstream)

Idea: maintain the invariant that the transfer matrix induced so far at each sink isinvertible.

Marco Calderini (University of Trento) NC Problem 22 May 2013 13 / 21

Page 23: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Linear Information Flow Algorithm

S

t1 t2 t3

Network: one source, threesinks, multicast capacity 3

find 3 edge-disjoint paths tot1

find 3 edge-disjoint paths tot2

find 3 edge-disjoint paths tot3

discard unused vertices andedges

process edges in topologicalorder (i.e., upstream beforedownstream)

Idea: maintain the invariant that the transfer matrix induced so far at each sink isinvertible.

Marco Calderini (University of Trento) NC Problem 22 May 2013 13 / 21

Page 24: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Linear Information Flow Algorithm

S

t1 t2 t3

Network: one source, threesinks, multicast capacity 3

find 3 edge-disjoint paths tot1

find 3 edge-disjoint paths tot2

find 3 edge-disjoint paths tot3

discard unused vertices andedges

process edges in topologicalorder (i.e., upstream beforedownstream)

Idea: maintain the invariant that the transfer matrix induced so far at each sink isinvertible.

Marco Calderini (University of Trento) NC Problem 22 May 2013 13 / 21

Page 25: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Linear Information Flow Algorithm

S

t1 t2 t3

Network: one source, threesinks, multicast capacity 3

find 3 edge-disjoint paths tot1

find 3 edge-disjoint paths tot2

find 3 edge-disjoint paths tot3

discard unused vertices andedges

process edges in topologicalorder (i.e., upstream beforedownstream)

Idea: maintain the invariant that the transfer matrix induced so far at each sink isinvertible.

Marco Calderini (University of Trento) NC Problem 22 May 2013 13 / 21

Page 26: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Linear Information Flow Algorithm

S

t1 t2 t3

Network: one source, threesinks, multicast capacity 3

find 3 edge-disjoint paths tot1

find 3 edge-disjoint paths tot2

find 3 edge-disjoint paths tot3

discard unused vertices andedges

process edges in topologicalorder (i.e., upstream beforedownstream)

Idea: maintain the invariant that the transfer matrix induced so far at each sink isinvertible.

Marco Calderini (University of Trento) NC Problem 22 May 2013 13 / 21

Page 27: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Linear Information Flow Algorithm

S

t1 t2 t3

Network: one source, threesinks, multicast capacity 3

find 3 edge-disjoint paths tot1

find 3 edge-disjoint paths tot2

find 3 edge-disjoint paths tot3

discard unused vertices andedges

process edges in topologicalorder (i.e., upstream beforedownstream)

Idea: maintain the invariant that the transfer matrix induced so far at each sink isinvertible.

Marco Calderini (University of Trento) NC Problem 22 May 2013 13 / 21

Page 28: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Linear Information Flow Algorithm

S

t1 t2 t3

Network: one source, threesinks, multicast capacity 3

find 3 edge-disjoint paths tot1

find 3 edge-disjoint paths tot2

find 3 edge-disjoint paths tot3

discard unused vertices andedges

process edges in topologicalorder (i.e., upstream beforedownstream)

Idea: maintain the invariant that the transfer matrix induced so far at each sink isinvertible.

Marco Calderini (University of Trento) NC Problem 22 May 2013 13 / 21

Page 29: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

e must be a linear combination of u1, u2 and u3

e, which replaces rows in some transfer matrices, must maintain their full rank

Marco Calderini (University of Trento) NC Problem 22 May 2013 14 / 21

Page 30: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Suppose u1, u2 and u3 span an m-dimensional space V1.

Assuming multicast capacity r, at a sink node t, the vectors not beingreplaced span an (r − 1)-dimensional space V2.

We have dim(V1 ∩ V2) = dim(V1) + dim(V2)− dim(V1 ∪ V2) = m− 1

All vectors in V1 ∩ V2 are ruled out as choices for .

In total, the zero vector + at most |T |(qm−1 − 1) nonzero vectors are ruledout, leaving at least

qm − 1− |T |(qm−1 − 1) = qm−1(q − |T |) + |T | − 1

choices for e, which is strictly positive as long as q ≥ |T |.

Marco Calderini (University of Trento) NC Problem 22 May 2013 15 / 21

Page 31: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Random Network Coding

As observed by Tracey Ho, et al. [HMKKESL,2006], choosing the local networkcoding coefficients at random leads to full rank transfer matrices with highprobability if the field size is sufficiently large.If η random choices must be made,

P [success] ≥ (1− |T |/q)η ≥ 1− η|T |q,

or

P [failure] ≤ η|T |q

= η|T |2−m

for q = 2m, i.e., exponential decrease with the number of bits per field element.Thus, a network code chosen at random is highly likely to achieve the multicastcapacity, if q is large enough.

Marco Calderini (University of Trento) NC Problem 22 May 2013 16 / 21

Page 32: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Routing versus Coding

Multicast by routing:

requires packing of multipledistribution trees

optimal packing may not achievemulticast capacity

optimal fractional packing ofdistribution trees is NP hard [Jain,Mahdian, Salavatipour, SODA2003]

Multicast by linear network coding:

achieves multicast capacity

optimal solution can be foundefficiently (polynomial time)

S

t2 t3

t1

Multicasting via distribution trees

Marco Calderini (University of Trento) NC Problem 22 May 2013 17 / 21

Page 33: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Linearly-coded Networks

We distinguish between two models for network coding:

1 Coherent: the network is given, and the local coding coefficients are fixed atdesign time (so that Ai is known at receiver ti, where Ai is the transfermatrix of ti)

2 Noncoherent: the local coding coefficients are chosen randomly at run time(so that Ai is not known to the transmitters or receivers)

Marco Calderini (University of Trento) NC Problem 22 May 2013 18 / 21

Page 34: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Random (Noncoherent) Linear Network Coding

Nodes draw coding coefficients uniformly at random from FqThe transfer matrix will be invertible with high probability if q is sufficientlylarge

The transfer matrix can be recorded by appending a header to each originalpacket

X = [I D]

Y = AX = [AAD]⇒ A−1Y = [I D] = X

Captures most of the practical applications of network coding

Marco Calderini (University of Trento) NC Problem 22 May 2013 19 / 21

Page 35: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Conclusion

Linear network codes:

achieve the multicast capacity for sufficiently large q

can be chosen randomly without sacrificing optimality

Marco Calderini (University of Trento) NC Problem 22 May 2013 20 / 21

Page 36: Network Coding Problem - An Introductionsala/events2013/BUNNYslide_Calderini.pdf · Network Coding Problem - An Introduction Dott. Marco Calderini University of Trento, Italy

Thanks for your attention!

Marco Calderini (University of Trento) NC Problem 22 May 2013 21 / 21