# 超立方体图

超立方体图（hypercube graph，又称 n-立方体或布尔立方体，记作 \( Q_n \)）是这样的图：其顶点是全部 \( 2^n \) 个长度为 n 的二进制串，两个顶点之间有边相连，当且仅当这两个串恰有一个坐标不同。<sup>[1](https://pages.cs.wisc.edu/~tvrdik/5/html/Section5.html)</sup> 它是 n 维立方体的 1-骨架，既是图论中的核心对象，也是 20 世纪 80 年代建造的一族并行计算机的互连拓扑。<sup>[2](https://deepblue.lib.umich.edu/bitstream/handle/2027.42/27522/0000566.pdf)</sup>

| 关键事实 | 详情 |
|---|---|
| 顶点与边 | \( 2^n \) 个顶点、\( n \cdot 2^{n-1} \) 条边；每个顶点的度为 n<sup>[2](https://deepblue.lib.umich.edu/bitstream/handle/2027.42/27522/0000566.pdf)</sup> |
| 递归构造 | \( Q_1 = K_2 \)，且 \( Q_n = K_2 \times Q_{n-1} \)，即与单边图的笛卡尔积<sup>[3](https://link.springer.com/chapter/10.1007/978-981-96-4745-3_1)</sup> |
| 距离 | 两顶点间的图距离等于它们的汉明距离，即二者相异的坐标数；直径为 n，平均距离趋近 n/2<sup>[1](https://pages.cs.wisc.edu/~tvrdik/5/html/Section5.html)</sup><sup> • </sup><sup>[2](https://deepblue.lib.umich.edu/bitstream/handle/2027.42/27522/0000566.pdf)</sup> |
| 鲁棒性 | 顶点连通度与边连通度均为 n；二分宽度为 \( 2^{n-1} \)；距离为 k 的两顶点之间有 k! 条不同的最短路径<sup>[1](https://pages.cs.wisc.edu/~tvrdik/5/html/Section5.html)</sup> |
| 二部性与哈密顿性 | 色数为 2，按顶点权重的奇偶性着色；每个 \( Q_n \) 都有哈密顿圈，这样的圈即二进制反射格雷码<sup>[2](https://deepblue.lib.umich.edu/bitstream/handle/2027.42/27522/0000566.pdf)</sup><sup> • </sup><sup>[4](https://mathworld.wolfram.com/HypercubeGraph.html)</sup> |
| 谱 | 邻接矩阵的特征值为 \( n - 2d \)，对每个 \( d \in [0,n] \) 重数为 \( \binom{n}{d} \)<sup>[5](https://onlinelibrary.wiley.com/doi/full/10.1002/rsa.21267)</sup> |
| 可扩展性极限 | 度随顶点数对数增长，且该拓扑只存在于 2 的幂次规模<sup>[1](https://pages.cs.wisc.edu/~tvrdik/5/html/Section5.html)</sup> |

## 定义与构造

有两种标准的等价定义。代数上，顶点集为 \( \{0,1\}^n \)，顶点 u 与 v 相邻，当且仅当它们恰有一个坐标不同。<sup>[6](https://dmtcs.episciences.org/466/pdf)</sup> 递归地，\( Q_1 \) 是单边 \( K_2 \)，每个 \( Q_n \) 是 \( K_2 \) 与 \( Q_{n-1} \) 的笛卡尔积，因此 \( Q_n \) 也是 n 个两顶点路径的笛卡尔积。<sup>[3](https://link.springer.com/chapter/10.1007/978-981-96-4745-3_1)</sup><sup> • </sup><sup>[7](https://ocw.mit.edu/courses/18-212-algebraic-combinatorics-spring-2019/54128665413c774414c64d53fdb3de4e_MIT18_212S19_lec27.pdf)</sup>

最初几个情形都有熟悉的名称：\( Q_1 \) 是路径 \( P_2 \)，\( Q_2 \) 是正方形图 \( C_4 \)，\( Q_3 \) 是立方体图，\( Q_4 \) 是四维超立方体图。<sup>[4](https://mathworld.wolfram.com/HypercubeGraph.html)</sup> 递归给出一种层次结构：对 1 到 n−1 之间任意 k，有 \( Q_n = Q_k \times Q_{n-k} \)；沿一个坐标切分，得到两个由 \( 2^{n-1} \) 条边相连的 \( (n-1) \)-立方体，这达到了最优的二分宽度。<sup>[1](https://pages.cs.wisc.edu/~tvrdik/5/html/Section5.html)</sup> 一个 k 维子立方体由恰好含 k 个无关符号和 n−k 个固定坐标的地址指定；顶点对应布尔代数中的最小项，子立方体对应其中的项。<sup>[1](https://pages.cs.wisc.edu/~tvrdik/5/html/Section5.html)</sup>

## 结构性质

**距离与对称性。** 两顶点间的距离即它们的汉明距离，故直径为 n，平均距离为 \( n \cdot 2^{n-1}/(2^n - 1) \)，随 n 增大迅速趋近 n/2。<sup>[2](https://deepblue.lib.umich.edu/bitstream/handle/2027.42/27522/0000566.pdf)</sup> 该图既是顶点对称的也是边对称的：其自同构群由平移（与一个固定串作异或）和 n 个坐标的置换组成，并且它是距离传递的。<sup>[1](https://pages.cs.wisc.edu/~tvrdik/5/html/Section5.html)</sup><sup> • </sup><sup>[4](https://mathworld.wolfram.com/HypercubeGraph.html)</sup>

**二部性与圈。** 每条边恰好翻转一位，因此 1 的个数的奇偶性沿每条边交替；将偶权重顶点染一色、奇权重顶点染另一色，即得一个 2-着色，色数为 2。<sup>[6](https://dmtcs.episciences.org/466/pdf)</sup><sup> • </sup><sup>[2](https://deepblue.lib.umich.edu/bitstream/handle/2027.42/27522/0000566.pdf)</sup> 所有超立方体图都是哈密顿的，标号 \( Q_n \) 的任一哈密顿圈都定义了一个二进制反射格雷码，即所有 n 位串的一种排序，其中相邻的串只差一位。<sup>[4](https://mathworld.wolfram.com/HypercubeGraph.html)</sup> 偶长度圈的数目有闭式公式；例如 4-圈的数目为 \( 2^{n-3}(n-1)n \)。<sup>[4](https://mathworld.wolfram.com/HypercubeGraph.html)</sup>

**连通度与容错性。** \( Q_n \) 的顶点连通度与边连通度均为 n，这是 n-正则图所能达到的最大值。<sup>[2](https://deepblue.lib.umich.edu/bitstream/handle/2027.42/27522/0000566.pdf)</sup> 若两顶点距离为 k，则它们之间有 n 条顶点不相交路径，其中 k 条长度为 k，n−k 条长度为 k+2；并有 k! 条不同的最短路径，对应 k 个相异坐标的置换。<sup>[1](https://pages.cs.wisc.edu/~tvrdik/5/html/Section5.html)</sup> 删去 n−1 条边后，任意两顶点之间仍存在长度至多 n 的路径，故故障直径等于 n。<sup>[1](https://pages.cs.wisc.edu/~tvrdik/5/html/Section5.html)</sup> 近期工作扩展了这些思想：\( Q_n \) 的结构故障直径结果推广了经典的直径与故障直径；2025 年的一项结果证明，边至多跨越 d = 5 个方向的 \( Q_n \) 的匹配可延拓为哈密顿圈，这是对拉斯克-萨维奇猜想（\( Q_n \) 的每个匹配都可延拓为哈密顿圈）的部分进展。<sup>[8](https://arxiv.org/abs/2412.09885)</sup><sup> • </sup><sup>[9](https://arxiv.org/abs/2501.19029)</sup>

**谱与生成树。** 由于 \( Q_n \) 是笛卡尔积，其邻接特征值都是形如 \( \varepsilon_1 + \cdots + \varepsilon_n \) 的和，其中每个 \( \varepsilon_i \in \{-1, 1\} \)；等价地，特征值 \( n - 2d \) 的重数为 \( \binom{n}{d} \)。<sup>[7](https://ocw.mit.edu/courses/18-212-algebraic-combinatorics-spring-2019/54128665413c774414c64d53fdb3de4e_MIT18_212S19_lec27.pdf)</sup><sup> • </sup><sup>[5](https://onlinelibrary.wiley.com/doi/full/10.1002/rsa.21267)</sup> 拉普拉斯特征值为 \( 2k \)，重数为 \( \binom{n}{k} \)；矩阵树定理给出生成树的数目为 \( 2^{2^n - n - 1} \prod_{k=1}^{n} k^{\binom{n}{k}} / 2^n \)；对普通的立方体 \( Q_3 \)，该数为 384。<sup>[7](https://ocw.mit.edu/courses/18-212-algebraic-combinatorics-spring-2019/54128665413c774414c64d53fdb3de4e_MIT18_212S19_lec27.pdf)</sup>

**绘制极限。** \( Q_n \) 仅在 \( n \le 3 \) 时是平面的。已知 \( Q_4 \) 的交叉数为 8，但更大的 n 的精确交叉数尚不清楚；埃尔德什（Erdős）与盖伊（Guy）猜想埃格尔顿-盖伊（Eggleton-Guy）上界公式是精确的。<sup>[4](https://mathworld.wolfram.com/HypercubeGraph.html)</sup> 确定支配数 \( \gamma(Q_n) \) 本质上是困难的，截至 2018 年 4 月，已知值仅到 n = 9。<sup>[4](https://mathworld.wolfram.com/HypercubeGraph.html)</sup>

## 超立方体并行计算机

该图的性质使它成为 20 世纪 80 年代分布式内存并行计算机的主流互连拓扑。超立方体机器在每个顶点放置一个带本地内存的处理器，处理器之间仅通过沿边传递消息来协调。<sup>[10](https://www.researchgate.net/publication/233409327_Parallel_computing_on_a_hypercube_an_overview_of_the_architecture_and_some_applications)</sup> 其吸引力来自对数直径、大二分带宽、高连通度与简单路由的结合：在 e-立方体路由中，源地址与目的地址按固定顺序逐位比较，依次纠正每个相异的位，这是一种简单到可以硬件固化的最优最短路径算法。<sup>[1](https://pages.cs.wisc.edu/~tvrdik/5/html/Section5.html)</sup> 超立方体还能高效模拟几乎任何其他拓扑，这使算法可以跨机器移植。<sup>[1](https://pages.cs.wisc.edu/~tvrdik/5/html/Section5.html)</sup><sup> • </sup><sup>[11](https://www.sciencedirect.com/science/article/abs/pii/S0020025501001207)</sup>

**宇宙立方体。** 有影响力的原型机由计算机科学家查尔斯·塞茨（Charles Seitz）和物理学家杰弗里·福克斯（Geoffrey Fox）在加州理工学院（Caltech）建造。这项工作始于 1981 年 5 月，当时福克斯参加了卡弗·米德（Carver Mead）关于超大规模集成电路（VLSI）的研讨会，意识到并行机器可以处理他研究核心的格点规范计算；目标定为 64 个处理器的六维超立方体，这台以布尔 6-立方体连接的 64 节点机器于 1983 年投入运行。<sup>[12](https://www.netlib.org/utk/lsi/pcwLSI/text/node13.html)</sup><sup> • </sup><sup>[13](https://calteches.library.caltech.edu/3419/)</sup> 每个节点只与其六个最近邻通信，没有共享内存；机器造价约 8 万美元，性能约为克雷-1（Cray-1）的十分之一。福克斯的团队用它进行量子色动力学的数值计算，这是当时常规机器无法企及的问题。<sup>[13](https://calteches.library.caltech.edu/3419/)</sup>

**商业后裔。** 英特尔架构师贾斯汀·拉特纳（Justin Rattner）1985 年的个人超级计算机（Personal SuperComputer，iPSC）用商用现成部件将 32 至 128 个英特尔 80286/7 处理器互连成超立方体。<sup>[14](https://www.computerhistory.org/revolution/supercomputers/10/74)</sup> 1986 年的 nCUBE 机器是一台基于微处理器的超立方体超级计算机，采用存储转发式消息传递。<sup>[15](https://web.eecs.umich.edu/~qstout/abs/IEEEM86.html)</sup> 到 1988 年，加州理工学院/喷气推进实验室（JPL）的马克III超立方体（Mark III Hypercube）已投入运行，它由批量生产的摩托罗拉 68020 微处理器构成，宣传称其性价比约为常规超级计算机的 10 倍，当时全球约有 100 套超立方体装置。<sup>[16](https://www.jpl.nasa.gov/news/mark-iii-supercomputer/)</sup>

## 纯超立方体为何让位于变体

使 \( Q_n \) 具有吸引力的那些参数，同时也限制了它。顶点度等于 n，因此它随顶点数对数增长：节点数翻倍，每个路由器的端口数就增加一个，而 k 个端口的路由器至多支持 \( 2^k \) 个节点。<sup>[1](https://pages.cs.wisc.edu/~tvrdik/5/html/Section5.html)</sup><sup> • </sup><sup>[21](https://technav.ieee.org/topic/hypercubes/)</sup> 该拓扑只对 2 的幂次规模有定义，因此不能增量扩展，且链路数比网格和环面增长得更快。<sup>[1](https://pages.cs.wisc.edu/~tvrdik/5/html/Section5.html)</sup><sup> • </sup><sup>[17](https://jastoolbox.sandia.gov/topic/joint-architecture-standard-overview/network-topologies/complete-and-incomplete-hypercubes/)</sup> 不完整超立方体支持任意数目的节点，却牺牲了可预测的可靠性；在一个 N = 9 个节点的例子中，单个节点故障就使另一个节点被孤立。<sup>[17](https://jastoolbox.sandia.gov/topic/joint-architecture-standard-overview/network-topologies/complete-and-incomplete-hypercubes/)</sup>

这些缺陷促生了一大族衍生结构，它们在保持类超立方体结构的同时使度保持固定或改善可扩展性，包括立方体连接环、扭曲立方体与莫比乌斯立方体、交叉立方体以及折叠超立方体；类超立方体网络则通过重新连接 \( Q_n \) 的若干对边得到。<sup>[1](https://pages.cs.wisc.edu/~tvrdik/5/html/Section5.html)</sup><sup> • </sup><sup>[18](https://arxiv.org/abs/2105.04803)</sup> 超立方体也仍是嵌入问题的基准：大量文献研究哪些其他拓扑（如德布鲁因图、弦环和网格）可以等距地或在缩放意义下嵌入超立方体或半超立方体。<sup>[19](https://arxiv.org/abs/1507.02147)</sup>

## 跨越数学各领域的联系

带汉明距离的顶点集 \( \{0,1\}^n \) 使 \( Q_n \) 成为二进制码的度量空间；在这一图上发展起来的布尔立方体上的傅里叶分析，是理论计算机科学中处理布尔函数、学习理论和纠错码的标准工具。<sup>[20](https://zesty2.cs.uchicago.edu/articles/gs001/)</sup> 同一个图也是 n 元布尔代数的哈斯图的基础，子立方体地址对应布尔代数中的项，因此该图把组合学、编码理论与逻辑学联系在同一个结构中。<sup>[4](https://mathworld.wolfram.com/HypercubeGraph.html)</sup><sup> • </sup><sup>[1](https://pages.cs.wisc.edu/~tvrdik/5/html/Section5.html)</sup>

## References

1. [Direct interconnection networks I+II, University of Wisconsin-Madison course notes](https://pages.cs.wisc.edu/~tvrdik/5/html/Section5.html)
2. [F. Harary, J. P. Hayes, and H.-J. Wu (1988). A survey of the theory of hypercube graphs. Computers & Mathematics with Applications 15(4):277-289.](https://deepblue.lib.umich.edu/bitstream/handle/2027.42/27522/0000566.pdf)
3. [Graph Theory Fundamentals, Springer Nature Link](https://link.springer.com/chapter/10.1007/978-981-96-4745-3_1)
4. [Hypercube Graph, Wolfram MathWorld](https://mathworld.wolfram.com/HypercubeGraph.html)
5. [Randomly Twisted Hypercubes: Between Structure and Randomness, Random Structures & Algorithms](https://onlinelibrary.wiley.com/doi/full/10.1002/rsa.21267)
6. [P. Gregor and R. Škrekovski. Long paths in induced subgraphs of hypercubes, DMTCS](https://dmtcs.episciences.org/466/pdf)
7. [MIT 18.212 Algebraic Combinatorics, Lecture 27: Matrix Tree Theorem](https://ocw.mit.edu/courses/18-212-algebraic-combinatorics-spring-2019/54128665413c774414c64d53fdb3de4e_MIT18_212S19_lec27.pdf)
8. [H. Zhao, E. Sabir, C.-K. Lin. Structure fault diameter of hypercubes, arXiv:2412.09885](https://arxiv.org/abs/2412.09885)
9. [J. Fink, V. Hotmar. Matchings in Hypercubes Extend to Long Cycles, arXiv:2501.19029](https://arxiv.org/abs/2501.19029)
10. [G. Ostrouchov (1987). Parallel computing on a hypercube: an overview of the architecture and some applications](https://www.researchgate.net/publication/233409327_Parallel_computing_on_a_hypercube_an_overview_of_the_architecture_and_some_applications)
11. [Optimal Gray-code labeling and recognition algorithms for hypercubes, Information Sciences](https://www.sciencedirect.com/science/article/abs/pii/S0020025501001207)
12. [Birth of the Hypercube, Caltech Concurrent Computation Program history](https://www.netlib.org/utk/lsi/pcwLSI/text/node13.html)
13. [Cosmic Cubism, Caltech Engineering & Science (March 1984)](https://calteches.library.caltech.edu/3419/)
14. [The Personal SuperComputer, Computer History Museum](https://www.computerhistory.org/revolution/supercomputers/10/74)
15. [nCUBE Hypercube Parallel Supercomputer, University of Michigan](https://web.eecs.umich.edu/~qstout/abs/IEEEM86.html)
16. [Mark III Supercomputer, NASA Jet Propulsion Laboratory (1988)](https://www.jpl.nasa.gov/news/mark-iii-supercomputer/)
17. [Complete and Incomplete Hypercubes, Sandia JAS Toolbox](https://jastoolbox.sandia.gov/topic/joint-architecture-standard-overview/network-topologies/complete-and-incomplete-hypercubes/)
18. [Component Edge Connectivity of Hypercube-like Networks, arXiv:2105.04803](https://arxiv.org/abs/2105.04803)
19. [Hypercube emulation of interconnection networks topologies, arXiv:1507.02147](https://arxiv.org/abs/1507.02147)
20. [R. de Wolf (2008). A Brief Introduction to Fourier Analysis on the Boolean Cube, Theory of Computing Library](https://zesty2.cs.uchicago.edu/articles/gs001/)
21. [Hypercubes, IEEE Technology Navigator](https://technav.ieee.org/topic/hypercubes/)

---
*Initially written Oct 15, 2026*

Topic: 物质世界与数学 › 数学与统计学 › 逻辑与离散数学 › General discrete mathematics and discrete structures › Graph theory › Graph theory overview and basic objects

Copyright 2026 Edgepedia

License: Edgepedia Community License 1.0, https://www.edgepedia.org/edgepedia/license

Source: https://www.edgepedia.org/zh/hypercube-graph

English original: https://www.edgepedia.org/hypercube-graph
