Why does a disconnected undirected graph with n vertices have at most (n-1)(n-2)/2 edges?
To maximize the number of edges while keeping the graph disconnected, the extremal construction isolates exactly one vertex and forms a complete graph with the remaining n-1 vertices. The number of edges is therefore the maximum for a complete graph on n-1 vertices, which is (n-1)(n-2)/2.
Conditions
- G is an undirected graph.
- G has n vertices.
- G is a disconnected graph.
Reasoning, step by step
- Separate one vertex to remain isolated, ensuring the graph is disconnected.
- Connect all remaining n-1 vertices to each other to form a complete subgraph.
- Calculate the number of edges in this complete subgraph using the formula for n-1 vertices: (n-1)((n-1)-1)/2.
- Simplify the expression to (n-1)(n-2)/2.
Example
The presenter constructs an example with 6 vertices (A, B, C, D, E, F). Vertices A through E form a complete graph ( edges), while F is isolated. This matches the formula (6-1)(6-2)/2 = 10.
Common misconceptions
- Incorrectly assuming that the isolated vertex can be connected to other vertices without violating disconnectedness.
- Relying solely on the presenter's verbal explanation, which mistakenly stated the formula as , instead of the correct on-screen formula (n-1)(n-2)/2.
Watch the explanation
5:13 – 6:00Watch this moment ↗
Explore next
Answers are generated from source material and independently checked. Consult the original video or creator if something is unclear.