Let be an edge-weighted undirected graph with positive edge weights. Suppose a positive constant is added to the weight of every edge.
Which ONE of the following statements is TRUE about the minimum spanning trees (MSTs) and shortest paths (SPs) in before and after the edge weight update?
View worked solution
Answer: C
To understand the effect of adding a positive constant to every edge weight, we analyze MSTs and Shortest Paths separately:
- Minimum Spanning Trees (MSTs): Any spanning tree of a graph with vertices contains exactly edges. If we add to the weight of every edge, the total weight of any spanning tree increases by exactly . Since this is a constant addition for all spanning trees, the relative ordering of their weights remains unchanged. Thus, every MST remains an MST.
- Shortest Paths (SPs): Different paths between two vertices can have different numbers of edges. Adding to each edge penalizes paths with more edges more heavily than paths with fewer edges. For example, consider two paths between and : with edge of weight , and with edges of weight each (total weight ). Initially, is the shortest path. If we add to each edge, the weight of becomes and the weight of becomes . Now, becomes the shortest path. Thus, SPs need not remain SPs.
Hence, every MST remains an MST, and SPs need not remain SPs.
Free practice · Your answers on this page are not saved.
