Steiner Tree Problem Assume that the vertices in
Steiner Tree Problem
Assume that the vertices in the undirected weighted graph is partitioned into two sets: 1) Terminals 2) Steiner Find the smallest connected subgraph of the graph that contains all the terminal vertices. If there are no steiner vertices, then the problem is – Minimum Spanning Tree (MST) Note that the optimal answer is always a tree.
Terminal s Steiner vertices
2 2 2 2 • • • This is the subgraph obtained by us. The number of edges in this subgraph is 14. The weight of the optimum tree = 7.
• Thus, if we replace weighted edges by the shortest path, this algorithm is a 2 approximate algorithm. • But there is a problem. • This algorithm uses the optimum tree which we donot know. So, now what to do?
LP Duality shows that this is indeed tight. 2 1 2 2 1 1 1 2 MST in G 2 2 Steiner Tree output by our algorithm
3 1 5 10 9 15 6
3 5 10 1 9 15 6 There is a special name given to this sequence. Do you know what it is? Euler Tour
a b c b d b a f e f a g h g a
Correctness: Try to prove that this algorithm indeed solved the TSP. Running Time: Try to prove that this algorithm runs in polynomial time. Question: What is the approximation ratio of this algorithm?
a b c b d b a f e f a g h g Observation: Each edge of the MST appears in exactly twice in the Euler Tour Observation: Weight of Euler Tour is twice the weight of MST We will then show that the weight of our TSP cycle = weight of Euler Tour Weight of our TSP cycle = 2 w(MST) a
• Assume that all edges of the Euler Tour have weight 1. • This is how our algorithm will proceed. a b c b d b a f e f a g Lemma: Our algorithm is 2 -approximate. This is the simplest algorithm for this problem but not the best in terms of approximation. h g a
Eulerian Cycle: A eulerian cycle in a graph is a cycle that passes through each edge at most once. Observation: If the graph contains a eulerian cycle, then the degree of each vertex is even. Lemma: If the degree of each vertex in the graph is even, then there exists a eulerian cycle in the graph.
3 1 5 10 15 6 The way we make even degree graph for TSP. Once we get the eulerian cycle, we “shortcut” some path to get a TSP. Question: Can we add few edges and still create an even degree graph from MST?
3 1 5 10 9 15 6 Some vertices already have even degree in MST. Lemma: The number of vertices that have odd degree in MST is even.
3 1 5 10 9 15 6 • We will add some edges between only these vertices. • Question: How should we add these edges? Remember the weight of the edges that you should add should not be very high.
3 15 1 21 5 10 13 9 6 15 • Add minimum cost/weight matching between these vertices. • Such a matching is also called perfect matching.
3 15 1 21 5 10 13 9 6 15 Question: What is the weight of the edges that you have added to the MST?
- Slides: 24