This preview shows pages 1–3. Sign up to view the full content.
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
Unformatted text preview: CME 305: Discrete Mathematics and Algorithms Instructor: Professor Amin Saberi (saberi@stanford.edu) HW#2 Solutions 1. Let T be a spanning tree of a graph G with an edge cost function c . We say that T has the cycle property if for any edge e / T , c ( e ) c ( e ) for all e in the cycle generated by adding e to T . Also, T has the cut property if for any edge e T , c ( e ) c ( e ) for all e in the cut defined by e . Show that the following three statements are equivalent: (a) T has the cycle property. (b) T has the cut property. (c) T is a minimum cost spanning tree. Remark 1 : Note that removing e T creates two trees with vertex sets V 1 and V 2 . A cut defined by e T is the set of edges of G with one endpoint in V 1 and the other in V 2 (with the exception of e itself). Remark 2 : The cycle and cut properties we have defined in this problem are slightly different from what they usually mean. Solution: In order to show that (a), (b), and (c) are equivalent, it is enough to show: (a) (c), and (b) (c). (c) (a) : By contradiction suppose T does not have the cycle property: there exists e / T such that T { e } has a cycle C in which there exists e T and e C where c ( e ) > c ( e ). Let tree T be the tree obtained by adding e to T and removing e ; T is a tree with cost strictly less than cost of T which is contradicting with T being an MST. (a) (c) : By contradiction suppose T is not an MST: let e be the first edge that was picked by Kruskals algorithm but des not belong to T . Adding e to T would create cycle C . Since T has cycle property, c ( e ) c ( e ), e C . Therefore, all e C , e 6 = e have been visited by the Kruskals algorithm. We have two cases: case 1 : All e C \{ e } were picked by the algorithm. In this case the algorithm would not pick e because it creates a cycle with the existing edges. case 2 : There exists e * C , e * 6 = e such that it was not picked by the algorithm. The reason for not picking an edge is that it would create a cycle with the existing edges. However, since e was the first edge picked by the algorithm that does to belong to T , this would mean that T has a cycle, which is a contradiction. (a) (b) : By contradiction suppose T does not have the cut property: there exists e T such that there exits edge e = ( v 1 ,v 2 ) such that v 1 V 1 and v 2 V 2 ( V 1 and V 2 are the set of vertices of the two connected components after removing e , see Remark 2.), and c ( e ) < c ( e ). Since T is connected graph there exist path P T between v 1 and v 2 such that all the edges of P T belong to T . Adding e to P T creates a cycle in which there exist e T where c ( e ) > c ( e ) which is contradicting with T having the cycle property. (b) (a) : By contradiction suppose T does not have the cycle property: there exists edge e such that when adding it to T and creating cycle C , there exists e C , where c ( e ) > c ( e ). In T , if we remove...
View
Full
Document
This document was uploaded on 06/17/2010.
 Winter '09

Click to edit the document details