retagged by
18,360 views
27 27 votes
Consider a graph $G = (V,E)$, where $V = \{v_1,v_2, \dots ,v_{100}\}$, $E = \{(v_i,v_j) \mid 1\leq i < j \leq 100\}$, and weight of the edge $(v_i,v_j)$ is $\mid i – j \mid$. The weight of minimum spanning tree of $G$ is _________

7 Answers

Best answer
45 45 votes
Vertices are given from $1$ to $100$ and edge weight between the vertices is absolute values of the difference between the suffix values of the vertices.

So, if we choose the vertices consecutively as $1-2-3-4-5-  \ldots -99-100$ we get the spanning tree with minimum weight.

Spanning tree will contain $99$ edges since there are $100$ vertices and cost of each edge is $ ‘1\text{'}.$

Therefore, weight of spanning tree would be $99\ast 1 = 99$.
edited by
1 1 vote
In MST, all the edges of weight 1 will be connected like V1 to V2, V2 to V3 and so on.

So. the Weight of MST of G will be 99.
0 0 votes
Its better to take small example of 10 vertices and solve where each vertex 1,2 ,3, 4, 5,6,7,8,9,10 has number of edges from 9, 8, 7,6,5,4,3,2,0 respectively. And each vertex has edge with weight 1 so we take edges |V-1| times as the last vertex would form cycle.

For the example with 10 vertex we got weight of MST as 9 similarly for 100 vertices we get weight as 99.
Answer:
Position:
Show:

Related questions

59 59 votes
4 answers 4 answers
24.9k
24.9k views
Arjun asked Feb 12, 2020
24,903 views
Consider a double hashing scheme in which the primary hash function is $h_1(k)= k \text{ mod } 23$, and the secondary hash function is $h_2(k)=1+(k \text{ mod } 19)$. Ass...
81 81 votes
14 answers 14 answers
38.5k
38.5k views
Arjun asked Feb 12, 2020
38,543 views
Let $G = (V, E)$ be a weighted undirected graph and let $T$ be a Minimum Spanning Tree (MST) of $G$ maintained using adjacency lists. Suppose a new weighed edge $(u, v) ...
86 86 votes
9 answers 9 answers
33.2k
33.2k views
Arjun asked Feb 12, 2020
33,223 views
Let $G = (V,E)$ be a directed, weighted graph with weight function $w: E \rightarrow \mathbb{R}$. For some function $f: V \rightarrow \mathbb{R}$, for each edge$(u,v)\in ...
65 65 votes
11 answers 11 answers
31.3k
31.3k views
gatecse asked Feb 14, 2018
31,258 views
Consider the following undirected graph $G$:Choose a value for $x$ that will maximize the number of minimum weight spanning trees (MWSTs) of $G$. The number of MWSTs of $...