Upload
julie-cox
View
215
Download
0
Embed Size (px)
Citation preview
1
Broadcast
2
3
Use a spanning tree
Root
4
synchronous
•It takes the same time at link to send a message•It takes the same time at each node to process the incoming data
5
6
7
Time complexity:
d levels
n nodes
Message complexity:
)(dO)(nO
8
asynchronous
Links and nodes may have different delays
9
10
slowlink
11
slowlink
12
Actualdelivery
13
14
Time complexity:
d levels
n nodes
Message complexity:
)(dO)(nO
15
Convergecast
16
synchronous
17
18
19
20
Time complexity:
d levels
n nodes
Message complexity:
)(dO)(nO
21
asynchronous
22
23
24
25
26
Time complexity:
d levels
n nodes
Message complexity:
)(dO)(nO
27
Building a BFS Spanning Tree
28
Tree algorithm for node :
Upon receipt of <invitation> messagefrom neighbor node :
If not member of tree:
v
accept invitation by sending <accept> message to ;
u
v (the father)
If member of tree:decline invitation by sending <reject> message to ; v
Send invitations to all neighbors, except v
29
synchronous
30
A node initiates the BFS process
<invitation><invitation>
31
become membersof tree
32
<accept><accept>
33
34
35
<reject>
36
37
38
<reject>
39
40
41
Alternative solution
42
43
reject
44
45
46
Time complexity:
D diameter
n nodes
Message complexity:
)(DO)(mO
m edges
47
asynchronous
48
49
50
51
52
slow node
53
54
55
56
57
58
reject
59
60
61
reject
62
63
Time complexity:
D diameter
n nodes
Message complexity:
)(DO)(mO
m edges
64
The asynchronous algorithm may give deeper trees than the diameter
Example:
Clique graph
Synchronous BFS Asynchronous BFS
65
Building a DFS Spanning Tree
66
12
11
2
3
1
23
1
23
1
2
12
34
2
34
67
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
68
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
69
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
70
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
71
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
72
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
73
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1reject
74
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
75
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
76
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
77
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
78
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
reject
79
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
80
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
reject
81
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
82
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
83
Time complexity:
n nodes
Message complexity:
)(mO)(mO
m edges 12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
84
Building a DFS Spanning Treewith no specified root
85
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
8
1
86
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
8
1
8
1
87
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
8
1
8
181
88
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
8
1
8
181
89
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
8
1
8
881
90
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
8
1
8
881
91
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
8
1
8
881
reject
92
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
8
1
8
881
93
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
8
8
8
881
94
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
8
8
8
881
8
95
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
8
8
8
881
8
8
96
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
8
8
8
881
8
8
97
12
11
2
3
1
23
1
23
1
2
12
34
2
34
8
8
8
8
881
8
8
98
12
11
2
3
1
23
1
23
1
2
12
34
2
34
8
8
8
8
881
8
8
99
12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
8
8
8
881
8
8
root
100
Time complexity:
n nodes
Message complexity:
)(mO)( mnO
m edges 12
11
2
3
1
23
1
23
1
2
12
34
2
34
1
8
8
8
881
8
8
root