is_multigraphical#

is_multigraphical(sequence)[源代码]#

如果某些多图可以实现序列,则返回true。

参数
sequence列表

整数列表

返回
valid布尔尔

如果deg_equence是多字度数序列,则为True,否则为False。

笔记

最坏情况下的运行时间是 \(O(n)\) 哪里 \(n\) 是序列的长度。

工具书类

1

S. L. Hakimi. "On the realizability of a set of integers as degrees of the vertices of a linear graph", J. SIAM, 10, pp. 496-506 (1962).