Advanced Graph Algorithms SS 2012 - Max Planck Society · Advanced Graph Algorithms SS 2012...

1
7. Homework Total points: 40 Advanced Graph Algorithms SS 2012 Ran Duan, Jens M. Schmidt, Magnus Wahlström Tutor: Bernhard Schommer Exercise 1: Minimum Spanning Trees (15 points) Assume that all edge weights are pairwise distinct. Consider an algorithm that first performs k steps of Prim’s/Jarník’s algorithm and then contracts all tree edges and applies Borůvka’s algorithm. What is the running time of this algorithm in terms of k, n and m? For which value of k is the running time minimized? Exercise 2: Finding Quadrangle (10 points) Give an O(n ω ) algorithm for finding a quadrangle (a simple cycle of 4 edges) in directed graphs. Exercise 3: Maximum Witness (15 points) In the Boolean matrix product C of two Boolean matrices A and B, if C i,j = 1, then any index k such that A i,k and B k,j are both 1 is a witness for C i,j . The maximum witness for C i,j is the largest possible witness for C i,j . The time complexity for computing the maximum witness for all entries of C is usually denoted by O(n μ ), when A, B are both n × n matrices. Let ω(1, r, 1) denotes the exponent of the time complexity for computing the product of an n × n r matrix and an n r × n matrix. If ω(1, r, 1) 2 if 0 r α 2+ β (r - α) otherwise where α =0.294=0.533, show that μ< 2.575. (Note that by far the maximum witness has the same time complexity as the unweighted directed APSP as given in class.)

Transcript of Advanced Graph Algorithms SS 2012 - Max Planck Society · Advanced Graph Algorithms SS 2012...

Page 1: Advanced Graph Algorithms SS 2012 - Max Planck Society · Advanced Graph Algorithms SS 2012 RanDuan,JensM.Schmidt,MagnusWahlström Tutor:BernhardSchommer ... whereα= 0.294,β= 0.533,showthatµ

7. Homework Total points: 40

Advanced Graph Algorithms SS 2012Ran Duan, Jens M. Schmidt, Magnus Wahlström Tutor: Bernhard Schommer

Exercise 1: Minimum Spanning Trees (15 points)Assume that all edge weights are pairwise distinct. Consider an algorithm that firstperforms k steps of Prim’s/Jarník’s algorithm and then contracts all tree edges andapplies Borůvka’s algorithm. What is the running time of this algorithm in terms ofk, n and m? For which value of k is the running time minimized?

Exercise 2: Finding Quadrangle (10 points)Give an O(nω) algorithm for finding a quadrangle (a simple cycle of 4 edges) indirected graphs.

Exercise 3: Maximum Witness (15 points)In the Boolean matrix product C of two Boolean matrices A and B, if Ci,j = 1, thenany index k such that Ai,k and Bk,j are both 1 is a witness for Ci,j. The maximumwitness for Ci,j is the largest possible witness for Ci,j. The time complexity forcomputing the maximum witness for all entries of C is usually denoted by O(nµ),when A,B are both n× n matrices.Let ω(1, r, 1) denotes the exponent of the time complexity for computing the productof an n× nr matrix and an nr × n matrix. If

ω(1, r, 1) ≤{

2 if 0 ≤ r ≤ α2 + β(r − α) otherwise

where α = 0.294, β = 0.533, show that µ < 2.575. (Note that by far the maximumwitness has the same time complexity as the unweighted directed APSP as given inclass.)