京都大学 情報学研究科 数理工学専攻 2018年8月実施 アルゴリズム基礎
Author
祭音Myyura
Description
Let be a connected simple undirected graph with a set of vertices and a set of edges, let be a spanning tree of rooted at a vertex , and let be a numbering on , where we assume that the following conditions (a) and (b) hold.
(a) For each edge , vertex is either an ancestor or a descendant of in .
(b) For each vertex and the parent of in , .
Let denote the set of leaves in . For each vertex , let denote the set of neighbors of in , and let denote the set consisting of vertex and the descendants of in . Define a function
such that
Answer the following questions.
(i) Prove that no leaf is a cut-vertex in .
(ii) Prove that a necessary and sufficient condition for the root to be a cut-vertex in is that has at least two children in .
(iii) Prove that a necessary and sufficient condition for a vertex to be a cut-vertex in is that has a child in such that
题目描述
设 是含 个顶点的连通简单无向图, 是以 为根的生成树, 是顶点编号,并满足:
- 对每条边 , 在 中是 的祖先或后代;
- 对每个非根顶点 及其父顶点 ,有 。
令 为 的叶集, 为 在 中的邻接点集合, 为 及其在 中所有后代组成的集合。对 定义
回答:
- 证明任一叶顶点 都不是 的割点。
- 证明根 是割点的充要条件是 在 中至少有两个子顶点。
- 证明非叶、非根顶点 是割点的充要条件是: 在 中存在子顶点 满足 。
考点
- 深度优先搜索树与 lowpoint:利用树边、回边的祖先—后代结构刻画子树是否能绕过父顶点连接到更高祖先。
- 割点判定:分别证明 DFS 树中叶、根和一般内部顶点成为割点的充要条件。
Kai
(1)
Let , i.e., is a leaf of .
Sinc is a spanning tree of , is connected.
After removing the vertex from , the remaining graph is still connected and spans all the vertices .
Note that is a subgraph of , hence is connected, which implies that is not a cut-vertex.
(2)
(Necessity) Assume that is a cut-vertex.
If has only one child in , i.e., is a leaf vertex of , then by the same argument of (1), we know that is still connected.
This contradicts the assumption taht is a cut-vertex.
(Sufficiency) Assume that has at least two children in . Let two of them be and .
Consider the two subtrees and . Since and are different children of the root , the vertices in and are not in an ancestor-descendant relationship with each other.
By condition (a), there cannot be any edge between a vertex in and a vertex in .
After deleting , the two subtrees and cannot be connected to each other. Hence is disconnected, which implies that is a cut-vertex.
(3)
(Necessity) Assume that is a cut-vertex.
We prove that there must exist a child of such that by contradiction.
Suppose that every child of satisfies . Then for each child of , there exist some vertex and some neighbor such that .
Since , the vertex is a descendant of . By condition (b), every descendant of has numbering greater than .
Therefore, the vertex of is not in .
By condition (a), since is a descendant of , and y has numbering smaller than , the vertex must be a proper ancestor of .
Thus every child subtree of has an edge to some proper ancestor of , i.e., after deleting , every child subtree can still connect to the part above through an edge to a proper ancestor of .
Therefore, remains connected, which contradicts the assumption that is a cut-vertex.
(Sufficiency) Assume that has a child satisfying .
Note that is a neighbor of , i.e., , when computing , the vertex can be reached from by one graph edge.
Hence , together with the assumption we have
This means that the subtree cannot reach any proper ancestor of through a graph edge. The smallest numbered vertex reachable from is exactly .
Equivalently, has no edge to any proper ancestor of .
After deleting , the subtree is disconnected from the part of the graph above . Therefore is disconnected.
Hence is a cut-vertex.