On the Graph Decomposition

Slides:



Advertisements
Similar presentations
1 Decomposing Hypergraphs with Hypertrees Raphael Yuster University of Haifa - Oranim.
Advertisements

Transitive Closure Compression Jan. 2013Yangjun Chen ACS Outline: Transitive Closure Compression Motivation DAG decomposition into node-disjoint.
Global Flow Optimization (GFO) in Automatic Logic Design “ TCAD91 ” by C. Leonard Berman & Louise H. Trevillyan CAD Group Meeting Prepared by Ray Cheung.
Parallel Scheduling of Complex DAGs under Uncertainty Grzegorz Malewicz.
Lectures on Network Flows
Yangjun Chen 1 Bipartite Graphs What is a bipartite graph? Properties of bipartite graphs Matching and maximum matching - alternative paths - augmenting.
Implementation of Graph Decomposition and Recursive Closures Graph Decomposition and Recursive Closures was published in 2003 by Professor Chen. The project.
VLSI Layout Algorithms CSE 6404 A 46 B 65 C 11 D 56 E 23 F 8 H 37 G 19 I 12J 14 K 27 X=(AB*CD)+ (A+D)+(A(B+C)) Y = (A(B+C)+AC+ D+A(BC+D)) Dr. Md. Saidur.
An Efficient Algorithm for Answering Graph Reachability Queries Yangjun Chen, Yibin Chen Dept. Applied Computer Science, University of Winnipeg 515 Portage.
Validating Streaming XML Documents Luc Segoufin & Victor Vianu Presented by Harel Paz.
Yangjun Chen 1 Bipartite Graph 1.A graph G is bipartite if the node set V can be partitioned into two sets V 1 and V 2 in such a way that no nodes from.
Recursive Graph Deduction and Reachability Queries Yangjun Chen Dept. Applied Computer Science, University of Winnipeg 515 Portage Ave. Winnipeg, Manitoba,
V. V. Vazirani. Approximation Algorithms Chapters 3 & 22
TEDI: Efficient Shortest Path Query Answering on Graphs Author: Fang Wei SIGMOD 2010 Presentation: Dr. Greg Speegle.
GRAPHS CSE, POSTECH. Chapter 16 covers the following topics Graph terminology: vertex, edge, adjacent, incident, degree, cycle, path, connected component,
UNC Chapel Hill Lin/Foskey/Manocha Minimum Spanning Trees Problem: Connect a set of nodes by a network of minimal total length Some applications: –Communication.
A Clustering Algorithm based on Graph Connectivity Balakrishna Thiagarajan Computer Science and Engineering State University of New York at Buffalo.
1 Closures of Relations: Transitive Closure and Partitions Sections 8.4 and 8.5.
Data Structures & Algorithms Graphs
Relations and their Properties
Agenda Review: –Planar Graphs Lecture Content:  Concepts of Trees  Spanning Trees  Binary Trees Exercise.
Computing Branchwidth via Efficient Triangulations and Blocks Authors: F.V. Fomin, F. Mazoit, I. Todinca Presented by: Elif Kolotoglu, ISE, Texas A&M University.
Pipelined and Parallel Computing Partition for 1 Hongtao Du AICIP Research Nov 3, 2005.
GRAPHS. Graph Graph terminology: vertex, edge, adjacent, incident, degree, cycle, path, connected component, spanning tree Types of graphs: undirected,
Chapter 8: Relations. 8.1 Relations and Their Properties Binary relations: Let A and B be any two sets. A binary relation R from A to B, written R : A.
A New Top-down Algorithm for Tree Inclusion Dr. Yangjun Chen Dept. Applied Computer Science, University of Winnipeg 515 Portage Ave. Winnipeg, Manitoba,
Iterative Improvement for Domain-Specific Problems Lecturer: Jing Liu Homepage:
Chapter 11. Chapter Summary  Introduction to trees (11.1)  Application of trees (11.2)  Tree traversal (11.3)  Spanning trees (11.4)
On the Intersection of Inverted Lists Yangjun Chen and Weixin Shen Dept. Applied Computer Science, University of Winnipeg 515 Portage Ave. Winnipeg, Manitoba,
Representing Relations Using Digraphs
Relations and Their Properties
Directed Graphs Directed Graphs Shortest Path 12/7/2017 7:10 AM BOS
IOI/ACM ICPC Training 4 June 2005.
A Linear-Space Top-down Algorithm for Tree Inclusion Problem
Relations Binary relations represent relationships between the elements of two sets. A binary relation R from set A to set B is defined by: R  A 
Chapter - 12 GRAPH MATRICES AND APPLICATIONS.
School of Computing Clemson University Fall, 2012
Week 6 - Wednesday CS 113.
Special Graphs By: Sandeep Tuli Astt. Prof. CSE.
Parallel Tasks Decomposition
By: Sibo Wang, Xiaokui Xiao, Yin Yang, Wenqing Lin
Computing Connected Components on Parallel Computers
Graph theory Definitions Trees, cycles, directed graphs.
Computing Full Disjunctions
Bipartite Graphs What is a bipartite graph?
Lectures on Network Flows
PC trees and Circular One Arrangements
Auburn University COMP8330/7330/7336 Advanced Parallel and Distributed Computing Communication Costs (cont.) Dr. Xiao.
Chapter 5. Optimal Matchings
Topological Sort (topological order)
The Taxi Scheduling Problem
Outline: Transitive Closure Compression
1.3 Modeling with exponentially many constr.
Planarity Testing.
Graphs Graph transversals.
3.3 Applications of Maximum Flow and Minimum Cut
ICS 353: Design and Analysis of Algorithms
Great Theoretical Ideas in Computer Science
Lectures on Graph Algorithms: searching, testing and sorting
Connectivity Section 10.4.
1.3 Modeling with exponentially many constr.
Bipartite Graph 1. A graph G is bipartite if the node set V can be partitioned into two sets V1 and V2 in such a way that no nodes from the same set are.
Uncapacitated Minimum Cost Problem in a Distribution Network
Text Book: Introduction to algorithms By C L R S
V12 Menger’s theorem Borrowing terminology from operations research
HW 3 (Due Wednesday Feb 6) Create slide(s) for your 1 minute presentation on a graph theory application. Make sure your slide(s) include (1) Define the.
Binhai Zhu Computer Science Department, Montana State University
DAGs Longin Jan Latecki
Minimum Spanning Trees
Presentation transcript:

On the Graph Decomposition Yangjun Chen and Yibin Chen Dept. Applied Computer Science, University of Winnipeg 515 Portage Ave. Winnipeg, Manitoba, Canada R3B 2E9

Outline Motivation Graph stratification Main algorithm - Bipartite graphs and virtual nodes - Chain generation - Resolving virtual nodes Summary

Motivation Graph decomposition into node-disjoint chains Given a directed acyclic graph G, decompose it into a minimum set of node-disjoint chains, which cover all the nodes of G. For any two nodes u and v on a chain, if u is above v then there is a path from u to v in G. Application - Decomposition of a partially ordered sets (posets) into a minimum set of chains - Compress transitive closures of graphs

Motivation a1 a2 a1 a2 a1 a2   a3 a3 a3 a4 a4 a4 a5 a6 a5 a6 a5 a6  

Motivation Compression of transitive closures O(n2) O(n) index Index sequence 1 2   a3 (1, 1) a1 (2, 1) a2 (1, 1)(2, 2) (1, 2)(2, 1) a4 (1, 1) a3 (2, 2) a4 (1, 2)(2, 2) (1, 3)(2, 2) a5 a6   (1, 3) a5 a6 (2, 3) (1, 3) (2, 3) O(n2) O(n)  - number of chains

Main idea of graph decomposition Stratifying a graph into a series of bipartite graphs: G1, …, Gh. Finding a maximum matching Mi for each Gi. (In this process, virtual nodes may be introduced.) Combining all Mi’s to get a set of chains, denoted as M1  …  Gh, which may contain virtual nodes. Removing the virtual nodes to get the final result.

Graph stratification Definition 1 Let G(V, E) be a DAG. We decompose V into subsets V0, V1, ..., Vh such that V = V0  V1  ...  Vh and each node in Vi has its children appearing only in Vi-1, ..., V0 (i = 1, ..., h), where h is the height of G, i.e., the length of the longest path in G.  q r s V4: q r s n o p m V3: n o p m j k l t i V2: j k l t i g h f x V1: g x h f b y c d e z a b V0: y c d e z a

Graph stratification Dividing a graph into a series of bipartite graphs: V4: q r s V3: n o p m V3: n o p m e a b y d f g h i j k l m n o p q r s t z x c V2: j k l t i V2: j k l t i V1: g x h f V1: g f x h V0: b y c d e z a

Virtual nodes Find a maximum matching for each bipartite graph and then combine them together, by which ‘virtual node’ may be introduced. Definition 2 (virtual nodes) Let G(V, E) be a DAG, divided into V0, ..., Vh (i.e., V = V0  ...  Vh). Let Mi be a maximal matching of B(Vi, Vi-1′; Ci) for i = 1, …, h. For each free node v in Vi-1′ with respect to Mi, a virtual node v′ created for v is a new node added to Vi (1  i  h - 1), denoted as v = s(v′). 

Virtual Nodes Definition 2 (virtual nodes) Let G(V, E) be a DAG, divided into V0, ..., Vh (i.e., V = V0  ...  Vh). Let Mi be a maximal matching of B(Vi, Vi-1′; Ci) for i = 1, …, h. For each free node v in Vi-1′ with respect to Mi, a virtual node v′ created for v is a new node added to Vi (1  i  h - 1), denoted as v = s(v′).  q r s V1: V0: e a b y d g h z x c V4: V3: n o p m V2: j k l t i M1: g x h V1’: g x c’ h e’ z’ f b y c d e z a label(t  e’) = 0 label(j  e’) = 1 label(t  z’) = 0 label(k  c’) = 1 label(i  e’) = 0 label(k  e’) = 1 label(i  z’) = 0 label(l  c’) = 1 label(j  c’) = 1 label(l  e’) = 1

Virtual Arcs inherited arcs - If there is u  Vj (j > i) such that u  v  E, add u  v′, referred to as an inherited arc. transitive arcs - If there exist u  Vj (j > i) and w  Vi such that u  w  E and w  v  Ci, add u  v′ if it has not been created as an inherited arc, referred to as a transitive arc. alternating arcs of the first kind - If there exists a covered node w  Vi-1′ (relative to Mi) such that one of v’s parents is connected to w through an -segment in B(Vi, Vi-1′; Ci), and u  Vj (j > i) such that one of the two conditions holds: u  w  E, or there is a node w′  Vi such that u  w′  E and w′  w  Ci, add u  v′ if it has not been created as an inherited or a transitive arc.

Chain Generation V1: V0: e a b y d g h z x c f g h i j k l t c’ e’ z’ M1: e a b y d g h z x c M2: j k l t i g x c’ h e’ z’ f q r s V4: q r s M3: m n o p i j k l t M4: V3: n o p m o p V2: j k l t i V1’: g x c’ h e’ z’ f

Chain Generation q r s M4: o p q r s M3: m n o p i j k l t n o p m M2: x c’ h e’ z’ f g x c’ h e’ z’ f M1: e a b y d g h z x c b y c d e z a

Chain Generation m n o p q r s f g h i j k l t x a y c d e z b q r s n

Chain Generation m n o p q r s f g h i j k l t x a y c d e z b q r s n

Chain Generation = V( ) = T  S, and Definition 3 (alternating graph) Let B(T, S; E) be a bipartite graph. Let M be a matching of B(T, S; E). The alternating graph with respect to M is a directed graph with the following sets of nodes and arcs: = V( ) = T  S, and = E( ) = {u  v | u  S, v  T, and (u, v)  M}  {v  u | u  S, v  T, and (u, v)  E\M}.  V1: g x h V1: g x h V0: V0: b y c d e z a b y c d e z a M1: g x h b y c d e z a

Chain Generation Next, we will combine two consecutive alternating graphs = (Vi′, Vi-1′; Ci) and = (Vi+1, Vi′; Ci+1), denoted as  , by connecting each node in Vi+1 to all its reachable nodes in Vi-1′. j k l t i V2: V1: g x h f g x h f V1: V0: b y c d e z a

Chain Generation f g h i j k l t x e a y c d z b j k l t i V2: V1: g x A maximum set of node disjoint paths with each starting from a free node u relative to Mi+1 in Vi+1, and ending at a free node v relative to Mi in Vi-1′,

Chain Generation What we want is to find a maximum set S of node-disjoint paths in  , each starting from a free node u relative to Mi+1 in Vi+1, and ending at a free node v relative to Mi in Vi-1′. Let P be such a path with u and v being the starting and ending nodes. We will create a virtual node v´ for v, connect it u. However, for each free node (in Vi-1′) not appearing on such a path, its virtual node will be added to Vi+1, for which only inherited and transitive arcs, as well as a new kind of virtual arcs, called alternating arcs of the second kind will be created.

Chain Generation Alternating arc of the second kind – Let v´ be a virtual node Created for v in Vi-1′ and added to Vi+1. If there exist a free node w  Vi-1′ (relative to Mi) and a node u  Vj (j > i) such that one of v’s parents is connected to w through a -segment in B(Vi′, Vi-1′; Ci), satisfying one of the following two conditions: - u  w  E, or there is an alternating path in (Vi′, Vi-1′; Ci), which does not go through any node in S, but connects w to a node x  Vi-1′ such that x is reachable from u, add u  v′ if it has not been created as an inherited or a transitive arc. label(u  v′) is set to be i, same as an alternating arc incident to a virtual node added to Vi′.

Chain Generation M2: j k c′ l t i q r s V1: V0: V4: V2: V3: e a b y d z c f g h x c′ z′ m n o p i j k l t e′ c′′ g x h e′ z′ f n o p m M3: j k c′ l t i n o p m g x h e′ z′ f j k c′ l t i b y c d e z a M4: q r s label(l  e’) = 1 label(m  c’) = 1 label(t  z) = 0 label(q  c’) = 1 label(q  c) = 1 n o p m

Chain Generation q r s e a b y d q r s z c f g h x c′ z′ m n o p i j k l t e′ c′′ q r s V4: n o c′′ p m n o c′′ V3: p m j k c′ l t i q r s g h M4: x e′ z′ f n o c′′ p m b y c d e z a

Virtual Node Resolution After the chain generation, the next step is to resolve (or say, to remove) virtual nodes from chains. For this purpose, we will work top-down along the chains. Two steps will be carried out: Remove virtual nodes, and at the same time connect some nodes according to the connectivity represented by them, and Establish new connections between free nodes by transferring edges along alternating paths within a bipartite graph or cross more than one bipartite graph.

Virtual Node Resolution When we try to remove virtual nodes v with label(u  v) = i, all the virtual nodes with higher labels must have been eliminated. In this step, the following operations will be conducted. Let v be a virtual node in Vi′. If v does not have a parent along the corresponding chain, it will be simply removed. If v has a parent u along a chain with label(u  v) = 0, remove v and connect u to s(v). label(u  s(v)) is set to 0. Let level(s(v)) = i. Connect u to each reachable node in Vi.

Virtual Node Resolution If v has a parent u along a chain with label(u  v) = i, remove v and connect u to each reachable node in Vi-1. Construct a combined graph in a way similar to the chain generation, involving the corresponding bipartite graphs, where the direction of each arc corresponding to an edge belonging to a maximum matching is reversed.

Virtual Node Resolution q r s q r s n o p m n o p m j k l t i j k l t i g x h g x h z′ f e′ f b y c d e z a b y c d e z a

Virtual Node Resolution q r s q r s n o p m n o p m j k l t i j k l t i j k l t i g x h f g x h f b y c d e z a g x h f b y c d e z a

Virtual Node Resolution q r s q r s n o c′′ p m n o p m j k c′ l t i j k l t i g x h e′ z′ g h f x f b y c d e z a b y c d e z a

Summary A efficient algorithm for graph decomposition - Graph stratification - Algorithm for finding maximum matching for bipartite graphs - Virtual nodes Computational complexities time: O(max{ n, m}) space overhead: O(n)

Thanks you.