Ferianakademie 2010 Course 2: Distance Problems: Theory and Praxis. Distance Labelings. Stepahn M. Günther. September 23, 2010

Similar documents
Trees. Arash Rafiey. 20 October, 2015

Λέων-Χαράλαμπος Σταματάρης

1 Variations of the Traveling Salesman Problem

Dynamic programming. Trivial problems are solved first More complex solutions are composed from the simpler solutions already computed

Fixed-Parameter Algorithms, IA166

Section 3.1: Nonseparable Graphs Cut vertex of a connected graph G: A vertex x G such that G x is not connected. Theorem 3.1, p. 57: Every connected

Labeling Schemes for Flow and Connectivity

Compact Routing with Slack

An Optimal Algorithm for the Euclidean Bottleneck Full Steiner Tree Problem

Forbidden-Set Labeling on Graphs

Lecture 7. s.t. e = (u,v) E x u + x v 1 (2) v V x v 0 (3)

Average Case Analysis for Tree Labelling Schemes

Exact Algorithms Lecture 7: FPT Hardness and the ETH

Labeling Schemes for Vertex Connectivity

1. [1 pt] What is the solution to the recurrence T(n) = 2T(n-1) + 1, T(1) = 1

Spanners of Complete k-partite Geometric Graphs

Problem Set 2 Solutions

6.856 Randomized Algorithms

Space vs Time, Cache vs Main Memory

Lecture 6: Linear Programming for Sparsest Cut

Lecture 4: September 11, 2003

DO NOT RE-DISTRIBUTE THIS SOLUTION FILE

Exercise set 2 Solutions

The self-minor conjecture for infinite trees

arxiv: v1 [cs.cg] 4 Dec 2007

Solutions for the Exam 6 January 2014

Number Theory and Graph Theory

arxiv:math/ v3 [math.co] 24 Dec 1999

On the Complexity of Multi-Dimensional Interval Routing Schemes

Applied Mathematics Letters. Graph triangulations and the compatibility of unrooted phylogenetic trees

Approximating Node-Weighted Multicast Trees in Wireless Ad-Hoc Networks

Efficient Bufferless Packet Switching on Trees and Leveled Networks

Faster parameterized algorithms for Minimum Fill-In

{ 1} Definitions. 10. Extremal graph theory. Problem definition Paths and cycles Complete subgraphs

Notes on Binary Dumbbell Trees

A graph is a set of objects (called vertices or nodes) and edges between pairs of nodes.

arxiv: v3 [cs.dm] 12 Jun 2014

Vertex-Colouring Edge-Weightings

GIAN Course on Distributed Network Algorithms. Spanning Tree Constructions

Reducing Directed Max Flow to Undirected Max Flow and Bipartite Matching

Algorithms for Finding Dominators in Directed Graphs

Given a graph, find an embedding s.t. greedy routing works

Trees Rooted Trees Spanning trees and Shortest Paths. 12. Graphs and Trees 2. Aaron Tan November 2017

Probabilistic embedding into trees: definitions and applications. Fall 2011 Lecture 4

DATA STRUCTURES AND ALGORITHMS

Solutions. (a) Claim: A d-ary tree of height h has at most 1 + d +...

Applications of BDF and DFS

Lecture 2 - Graph Theory Fundamentals - Reachability and Exploration 1

Fully dynamic algorithm for recognition and modular decomposition of permutation graphs

Distributed Algorithms 6.046J, Spring, 2015 Part 2. Nancy Lynch

22 Elementary Graph Algorithms. There are two standard ways to represent a

Theory of Computing. Lecture 4/5 MAS 714 Hartmut Klauck

Advanced Algorithms Class Notes for Monday, October 23, 2012 Min Ye, Mingfu Shao, and Bernard Moret

ACO Comprehensive Exam March 19 and 20, Computability, Complexity and Algorithms

The k-center problem Approximation Algorithms 2009 Petros Potikas

Properties of red-black trees

Notes for Lecture 24

Graphs. Graph G = (V, E) Types of graphs E = O( V 2 ) V = set of vertices E = set of edges (V V)

Greedy Algorithms CHAPTER 16

Generating edge covers of path graphs

arxiv: v1 [cs.ds] 1 May 2015

Final Exam in Algorithms and Data Structures 1 (1DL210)

Lecture 4: Primal Dual Matching Algorithm and Non-Bipartite Matching. 1 Primal/Dual Algorithm for weighted matchings in Bipartite Graphs

On the Minimum k-connectivity Repair in Wireless Sensor Networks

Communication Networks I December 4, 2001 Agenda Graph theory notation Trees Shortest path algorithms Distributed, asynchronous algorithms Page 1

Distributed minimum spanning tree problem

Lecture 6: Shortest distance, Eulerian cycles, Maxflow

An Algorithm for Enumerating All Spanning Trees of a Directed Graph 1. S. Kapoor 2 and H. Ramesh 3

Distributed Algorithms 6.046J, Spring, Nancy Lynch

Sparse Hypercube 3-Spanners

Embedded Width, A Variation of Treewidth for Planar Graphs

Interval Stabbing Problems in Small Integer Ranges

Trees. 3. (Minimally Connected) G is connected and deleting any of its edges gives rise to a disconnected graph.

Computational Geometry

( ) D. Θ ( ) ( ) Ο f ( n) ( ) Ω. C. T n C. Θ. B. n logn Ο

Paths, Flowers and Vertex Cover

Diversity Coloring for Distributed Storage in Mobile Networks

Analyze the obvious algorithm, 5 points Here is the most obvious algorithm for this problem: (LastLargerElement[A[1..n]:

Basic Approximation algorithms

Solution for Homework set 3

The 3-Steiner Root Problem

Lecture #7. 1 Introduction. 2 Dijkstra s Correctness. COMPSCI 330: Design and Analysis of Algorithms 9/16/2014

31.6 Powers of an element

Algebraic method for Shortest Paths problems

Approximation scheme for the traveling salesman problem

Monotone Paths in Geometric Triangulations

Practical Session No. 12 Graphs, BFS, DFS, Topological sort

Fast algorithms for max independent set

Characterization of Networks Supporting Multi-dimensional Linear Interval Routing Scheme

CS200: Graphs. Rosen Ch , 9.6, Walls and Mirrors Ch. 14

Distributed computing of efficient routing schemes in generalized chordal graphs

K 4 C 5. Figure 4.5: Some well known family of graphs

On Covering a Graph Optimally with Induced Subgraphs

DOUBLE DOMINATION CRITICAL AND STABLE GRAPHS UPON VERTEX REMOVAL 1

Bounds on distances for spanning trees of graphs. Mr Mthobisi Luca Ntuli

CSE Winter 2015 Quiz 1 Solutions

Discrete mathematics

GEODETIC DOMINATION IN GRAPHS

These notes present some properties of chordal graphs, a set of undirected graphs that are important for undirected graphical models.

Reachability in K 3,3 -free and K 5 -free Graphs is in Unambiguous Logspace

Transcription:

Ferianakademie 00 Course : Distance Problems: Theory and Praxis Distance Labelings Stepahn M. Günther September, 00 Abstract Distance labels allow to infer the shortest distance between any two vertices of a graph given their labels. It is straight-forward to construct such labels by listing the single source shortest path distances for each vertex. For a graph with n vertices this results in a memory requirement of O(nlogn) bits per vertex and constant lookup time. The question arises whether there are labeling schemes which allow for smaller labels at cost of lookup time. Such a scheme might be useful to reduce the size of routing tables in sensor networks which typically consist of nodes with very limited storage and processing capabilities. Instead of storing the next-hop for all possible destinations it is sufficient to store the labels of neighboring nodes. Once a packet arrives its destination label can be used to determine the distance between all neighboring nodes and the packet s destination. The next-hop is then given by the neighbor with minimum distance to the packet s destination. This report discusses a labeling scheme introduced by Gavoille et al. in [GPPR0] for general, connected, and undirected graphs with unit edge weights. It allows for O(n) bit labels per vertex and a lookup time of O(loglogn). Schemes which allow for sub linear sized labels are available for certain classes of graphs and are discussed in [GPPR0].

Contents Introduction Preliminaries. Dominating sets and dominating collections....................... Determining dominating sets............................... Upper bound for general graphs 6. Creating labels...................................... 6. Decoding labels....................................... Size of labels........................................ Time needed for decoding................................ Conclusion 8 A Label sizes 8

(0,0,,,) (0,0,,,) (,,,0,) (,,,,0) (,,,0,) (,,,,0) (,,0,,) (,,0,,) (a) f(l(),l()) = d(,) = (b) f(l(),l()) = d(,) = Figure : The rank of vertices u V = {,,,} is given by their ordering according to V. In (a) the rank of vertex is read from label L() and used as index in the list of distances stored in L() which gives the distance d(,). A second example is shown in (b). Introduction We denote an undirected graph by G = (V,E) where V is the set of vertices and E V V the set of edges. A graph belongs to a certain class G of graphs. For the scope of this report we only discuss the class of general, connected, and undirected graphs with unit edge weights. Further we denote the shortest distance between vertices u,v V by d(u,v). A distance labeling scheme is defined as tuple L,f where L denotes the set of labels L(u) for all u V and f represents a valid distance decoder, i.e. f(l(u),l(v)) = d(u,v), u,v V. () A trivial distance labeling scheme is given as follows. Choose an arbitrary but fixed ordering of vertices in V. Assign to each vertex u V a label consisting of two fields (a) the rank order(u) according to the ordering of V and (b) the list of distances {d(u,v) v V}. Thus, each label needs logn+nlogn O(nlogn) bits of memory. Given two labels L(u) and L(v) one can easily compute the shortest distance between u and v by using field (a) of label L(v) as index in field (b) of label L(u). An example is given in Figure. Preliminaries The distance labeling scheme presented in Section relies on the hierarchical decomposition of a graph into dominating sets which are introduced in this section. Furthermore, an algorithm to determine dominating sets of limited size is outlined.. Dominating sets and dominating collections Given a graph G = (V,E), a subset S V of nodes is called ρ-dominating set if We call node u S dominator of v if v V u S : d(u,v) ρ. () v = argmind(u,v). () u S

ρ ρ ρ ρ u d(u, v) d(x, y) x y v x d(u, v) u d(x, y) v y (a) Lower bound for d(x,y) given d(u,v) (b) Upper bound for d(x,y) given d(u,v) Figure : Distance between dominators Let d max denote the maximum distance between two vertices in V. Then, for ρ d max any single vertex u V forms a ρ-dominating set. Conversely, from ρ = 0 follows that S = V since each vertex dominates only itself. For a vertex u V we denote the dominator of u with respect to the dominating set S by dom S (u). If the distance between the dominators of two vertices is known, the distance between those two nodes is bounded by the following lemma. Lemma.. Given a graph G = (V,E) and a ρ-dominating set S, then for every two vertices x,y V the following two facts hold:. d(dom S (x),dom S (y)) ρ d(x,y) d(dom S (x),dom S (y))+ρ. The distance d(x,y) can be derived if the dominating radius ρ, the value d(x,y) mod (ρ+), and the distance between dominators d(dom S (x),dom S (y)) are known. Proof. Fact () can easily be seen when considering Figure. The dominators for x,y V are given by dom S (x) = u and dom S (y) = v. Since d(x,u) ρ and d(y,v) ρ, the distance between x and y is bounded below by d(u,v) ρ and bounded above by d(u,v) + ρ. Fact () holds since () defines a range of ρ + consecutive values and exactly one of these values equals to d(x,y) mod (ρ+). Given a graph G and a decreasing sequence of integers {ρ i } for 0 i k with ρ k = 0, we call the set of ρ i -dominating sets S = {(S i,ρ i ) 0 k i} () a dominating collection for G. The dominating sets S i typically become progressively larger with increasing index since ρ i decreases. The set S k consists of all vertices v V since ρ k is declared zero. Such a collection can be seen as a hierarchical decomposition of G where each vertex x S i, i > 0 is dominated by a node x S i.. Determining dominating sets Although any ρ-dominating set also forms a ρ -dominating set for ρ > ρ we are interested in small dominating sets. Ideally, we would choose minimum dominating sets. Unfortunately, the problem of deciding whether a given dominating set is a minimum dominating set can be reduced to the set covering problem which is N P-hard. The computational effort to determine minimum

6 8 9 0 9 6 0 8 T 0 T T T T T (a) Perform a BFS on G to construct a spanning tree (b) Assign vertices to buckets T i 9 0 6 8 (c) Vertex 9 dominates its subtree of height ρ 6 8 (d) Vertex dominates the remaining vertices Figure : Construction of a ρ-dominating set for ρ =. dominating sets is therefore not affordable. For this reason we demand dominating sets which are small enough. The following lemma [PU89] gives an upper bound for the size of a ρ-dominating set. Lemma.. For every n-vertex graph G and integer ρ 0 there exists a dominating set S with { } n S max,. () ρ+ Proof. Given a connected and undirected general graph G = (V, E) with unit edge weights a ρ-dominating set S which obeys Lemma. can be found as follows:. Perform a BFS on G to construct a spanning tree T.. Assign vertices v T to buckets T i according to their depth in T.. Starting at an arbitrary leaf l T i with maximal depth i repeat the following steps: Go up ρ nodes yielding an inner vertex w T. Add w to the ρ-dominating set S. Remove the subtree rooted at w and update the affected buckets. If the height of the remaining spanning tree is less than or equal to ρ, add its root to S and terminate. Starting at a leaf l and finding its ρ-th predecessor w ensures that w is a dominator for at least ρ+ vertices namely itself and ρ vertices below it. If there are branches along the path from w to l, then l dominates strictly more than ρ + vertices. By choosing a leaf l in maximum depth it is ensured that the whole subtree rooted at w has height ρ and is thus dominated by w. If the height of the remaining spanning tree is less than or equal to ρ, then the tree s root dominates the remaining vertices and is added to S.

order S0 (u) {d(u,v) v S 0 } (a) Label L 0 (u) of vertex u S 0 L i (dom Si (u)) order Si (u) {d(u,v) mod (ρ i +) v S i } (b) Label L i (u) of vertex u S i Figure : Labels for nodes in S 0 and S i, 0 < i k. An example for the algorithm outlined above is given in Figure. Regarding the time complexity of this algorithm we have to perform a BFS once which takes O( V + E ) O(n ) since E n(n )/. Afterwards, each ρ-dominating set can be constructed by traversing the spanning tree starting at the leafs which takes O(n) steps per set. Upper bound for general graphs Based on the hierarchical decomposition of G, a labeling scheme is discussed in this section which allows for labels linear in size to the number of vertices in G. The upper bounds O(n) for the label size and O(loglogn) for the decoding time are proofed by construction.. Creating labels First, we define a dominating collection S = {(S i,ρ i ) 0 i k} with k = loglogn and ρ i = k i. (6) Given this definition of ρ i and Lemma. it follows directly that S i n k i. Note, that S 0 is the smallest dominating set and that the sets S i become progressively larger. It is easy to verify that ρ k = 0 and thus S k = V for a given graph G = (V,E). The ordering of vertices within a dominating set S i can be is arbitrary but fixed. Once the dominating collection S has been determined labels for vertices are created as follows (see Figure ):. For all nodes u S 0 create labels which consist of the following two fields: (a) The rank order S0 (u) according to the ordering of S 0 (b) The list of distances {d(u,v) v S 0 }. For 0 < i k create labels for all vertices u S i which consist of the following three fields: (a) The label L i (dom Si (u)) of the dominator of u in the set S i (b) The rank order Si (u) according to the ordering of S i (c) The list of distances {d(u,v) mod (ρ i +) v S i } Step () stores the real distances between all vertices u,v S 0. For all other dominating sets S i, 0 < i k the dominator u = dom Si (u) of u S i is determined. The label L i (u ) becomes part of the label L i (u). Additionally, the rank of u according to the order of S i is added. The trick is now not to store the real distances d(u,v) between u and other vertices v S i but the value d(u,v) mod (ρ i +). Thus, the memory required to store a distance value is limited to log(ρ i +) instead of logn bits. Since S k = V, it is made sure that each vertex obtains a valid label. Note, that one would end up with the trivial labeling scheme outlined in Section if S 0 = V (and k = 0) was chosen. 6

. Decoding labels Given two vertices x,y V, the distance d(x,y) can be inferred recursively using the following distance decoder:. Obtain the labels L i (x ) and L i (y ) for x = dom Si (x) and y = dom Si (y) using field (a) of the labels L i (x) and L i (y), respectively. Determine the distance d(x,y ) between the dominators (recursive step). Determine the rank order(y) from field (b) of L i (y). Use order(y) as index in field (c) of L i (x) to determine the value d(x,y) mod (ρ i +). Use Lemma. to infer d(x,y) relying on the fact that S i is a ρ i -dominating set The recursion stops for i = 0 since the distance between vertices in S 0 can be determined directly.. Size of labels The label of any node v V is built over k steps. In each step 0 i k the respective rank order Si according to the ordering of S i is added. Consequently, a total of O(klogn) bits is needed for the ranks. In step i = 0 the real distances between all vertices in S 0 and thus S 0 logn bits per label are stored. For the remaining steps 0 < i k the distances are computed modulo (ρ i +). For this reason, additionally S i log(ρ i + ) bits are needed per label and step. Putting all together we end up with an upper bound for the size of labels which is given by L max S 0 logn+ S i log(ρ i +)+O(klogn). () i= For the individual terms we obtain S 0 logn n logn = n n logn = logn = n, k loglogn logn S i log(ρ i +) 8n (see Appendix A), and i= O(klogn) O(loglognlogn). Thus, the label size L max is bounded by 9n+Ologlogn O(n).. Time needed for decoding The individual steps for decoding outlined in Section. are basically lookup operations in arrays (obtaining labels, the rank of nodes, distance values, and computing distances according to Lemma.) and thus require constant time. The number of recursive steps is bounded above by k = loglogn. Consequently, the time needed for decoding is in O(loglogn).

Conclusion We have seen a distance labeling scheme for general graphs with unit edge weights which allows for label sizes linear in the number of vertices. The upper bound was explicitly derived. A lower bound is shown in [GPPR0]. Furthermore, for specific classes of graphs even better schemes are shown in [GPPR0]. In particular, the bounds Θ(log n) for trees, O( nlogn) and Ω(n / ) for planar graphs, and Ω( n) for bounded degree graphs. are derived. A Label sizes In Section. it is claimed that S i log(ρ i +) 8n. i= Recall, that k = loglogn, ρ i = k i and thus S i n k i. Then we obtain S i log(ρ i +) = i= n = n n = n i= ( k [ i= ( k i+ = n k i + 0 + x [ ] x xi+ x= ] x i+ ( [ ] ( x) x= x= + n k i log( (k i+ )+) = n k + ) log( k i+ ) i= ) k + k +...+ = n k ) [ ] k + = n k x i+ i i x x= ( [ ] ) = n + i x x = 8n. x= k i i+ i = n k + ( k i + k i i ) i References [GPPR0] Cyril Gavoille, David Peleg, Stéphane Pérennes, and Ran Raz. Distance labeling in graphs. Journal of Algorithms, :8, 00. [PU89] David Peleg and Eli Upfal. A tradeoff between space and efficiency for routing tables. Journal of the ACM, ():0 0, 989. 8