updating directed minimum cost spanning trees
play

Updating Directed Minimum Cost Spanning Trees Orestis A. Telelis - PowerPoint PPT Presentation

Introduction Complexity of Updates A dynamic algorithm Experiments Updating Directed Minimum Cost Spanning Trees Orestis A. Telelis joint work with Gerasimos G. Pollatos Vassilis Zissimopoulos Department of Informatics and


  1. Introduction Complexity of Updates A dynamic algorithm Experiments Updating Directed Minimum Cost Spanning Trees Orestis A. Telelis joint work with Gerasimos G. Pollatos Vassilis Zissimopoulos Department of Informatics and Telecommunications University of Athens, Hellas (Greece) Workshop on Experimental Algorithms, 2006 Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  2. Introduction Complexity of Updates A dynamic algorithm Experiments Outline 1 Introduction 2 Complexity of Updates 3 A dynamic algorithm The ATree structure Edge Deletion Edge Insertion Implementation and Complexity 4 Experiments Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  3. Introduction Complexity of Updates A dynamic algorithm Experiments Introduction A DMST is a min-cost subset of (directed) edges T ⊆ E such that: 1 T is acyclic 2 ( u , v ) , ( x , y ) ∈ T ⇒ v � = y 3 T is maximal with respect to 1 and 2. Branchings vs. Trees G strongly connected ⇒ a DMST T is a tree of n − 1 edges. Otherwise T may be forest of directed trees called branching. We can always augment G with infinite cost edges to make it strongly connected. Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  4. Introduction Complexity of Updates A dynamic algorithm Experiments Algorithms For a digraph G ( V , E ), | V | = n , | E | = m : 1 Same algorithm ( Edmonds’ algorithm ) independently by: Edmonds 1967, Chu& Liu 1965, Bock 1971: O ( mn ) 2 Best known implementation for general digraphs: Gabow, Galil, Spencer, Tarjan 1986: O ( m + n log n ) 3 Best known implementation for sparse digraphs ( O ( n ) edges): Mendelson, Tarjan, Thorup, Zwick, 2004: O ( m log log n ) Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  5. Introduction Complexity of Updates A dynamic algorithm Experiments Dynamic Updates Efficiently updating the DMST T ⊆ E of a digraph G ( V , E ) when: 1 An edge is deleted from the graph. 2 An edge is inserted to the graph. ... in less time than re-evaluating it from scratch. The dynamic complexity of DMST is not known. For MST see Holm, de Lichtenberg, Thorup, JACM 2001 Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  6. Introduction Complexity of Updates A dynamic algorithm Experiments Is it Possible? DMST on a Directed Acyclic Graph: For each v ∈ V choose the min-cost incoming edge. Cycles will not occur. Verification Time on a DAG cost ( T ) minimum iff ∀ ( u , v ) ∈ T min-cost edge entering v . This amounts testing O ( m ) inequalities. Ω( m ) time is required (Rabin 1972). Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  7. Introduction Complexity of Updates A dynamic algorithm Experiments A weak lower bound 1 1 1 1 v 0 v 1 v 2 v 3 v 4 1 + ǫ 1 + ǫ 1 + ǫ 1 + ǫ Sensitivity to edge operations Removal of ( v 3 , v 4 ) from the digraph and the DMST... Theorem Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  8. Introduction Complexity of Updates A dynamic algorithm Experiments A weak lower bound 1 1 1 1 v 0 v 1 v 2 v 3 v 4 1 + ǫ 1 + ǫ 1 + ǫ 1 + ǫ Sensitivity to edge operations ... causes the DMST to change entirely! At least verification time is required to update: Ω( n 2 ) for dense digraphs. Theorem A dynamic algorithm retaining and using only the DMST itself requires Ω( m ) time, which is Ω( n 2 ) for dense digraphs. Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  9. Introduction Complexity of Updates A dynamic algorithm Experiments Note: O (log n ) Update Time on DAGs For each vertex v store its incoming edges in a FHeap H ( v ). Deletion of ( u , v ) ∈ E from G ( V , E ): ( u , v ) ∈ T : extract least-cost e from H ( v ) to replace ( u , v ). 1 ( u , v ) �∈ T : decrease-cost to −∞ of ( u , v ) in H ( v ) and extract 2 ( u , v ) from H ( v ). Insertion of ( u , v ) to E : ∃ ( x , v ) ∈ T with cost ( x , v ) ≤ cost ( u , v ): insert ( u , v ) in H ( v ). 1 ∃ ( x , v ) ∈ T with cost ( x , v ) > cost ( u , v ): replace ( x , v ) with 2 ( u , v ) and insert ( x , v ) in H ( v ). Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  10. Introduction The ATree structure Complexity of Updates Edge Deletion A dynamic algorithm Edge Insertion Experiments Implementation and Complexity An algorithm for dynamic updates A dynamization of Edmonds’ algorithm: Encode output into an Augmented Tree (ATree) structure. Modify the data structure per edge operation. Identify maximal portion of unaffected output to maintain. Execute a modified implementation to augment the maintained output. Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  11. Introduction The ATree structure Complexity of Updates Edge Deletion A dynamic algorithm Edge Insertion Experiments Implementation and Complexity Edmonds’ Algorithm 1 Set v = v 0 . 2 Repeat until a single vertex remains: Select the min-cost edge entering v , say ( u , v ). 1 For each edge ( x , v ) set cost ( x , v ) ← cost ( x , v ) − cost ( u , v ). 2 Contract dicycle (if any) due to ( u , v ), to vertex u . 3 Set v = u . 4 3 Remove redundant selected edges. Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  12. Introduction The ATree structure Complexity of Updates Edge Deletion A dynamic algorithm Edge Insertion Experiments Implementation and Complexity Edmonds’ Algorithm 1 Set v = v 0 . 2 Repeat until a single vertex remains: [ O ( m + n log n ) Time] Select the min-cost edge entering v , say ( u , v ). 1 For each edge ( x , v ) set cost ( x , v ) ← cost ( x , v ) − cost ( u , v ). 2 Contract dicycle (if any) due to ( u , v ), to vertex u . 3 Set v = u . 4 3 Remove redundant selected edges. [ O ( n ) Time] We dynamize the loop Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  13. Introduction The ATree structure Complexity of Updates Edge Deletion A dynamic algorithm Edge Insertion Experiments Implementation and Complexity Example on Edmonds’ Algorithm Next Step Take the least cost edge entering vertex a . That is edge ( b , a ). 2 a d 10 1 1 1 1 c 2 b Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  14. Introduction The ATree structure Complexity of Updates Edge Deletion A dynamic algorithm Edge Insertion Experiments Implementation and Complexity Example on Edmonds’ Algorithm Next Step Take the least cost edge entering vertex b . That is edge ( a , b ). Reduce the cost of ( c , b ) to 2 − cost ( a , b ) = 2 − 1 = 1. 2 a d 10 1 1 1 1 c 2 b Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  15. Introduction The ATree structure Complexity of Updates Edge Deletion A dynamic algorithm Edge Insertion Experiments Implementation and Complexity Example on Edmonds’ Algorithm Next Step Contract cycle a → b → a into a vertex A . 2 a d 10 1 1 1 1 c 2 − 1 = 1 b Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  16. Introduction The ATree structure Complexity of Updates Edge Deletion A dynamic algorithm Edge Insertion Experiments Implementation and Complexity Example on Edmonds’ Algorithm Next Step Take the least cost edge entering vertex A . That is edge ( c , A ) (which was edge ( c , b )). d 2 10 A 1 1 1 c Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  17. Introduction The ATree structure Complexity of Updates Edge Deletion A dynamic algorithm Edge Insertion Experiments Implementation and Complexity Example on Edmonds’ Algorithm Next Step Take the least cost edge entering c . That is edge ( d , c ). d 2 10 A 1 1 1 c Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  18. Introduction The ATree structure Complexity of Updates Edge Deletion A dynamic algorithm Edge Insertion Experiments Implementation and Complexity Example on Edmonds’ Algorithm Next Step Take the least cost edge entering d . That is edge ( c , d ). Reduce the cost of ( a , d ) to 2 − cost ( c , d ) = 2 − 1 = 1. Reduce the cost of ( b , d ) to 10 − cost ( c , d ) = 10 − 1 = 9. d 2 10 A 1 1 1 c Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  19. Introduction The ATree structure Complexity of Updates Edge Deletion A dynamic algorithm Edge Insertion Experiments Implementation and Complexity Example on Edmonds’ Algorithm Next Step Contract cycle c → d → c into a vertex B . d 1 9 A 1 1 1 c Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  20. Introduction The ATree structure Complexity of Updates Edge Deletion A dynamic algorithm Edge Insertion Experiments Implementation and Complexity Example on Edmonds’ Algorithm Next Step Take the least cost edge entering B . That is edge ( A , B ) (which was edge ( a , d )). 1 9 A B 1 Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

  21. Introduction The ATree structure Complexity of Updates Edge Deletion A dynamic algorithm Edge Insertion Experiments Implementation and Complexity Example on Edmonds’ Algorithm Next Step Contract cycle A → B → A into a vertex C . 1 9 A B 1 Pollatos, Telelis, Zissimopoulos Updating Directed Minimum Cost Spanning Trees

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend