• Keine Ergebnisse gefunden

Theory of Parallel and Distributed Systems (WS2016/17)

N/A
N/A
Protected

Academic year: 2022

Aktie "Theory of Parallel and Distributed Systems (WS2016/17)"

Copied!
45
0
0

Wird geladen.... (Jetzt Volltext ansehen)

Volltext

(1)Theory of Parallel and Distributed Systems (WS2016/17) Kapitel 5 Permutation Routing. Walter Unger Lehrstuhl für Informatik 1. 12:01 Uhr, den 30. Januar 2017.

(2) Introduction 5. Recall. Disjoint Path Lemma. Inhaltsverzeichnis. Walter Unger 30.1.2017 12:01. Inhalt I Edge Colouring. 1. Introduction Networks Permutation Networks Matching on Bipartite Graphs. 2. Recall Some Basics Theorem of Hall. Z. Routing on Mesh Networks. 3. Disjoint Path Lemma The Lemma The Proof. 4. Routing on Mesh Networks The Problem Simple Routings Annexstein and Baumslag. WS2016/17.

(3) Introduction 5:1. Recall. Disjoint Path Lemma. Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Properties of the Networks to be considered Number of nodes. Number of edges. Degree. Length of pathes in the network: Diameter, i.e. the longest of all shortest paths. Radius, i.e. length of the shortest of all longest shortest paths Connectivity, i.e. is there a bottle-neck. Regularity, May be all nodes look ‘similar”. May be all edges look ‘similar”. Easy routing May be the graph is based on some group-structure. How many graphs are in some family of networks?. Z. Routing on Mesh Networks.

(4) Introduction 5:2. Recall. Networks. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Product of Graphs Definition: Let G = (V , E ) and G 0 = (V 0 , E 0 ) be graphs. With G × G 0 we denote the product of G and G 0 : G × G 0 = (V × V 0 , E1 ∪ E2 ). E1 = {((a, a0 ), (b, b 0 )) | a0 = b 0 ∧ (a, b) ∈ E }. E2 = {((a, a0 ), (b, b 0 )) | a = b ∧ (a0 , b 0 ) ∈ E 0 }. Example L(10) × C (4): v3 v3 w0 v3 w1 v3 w2 v3 w3 v3 w4 v3 w5 v3 w6 v3 w7 v3 w8 v3 w9 v2 v2 w0 v2 w1 v2 w2 v2 w3 v2 w4 v2 w5 v2 w6 v2 w7 v2 w8 v2 w9 v1 v1 w0 v1 w1 v1 w2 v1 w3 v1 w4 v1 w5 v1 w6 v1 w7 v1 w8 v1 w9 v0 v0 w0 v0 w1 v0 w2 v0 w3 v0 w4 v0 w5 v0 w6 v0 w7 v0 w8 v0 w9 w0 w1 w2 w3 w4 w5 w6 w7 w8 w9.

(5) Introduction 5:3. Recall. Disjoint Path Lemma. Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Grid of dimension d Grids: G (n1 , n2 , · · · , nd ) = L(n1 ) × L(n2 ) × · · · × L(Nd ) with ni > 1 d Y Nodecount: ni Degrees: {d, . . . , 2 · d} i=1. Edgecount:. d d X Y (ni − 1) nj i=1. Z. Routing on Mesh Networks. Diameter:. d X (ni − 1) i=1. j=1,j6=i. Grid: G (14, 4): 0,3. 1,3. 2,3. 3,3. 4,3. 5,3. 6,3. 7,3. 8,3. 9,3. 10,3. 11,3. 12,3. 13,3. 0,2. 1,2. 2,2. 3,2. 4,2. 5,2. 6,2. 7,2. 8,2. 9,2. 10,2. 11,2. 12,2. 13,2. 0,1. 1,1. 2,1. 3,1. 4,1. 5,1. 6,1. 7,1. 8,1. 9,1. 10,1. 11,1. 12,1. 13,1. 0,0. 1,0. 2,0. 3,0. 4,0. 5,0. 6,0. 7,0. 8,0. 9,0. 10,0. 11,0. 12,0. 13,0.

(6) Introduction 5:4. Recall. Disjoint Path Lemma. Networks. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Torus of dimension d Torus: Tr (n1 , n2 , · · · , nd ) = C (n1 ) × C (n2 ) × · · · × C (Nd ) with ni > 1 Qd Number of nodes: ni Degree: 2 · d Qi=1 Pd d Number of edges: Diameter: i=1 ni i=1 bni /2c Torus: Tr (14, 4): 0,3. 1,3. 2,3. 3,3. 4,3. 5,3. 6,3. 7,3. 8,3. 9,3. 10,3. 11,3. 12,3. 13,3. 0,2. 1,2. 2,2. 3,2. 4,2. 5,2. 6,2. 7,2. 8,2. 9,2. 10,2. 11,2. 12,2. 13,2. 0,1. 1,1. 2,1. 3,1. 4,1. 5,1. 6,1. 7,1. 8,1. 9,1. 10,1. 11,1. 12,1. 13,1. 0,0. 1,0. 2,0. 3,0. 4,0. 5,0. 6,0. 7,0. 8,0. 9,0. 10,0. 11,0. 12,0. 13,0.

(7) Introduction 5:5. Recall. Disjoint Path Lemma. Networks. Walter Unger 30.1.2017 12:01. Hypercube of dimension d. Z. Routing on Mesh Networks WS2016/17. HQ(d) = (VHQ(d) , EHQ(d) ) VHQ(d) = {0, 1}d EHQ(d) = {{w 0w 0 , w 1w 0 } | w 0w 0 , w 1w 0 ∈ VHQ(d) } Number of nodes: 2d Degree: d Number of edges: d · 2d−1 Diameter: d. 0000 0001 0010 0011 0100 0101 0110 0111 1000 1001 1010 1011 1100 1101 1110 1111. 0000 0001 0011 0010 0110 0111 0101 0100 1100 1101 1111 1110 1010 1011 1001 1000. Note the Gray-Code..

(8) Introduction 5:6. Recall. Disjoint Path Lemma. Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Hypercube of dimension d (alternative view) HQ(d) VHQ(d) EHQ(d). = = =. (VHQ(d) , EHQ(d) ) {0, 1}d {{w 0w 0 , w 1w 0 } | w 0w 0 , w 1w 0 ∈ VHQ(d) } 10110 10010. 00110 00010. 10000. 10001. 10101 11010. 00011 00100. 00000. 00111. 10111. 10011 10100. 00001. 11110. 01010. 01110 01011 01100. 01000. 01111. 01001. 01101. 11000. 11111. 11011 11100. 00101. Z. Routing on Mesh Networks. 11001. 11101.

(9) Introduction 5:7. Recall. Disjoint Path Lemma. Networks. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Cube-Connected Cycles of dimension d c h CCC (d) = (VCCC (d) , ECCC (d) ∪ ECCC (d) ) VCCC (d) = {0, 1, · · · , d − 1} × {0, 1}d c ECCC = {{(i, w ), ((i + 1) mod d, w )} | w ∈ {0, 1}d , 0 6 i < d} (d) h ECCC (d) = {{(i, w 0w 0 ), (i, w 1w 0 )} | w 0 ∈ {0, 1}n−i−1 , w ∈ {0, 1}i } Number of nodes: d · 2d Degree: 3 Number of edges: 3 · d · 2d−1 Diameter: 2 · d − 2 + bd/2c 0, 000. 0, 001. 0, 010. 0, 011. 0, 100. 0, 101. 0, 110. 0, 111. 1, 000. 1, 001. 1, 010. 1, 011. 1, 100. 1, 101. 1, 110. 1, 111. 2, 000. 2, 001. 2, 010. 2, 011. 2, 100. 2, 101. 2, 110. 2, 111.

(10) Introduction 5:8. Recall. Disjoint Path Lemma. Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Butterfly of dimension d Eh. Z. Routing on Mesh Networks. = {{(i, w 0w 0 ), (i, w 1w 0 )} | w ∈ {0, 1}i , w 0 ∈ {0, 1}n−i−1 }. c hCCC (d) BF (d) = (VBF (d) , EBF (d) ∪ EBF (d) ) VBF (d) = {0, 1, · · · , d − 1} × {0, 1}d c EBF = {{(i, w ), ((i + 1) mod d, w )} | w ∈ {0, 1}d , 0 6 i < d} (d) h EBF (d) = {{(i, w 0w 0 ), ((i + 1) mod d, w 1w 0 )} | w ∈{0,1}n−i−1 ,w 0 ∈{0,1}i } Number of nodes: d · 2d Degree: 4 Number of edges: d · 2d+1 Diameter: d + bd/2c 0,000. 0,001. 0,010. 0,011. 0,100. 0,101. 0,110. 0,111. 1,000. 1,001. 1,010. 1,011. 1,100. 1,101. 1,110. 1,111. 2,000. 2,001. 2,010. 2,011. 2,100. 2,101. 2,110. 2,111. 0,000. 0,001. 0,010. 0,011. 0,100. 0,101. 0,110. 0,111.

(11) Introduction 5:9. Recall. Disjoint Path Lemma. Networks. Walter Unger 30.1.2017 12:01. WS2016/17. DeBruijn network of dimension d DeBruijn DB(d) VDB(d) s EDB(d) se EDB(d). network: s se = (VDB(d) , EDB(d) ∪ EDB(d) ) d = {0, 1} = {(aw , wa) | a ∈ {0, 1}, aw , wa ∈ VDB(d) } = {(aw , wb) | a ∈ {0, 1}, b = 1 − a, aw , wb ∈ VDB(d) }. Number of nodes: Number of edges:. 2d 2d+1. Degree: Diameter:. 001. 000. 100. 2+2 d 011. 010. 101. 111. 110. Z. Routing on Mesh Networks.

(12) Introduction 5:10. Recall. Disjoint Path Lemma. Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Shuffle-Exchange network of dimension d Shuffle-Exchange network: s e SE (d) = (VSE (d) , ESE (d) ∪ ESE (d) ) d VSE (d) = {0, 1} s ESE = {(aw , wa) | a ∈ {0, 1}, aw , wa ∈ VSE (d) } (d) e ESE = {(wa, wb) | a ∈ {0, 1}, b = 1 − a, wa, wb ∈ VSE (d) } (d) Number of nodes: Number of edges:. 2d 2d+1. Degree: Diameter: 010. 000. 110. 100. 2+2 2·d −1. 011. 001. 101. Z. Routing on Mesh Networks. 111.

(13) Introduction 5:11. Recall. Disjoint Path Lemma. Permutation Networks. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Recall Butterfly of dimension d c h BF (d) = (VBF (d) , EBF (d) ∪ EBF (d) ) VBF (d) = {0, 1, · · · , d − 1} × {0, 1}d c EBF = {{(i, w ), ((i + 1) mod d, w )} | w ∈ {0, 1}d , 0 6 i < d} (d) h EBF (d) = {{(i, w 0w 0 ), ((i + 1) mod d, w 1w 0 )} | w ∈{0,1}n−i−1 ,w 0 ∈{0,1}i } Number of nodes: d · 2d Degree: 4 Number of edges: d · 2d+1 Diameter: d + bd/2c 0,000. 0,001. 0,010. 0,011. 0,100. 0,101. 0,110. 0,111. 1,000. 1,001. 1,010. 1,011. 1,100. 1,101. 1,110. 1,111. 2,000. 2,001. 2,010. 2,011. 2,100. 2,101. 2,110. 2,111. 0,000. 0,001. 0,010. 0,011. 0,100. 0,101. 0,110. 0,111.

(14) Introduction 5:12. Recall. Disjoint Path Lemma. Permutation Networks. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Unwrapped Butterfly of dimension d c h BF (d) = (VBF (d) , EBF (d) ∪ EBF (d) ) VBF (d) = {0, · · · , d} × {0, 1}d c EBF = {{(i, w ), (i + 1, w )} | w ∈ {0, 1}d , 0 6 i < d} (d) h EBF (d) = {{(i, w 0w 0 ), (i + 1, w 1w 0 )} | w ∈{0,1}n−i−1 ,w 0 ∈{0,1}i ,06i<d } Number of nodes: (d + 1) · 2d Number of edges: d · 2d+1 0,000. 0,001. 0,010. 0,011. 0,100. 0,101. 0,110. 0,111. 1,000. 1,001. 1,010. 1,011. 1,100. 1,101. 1,110. 1,111. 2,000. 2,001. 2,010. 2,011. 2,100. 2,101. 2,110. 2,111. 3,000. 3,001. 3,010. 3,011. 3,100. 3,101. 3,110. 3,111.

(15) Introduction 5:13. Recall. Permutation Networks. Disjoint Path Lemma. Walter Unger 30.1.2017 12:01. WS2016/17. Permutation network PN(d) VPN(d) c EPN(d). h EPN(d). = = = ∪ ∪ = ∪ ∪. Z. Routing on Mesh Networks. c h (VPN(d) , EPN(d) ∪ EPN(d) ) {1, 2, · · · , d, −1, −2, · · · , −d} × {0, 1}d {{(i, w ), (i + 1, w )} | w ∈ {0, 1}d , 1 6 i < d} {{(1, w ), (−1, w )} | w ∈ {0, 1}d } {{(−i, w ), (−i − 1, w )} | w ∈ {0, 1}d , 1 6 i < d} {{(i, w 0w 0 ), (i + 1, w 1w 0 )} | w ∈{0,1}n−i−1 ,w 0 ∈{0,1}i } {{(1, w 0w 0 ), (−1, w 1w 0 )} | w ∈{0,1}n−i−1 ,w 0 ∈{0,1}i } {{(−i, w 0w 0 ), (−i − 1, w 1w 0 )} | w ∈{0,1}n−i−1 ,w 0 ∈{0,1}i }.

(16) Introduction 5:14. Permutation Networks. Recall. Disjoint Path Lemma. Walter Unger 30.1.2017 12:01. Large Example Permutation network. Z. Routing on Mesh Networks WS2016/17.

(17) Introduction 5:15. Recall. Disjoint Path Lemma. Permutation Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Extended Permutation network PN(n, d) VPN(d) c EPN(n,d). h EPN(n,d). = = = ∪ ∪ = ∪ ∪. Z. Routing on Mesh Networks. c h (VPN(n,d) , EPN(d) ∪ EPN(n,d) ) {1, 2, · · · , d, −1, −2, · · · , −d} × {0, .., n − 1}d {{(i, w ), (i + 1, w )} | w ∈ {0, .., n − 1}d , 1 6 i < d} {{(1, w ), (−1, w )} | w ∈ {0, .., n − 1}d } {{(−i, w ), (−i − 1, w )} | w ∈ {0, .., n − 1}d , 1 6 i < d} {{(i, w 0w 0 ), (i + 1, w 1w 0 )} | w ∈{0,..,n−1}n−i−1 ,w 0 ∈{0,..,n−1}i } {{(1, w 0w 0 ), (−1, w 1w 0 )} | w ∈{0,..,n−1}n−i−1 ,w 0 ∈{0,..,n−1}i } {{(−i, w 0w 0 ), (−i − 1, w 1w 0 )} | w ∈{0,..,n−1}∗ ,w 0 ∈{0,..,n−1}i }. The 2d · nd nodes of (n, d)-PN are partitioned into 2d levels and nd columns. Levels are numbered −d, . . . , −1, 1, . . . , d. Columns are labeled with strings of length d over {0, 1, ..., n − 1}. The parameter d is called the dimension of the network. The nodes on level −d [resp. d] are called inputs [resp. outputs]. Each input (output) is identified with its column label. Permutation networks have a recursive structure. The Permutation network (n, 1) is complete (all possible connections)..

(18) Introduction 5:16. Recall. Some Basics. Disjoint Path Lemma. Walter Unger 30.1.2017 12:01. WS2016/17. Recall Definition (Bipartite graph) A graph G = (V , E ) is called bipartite if there exist U, W ⊂ V with U ∪˙ W = V and ∀e ∈ E : ∃u ∈ U, w ∈ W : e = {u, w }. Definition (Matching) For a given Graph G = (V , E ), a matching M ⊆ E is a set of non-incident edges, i.e., ∀e, f ∈ M : e ∩ f = ∅. Definition (Perfect matching) A matching M is called perfect, if it contains all nodes from G: ∀v ∈ V ∃e ∈ M : v ∈ e.. Z. Routing on Mesh Networks.

(19) Introduction 5:17. Some Basics. Recall. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Theorem of Hall Definition Let G = (V1 , V2 , E ) be a bipartite graph, and A ⊆ V1 . We denote: Γ(A) = {v ∈ V2 (v , w ) ∈ E , w ∈ A}. Theorem (Hall) Let G = (V1 , V2 , E ) be a bipartite graph. There exits a complete matching from V1 to V2 , iff for each A ⊆ V1 we have |Γ(A)| > |A|. Corollary Every regular bipartite Graph G = (V1 , V2 , E ) with |V1 | = |V2 | contains a complete matching..

(20) Introduction 5:18. Recall. Some Basics. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Proof (Hall) Theorem (Hall) Let G = (V1 , V2 , E ) be a bipartite graph. There exits a complete matching from V1 to V2 , iff for each A ⊆ V1 we have |Γ(A)| > |A|. =⇒ simple: Let M be a matching with |M| = |V1 | and let A ⊂ V1 arbitrary. |Γ(A)| = |{v ∈ V2 (v , w ) ∈ E , w ∈ A}|. |Γ(A)| > |{v ∈ V2 (v , w ) ∈ M, w ∈ A}|. |Γ(A)| > |A|..

(21) Introduction 5:19. Recall. Some Basics. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Proof (Hall) Theorem (Hall) Let G = (V1 , V2 , E ) be a bipartite graph. There exits a complete matching from V1 to V2 , iff for each A ⊆ V1 we have |Γ(A)| > |A|. ⇐= by contradiction: Let M be the largest matching with |M| < |V1 |. Let A1 = {v ∈ V1 | ∃b ∈ V2 : {v , b} ∈ M}. Let A2 = {v ∈ V2 | ∃b ∈ V1 : {v , b} ∈ M}. Let a ∈ V1 \ A1 . Γ(a) ⊂ A2 , because M is the largest matching. Any alternating path starting from a reaches only nodes in A01 ∪ A02 with A0i ⊂ Ai and |A01 | = |A02 |. Thus we have Γ(A01 ∪ {a}) ⊂ A02 . |A01 ∪ {a}| > |A02 |..

(22) Introduction 5:20. Recall. Edge Colouring. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Edge-Colouring I Definition (Edge coloring) Let G = (V , E ) be a graph. ψ : E → {1, ..., k} is an edge coloring if every pair of incident edges e1 , e2 is colored in different colors, i.e., ψ(e1 ) 6= ψ(e2 ). Definition. The Edge-Colouring-Problem for a graph G corresponds to the node-colouring of L(G ): χ0 (G ) = χ(L(G )). Theorem (Vizing 1965) χ0 (K2n ) = 2n − 1 and χ0 (K2n+1 ) = 2n + 1. Theorem χ0 (G ) > ω(L(G )) > ∆(G )..

(23) Introduction 5:21. Recall. Edge Colouring. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Edge-Colouring II Definition (Regular graphs) A graph is called n-regular, n ∈ N, if all nodes have the same degree n. Theorem. ˙ 2 , E ) has an edge coloring with n colors. A bipartite n-regular graph G = (V1 ∪V Theorem (Holyer) The d-Edge-Colouring-Problem is NP-complete for d > 3. Theorem (König 1916) Any bipartite graph with degree ∆ is ∆ edge-colourable (Running-Time O(nm)). Theorem (Vizing 1964) Any graph with degree ∆ is ∆ + 1 edge-colourable (Running-Time O(nm))..

(24) Introduction 5:22. Recall. Edge Colouring. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Simple Proof Theorem. ˙ 2 , E ) has an edge coloring with n colors. A bipartite n-regular graph G = (V1 ∪V Proof: We use an induction on the node degree n. Base Case: For n = 1 the statement is trivially true. Induction step: Let n > 1. Claim: ∀S ⊆ V1 : |Γ(S)| > |S| Proof: The number of edges from S into ΓG (S) is k := n · |S|. Hence, ΓG (S) has at least k incident edges. Each node in Γ(S) is incident to at most n of these k edges. Hence, |ΓG (S)| > k/n = |S|. Now Hall’s theorem implies that G has a perfect matching M. The edges of M get assigned color n − 1. The remaining graph is n − 1-regular and, by our induction hypothesis, can be colored with the remaining colors {0, 1, . . . , n − 2}..

(25) Introduction 5:23. Edge Colouring. Recall. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Proof (König) Theorem (König) Any bipartite graph with degree ∆ is ∆ edge-colourable (Running-Time O(nm)). a. b. Let ca , cb be the unused colours at the nodes a, b.. c. d. If ca = cb , we may colour (a, b) with ca .. e. f. g. h. i. j. k. l. m. n. o. p. Show how to colour an edge (a, b) in O(n) time.. Observe now the graph Ha,b , who consists only of edges coloured with ca , cb . Ha,b consists of a disjoined set of paths and cycles. a and b are the endpoints of two different paths. Thus we may exchange the colours of one path. Running-Time: store for each node and colour the corresponding edge..

(26) Introduction 5:24. Recall. The Lemma. Disjoint Path Lemma. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Lemma (Disjoint Path Lemma) For every permutation π : {0, 1, ..., n − 1}d → {0, 1, ..., n − 1}d , there is a collection of nd node disjoint paths in (n, d)-PN that, for every a ∈ {0, 1, ..., n − 1}d , contains a path Wa connecting input a with output π(a)..

(27) Introduction 5:25. Recall. The Proof. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Proof Lemma (Disjoint Path Lemma). For every permutation π : {0, 1, ..., n − 1}d → {0, 1, ..., n − 1}d , there is a collection of nd node disjoint paths in (n, d)-PN that, for every a ∈ {0, 1, ..., n − 1}d , contains a path Wa connecting input a with output π(a). Proof: Induction over d. Base Case: d = 1 : This case is trivially true since the inputs and the outputs are completely connected in P(n, 1). Induction step: (d − 1) → d. Idea is: Recall the recursive description of (n, d)-PN..

(28) Introduction 5:26. Recall. Disjoint Path Lemma. The Proof. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Proof (Recursive Description). An input/output-pair (a, π(a)) that should be connected by a path is called a request. For each request, we choose a subnetwork B (i) , i ∈ {0, 1, ..., n − 1}, through which the request is routed..

(29) Introduction 5:27. Recall. The Proof. Disjoint Path Lemma. Walter Unger 30.1.2017 12:01. WS2016/17. Proof (Recursive Step). The choices of the subnetworks satisfy the following properties: 1. 2. Z. Routing on Mesh Networks. Each input of each subnetwork is used by exactly one of the requests. Each output of each subnetwork is used by exactly one request..

(30) Introduction 5:28. Recall. The Proof. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Proof (Recursive Step). This way, for every i ∈ {0, 1, ..., n − 1}, the requests mapped to B (i) define a permutation. Thus, these requests can be routed along disjoint paths in B (i) by our induction hypothesis, so that the Disjoint Path Lemma follows. We have to show how to choose the subnetworks for the requests..

(31) Introduction 5:29. Recall. The Proof. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Proof (by Conflict Graph) Towards this end, we define the following bipartite conflict graph:. Gπ = ({ux | x ∈ {0, 1, ..., n − 1}d−1 } ∪ {vx | x ∈ {0, 1, ..., n − 1}d−1 }, Eπ ) The set Eπ contains an edge ea = {uâ , ub̂ } for every request (a, b) with b = π(a), where x̂ drops the leading letter of a string x = x0 , x1 , . . . , xd−1 ∈ {0, 1, ..., n − 1}d , i.e., x̂ = x1 , . . . , xd−1 ∈ {0, 1, ..., n − 1}d−1 . Edges incident to the same node ux represent an input conflict, that is, the corresponding requests must be routed through different subnetworks as, otherwise, they would share the same subnetwork input in column ix, for some i ∈ {0, 1, ..., n − 1}. Analogously, edges incident to the same node vx represent an output conflict and the corresponding requests should be routed through different subnetworks as well. Gπ is n-regular and bipartite..

(32) Introduction 5:30. Recall. The Proof. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Proof (by Conflict Graph). Gπ = ({ux | x ∈ {0, 1, ..., n − 1}d−1 } ∪ {vx | x ∈ {0, 1, ..., n − 1}d−1 }, Eπ ) The set Eπ contains an edge ea = {uâ , ub̂ } for every request (a, b) with b = π(a), where x̂ drops the leading letter of a string x = x0 , x1 , . . . , xd−1 ∈ {0, 1, ..., n − 1}d , i.e., x̂ = x1 , . . . , xd−1 ∈ {0, 1, ..., n − 1}d−1 . Gπ is n-regular and bipartite. By the Coloring Lemma, Eπ can be colored with colors 0, 1, ..., n − 1. For any i ∈ {0, . . . , n − 1}, the edges of color i build a matching in Gπ and, hence, the corresponding requests do not have input or output conflict. If all requests of color i ∈ {0, . . . , n − 1} are routed through subnetwork B (i) then the Properties 1 and 2 are satisfied. This completes the proof of the Disjoint Path Lemma..

(33) Introduction 5:31. Recall. Disjoint Path Lemma. The Problem. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. The Routing Problem Definition (Permutation routing problem) Let G = (V , E ) be a network. A permutation routing problem is defined by a permutation π : V → V . Each node v ∈ V has a message (packet) that shall be routed to node π(v ). Note: We use the synchronous congestion model from Peleg’s book: In each step, each edge can forward one packet in each direction..

(34) Introduction 5:32. Recall. Disjoint Path Lemma. Simple Routings. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Example Observation. On M(n, d), sending a packet from a source to a destination can be done by using dimension-by-dimension routing, that is, first the packet is routed to the target position with respect to dimension 0, then with respect to dimension 1, and so on. On the two-dimensional array M(n, 2), this approach is also called row-column routing as a packet is first routed to the target position in the row and then to the target position in the column. 0,3. 1,3. 2,3. 3,3. 4,3. 5,3. 6,3. 7,3. 8,3. 9,3. 10,3. 11,3. 12,3. 13,3. 0,2. 1,2. 2,2. 3,2. 4,2. 5,2. 6,2. 7,2. 8,2. 9,2. 10,2. 11,2. 12,2. 13,2. 0,1. 1,1. 2,1. 3,1. 4,1. 5,1. 6,1. 7,1. 8,1. 9,1. 10,1. 11,1. 12,1. 13,1. 0,0. 1,0. 2,0. 3,0. 4,0. 5,0. 6,0. 7,0. 8,0. 9,0. 10,0. 11,0. 12,0. 13,0.

(35) Introduction 5:33. Recall. Disjoint Path Lemma. Simple Routings. Walter Unger 30.1.2017 12:01. WS2016/17. Examples On the hypercube M(2, d), the paths chosen by dimension-by-dimension routing are called bit-fixing paths. 10110 10010. 00110 00010. 10000. 10001. 10101 11010. 00011 00100. 00000. 00111. 10111. 10011 10100. 00001. 11110. 01010. 01110 01011 01100. 01000. 01111. 01001. 01101. 11000. 11111. 11011 11100. 00101. Z. Routing on Mesh Networks. 11001. 11101.

(36) Introduction 5:34. Recall. Simple Routings. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. More Routing on Meshes In the following, let D denote the diameter of the network. Observation Every permutation π can be routed along dimension-by-dimension paths in at most D steps on M(n, 1) and M(n, 2). Lemma Consider M(n, 3). There is a permutation π such that every packet routing algorithm using dimension-by-dimension paths needs at least Ω(D 2 ) steps for routing π..

(37) Introduction 5:35. Recall. Disjoint Path Lemma. Simple Routings. Walter Unger 30.1.2017 12:01. WS2016/17. Idea for Proof of Lemma. h6. A Grid. h5. Exchange between ai ’s. Exchange between ci ’s. a0 b0. g3. a1 b1. a2 b2. a3 b3. a4 b4. a5 b5. a6 b6. g2. h0. a7. g1 g0. b7. c0 d0. Exchange between gi ’s. e0. Exchange between hi ’s. f0. c1 d1. c2 d2. c3 d3. c4 d4. c5 d5. c6 d6. e2. e3. e4. e5. g0. f1 g1. f2 g2. f3 g3. f4 g4. f5 g5. f6. h0. h1. h2. h3. h4. h5. h6. a1 a0. a6 a5. a4 a3. a7. b5. b3. a2. b0. b7 b6. b4. b2 b1. g6. c5. c3. c1 c0. c6. c4. c2. d0. c7. d5. d3. d1. e6. d7 d6. d4. d2 e1. e4. e2. e0. d7. e5. e3. e1. e6. f4. f2. f0. c7. f6 f5. f3. f1. Exchange between fi ’s. Red edge is always used in both directions.. g5 g4. h2 h1. Exchange between di ’s Exchange between ei ’s. g6. h4 h3. Red edge is used. Exchange between bi ’s. Z. Routing on Mesh Networks.

(38) Introduction 5:36. Recall. Simple Routings. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. More Routing on Meshes In the following, let D denote the diameter of the network. Observation Every permutation π can be routed along dimension-by-dimension paths in at most D steps on M(n, 1) and M(n, 2). Lemma Consider M(n, 3). There is a permutation π such that every packet routing algorithm using dimension-by-dimension paths needs at least Ω(D 2 ) steps for routing π. Question: Can one achieve time complexity O(D) on meshes of dimension d > 2?. Idea: Translate the routing algorithm for permutation networks into an efficient algorithm for mesh networks..

(39) Introduction 5:37. Recall. Simple Routings. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Notation Notation (d-dimensional mesh of side length n) Let n ≥ 1 and d ≥ 0 be integers. The d-dimensional mesh of side length n, denoted M(n, d), is the graph G ({0, 1, ..., n − 1}d , E ) with E = { {a, b} | ∃i ∈ {0, 1, ..., d − 1} : |ai − bi | = 1 and aj = bj , for j 6= i } . M(n, d) has nd nodes and d · nd − d · nd−1 edges. The diameter of a M(n, d)-mesh is d · (n − 1).. For fixed numbers i ∈ {0, 1, ..., d − 1}, ` ∈ {0, 1, ..., n − 1}, the subgraph M(n, d)|{a∈{0,1,...,n−1}d |ai =`} is isomorpic to M(n, d − 1). For a fixed vector b ∈ {0, 1, ..., n − 1}d−1 , the subgraph M(n, d)|{a∈{0,1,...,n−1}d |a=ib} is isomorphic to M(n, 1)..

(40) Introduction 5:38. Recall. Disjoint Path Lemma. Simple Routings. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. Example of the Decomposition Illustration of the decomposition of M(n, d) into: n submeshes M0 , ..., Mn−1 and one of the columns Ab :. WS2016/17.

(41) Introduction 5:39. Recall. Disjoint Path Lemma. Annexstein and Baumslag. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Annexstein and Baumslag Theorem (Annexstein and Baumslag 1990) M(n, d) can route a permutation in time O(n · d) = O(D). Proof We ’simulate’ the (n, d)-PN on M(n, d).. Decompose M(n, d) into n submeshes M0 , M1 , ..., Mn−1 of dimension d − 1 by fixing the last digit of the label, that is, for i ∈ {0, 1, ..., n − 1}, Mi := M(n, d)|{a∈{0,1,...,n−1}d |ad−1 =i} . Each of these submeshes Mi “plays the role” of a sub-PN B (i) . These submeshes are connected by one-dimensional meshes (columns), one for each d − 1-dimensional vector b ∈ {0, 1, ..., n − 1}d−1 , namely Ab := M(n, d)|{a|a=ib} ..

(42) Introduction 5:40. Recall. Disjoint Path Lemma. Annexstein and Baumslag. Example of the Decomposition. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17.

(43) Introduction 5:41. Recall. Disjoint Path Lemma. Annexstein and Baumslag. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Proof Analogous to the algorithm for permutation networks, we color the requests (packets) with n colors. The following algorithm then performs the routing: Packets with color i route from their sources to submesh Mi (inside the corresponding column Ab ). In each submesh Mi : Each packet is routed from the position isomorphic to its source to the position isomorpic to its destination. (The permutation routing problem in Mi is solved recursively.) Packets route from submesh Mi to their destinations (inside the corresponding column Ab ) Analysis of the time complexity: Let T (n, d) be the routing time for M(n,d). d =1: d >1:. T (n, 1) T (n, d). = =. n−1 T (n, 1) + T (n, d − 1) + T (n, 1). Solving the recurrence gives T (n, d) = (2d − 1)(n − 1) ≤ 2D..

(44) Introduction 5:42. Recall. Annexstein and Baumslag. Disjoint Path Lemma. Z. Routing on Mesh Networks. Walter Unger 30.1.2017 12:01. WS2016/17. Literature B. Vöcking. Theory of Distributed Systems, Lecture Summer 2012. D. Peleg. Distributed Computing: A Locality-Sensitive Approach, Society for Industrial and Applied Mathematics (SIAM), 2000 H. Attiya, J. Welch. Distributed Computing: Fundamentals, Simulations and Advanced Topics, John Wiley and Sons, 2004 F. T. Leighton. Introduction to Parallel Algorithms and Architectures: Arrays, Trees, Hypercubes, Morgan Kaufmann Publishers, 1991 J. Kleinberg, E. Tardos.Algorithm Design, Addison Wesley Pearson, 2005 J.F. Kurose, K.W. Ross. Computer Networking: A Top-Down Approach Featuring the Internet, Addison Wesley Longman, 1999 N. Nisan, T. Roughgarden, E. Tardos, V. Vazirani. Algorithmic Game Theory, Cambridge University Press, 2007.

(45) Fragen 6. Inhaltsverzeichnis. Walter Unger 30.1.2017 12:01. Legende : Nicht relevant : Grundlagen, die implizit genutzt werden : Idee des Beweises oder des Vorgehens : Struktur des Beweises oder des Vorgehens : Vollständiges Wissen. WS2016/17. Z.

(46)

Referenzen

ÄHNLICHE DOKUMENTE

• If a student is not able to present a correct solution although he/she marked the exercise as presentable, he/she will lose all of his/her points on the exercise sheet. Exercise

1:3 Systolic Arrays and Vector Computer 1/6 Walter Unger 30.1.2017 11:52 WS2016/17 Z.

Each processor uses Rng J,L and Rng K,L to know the area to write its output sequence.... Rng L,K to know the area to read its

5 MIS Introduction MIS and Coloring Small Domination Set Randomized Distributed MIS.. 6 Coloring III

Total running time: O(log n) using O(n) processors. Combine the cycles into pairs of layers of bigger correctly

The following algorithm then performs the routing: Packets with color i route from their sources to submesh Mi inside the corresponding column Ab.. In each submesh Mi : Each packet

The routing time needed by any greedy scheduling policy is at most C · D steps because each packet can be delayed at most for C − 1 steps on each edge on its routing path...

Gossip Introduction First Results Lines Trees Cycles HQ Hypercube CCC and BF Telephone-Mode Odd Number of Nodes Telegraph-Mode Lower Bound Summary Telegraph-Mode Edge Disjoint