# 欧几里得定理

**欧几里得定理**（Euclid's theorem）是指素数有无穷多个，由希腊数学家亚历山大的欧几里得（Euclid of Alexandria）于公元前300年左右在《几何原本》（Elements，Στοιχεῖα）第九卷命题20中首次证明。欧几里得的表述不含“无穷”一词：“素数比任何指定的一批素数都要多。”<sup>[1](https://mathcs.clarku.edu/~djoyce/java/elements/bookIX/propIX20.html)</sup> 在哈代与赖特（Hardy and Wright）的《数论导引》（An Introduction to the Theory of Numbers）所用编号中，它被称为欧几里得第二定理，而欧几里得第一定理是那条引理：若一个素数整除一个乘积，则它整除其中一个因子。<sup>[2](https://arxiv.org/abs/0902.2465)</sup>

| 关键事实 | 详情 |
|---|---|
| 陈述 | 素数有无穷多个；欧几里得的原话：“素数比任何指定的一批素数都要多”<sup>[1](https://mathcs.clarku.edu/~djoyce/java/elements/bookIX/propIX20.html)</sup> |
| 出处 | 《几何原本》第九卷命题20（约公元前300年）<sup>[1](https://mathcs.clarku.edu/~djoyce/java/elements/bookIX/propIX20.html)</sup> |
| 方法 | 给定任意有限素数列表，构造它们的乘积加一；所得数的任一素因子都不在列表中<sup>[1](https://mathcs.clarku.edu/~djoyce/java/elements/bookIX/propIX20.html)</sup> |
| 支撑结果 | 第七卷命题31：任何合数都被某个素数度量<sup>[2](https://arxiv.org/abs/0902.2465)</sup> |
| 常见误读 | 所列素数的乘积加一所得的数本身不必是素数；证明只需要它有素因子<sup>[3](https://t5k.org/notes/proofs/infinite/euclids.html)</sup> |
| 后来的证明 | 里本博伊姆的《素数记录簿》引用了九个半证明；2012年的一项调查收集了从公元前300年到2022年的200个证明<sup>[2](https://arxiv.org/abs/0902.2465)</sup><sup> • </sup><sup>[4](https://arxiv.org/abs/1202.3670)</sup> |
| 相关序列 | 数 \( N = 2 \cdot 3 \cdot 5 \cdots p + 1 \)，其中 \( p \) 是第 \( i \) 个素数，称为欧几里得数<sup>[5](https://mathworld.wolfram.com/EuclidsTheorems.html)</sup> |

## 欧几里得的证明

《几何原本》中的论证如下。设A、B、C为指定的素数；欧几里得用三个素数来说明一般情形，这是他的习惯做法，因为当时的符号无法表示任意多个对象。<sup>[1](https://mathcs.clarku.edu/~djoyce/java/elements/bookIX/propIX20.html)</sup><sup> • </sup><sup>[3](https://t5k.org/notes/proofs/infinite/euclids.html)</sup> 取被A、B、C度量的最小数DE，即它们的最小公倍数，并加上单位得到EF。于是EF要么是素数，要么不是。

如果EF是素数，那么素数A、B、C、EF就多于指定的三个。如果EF不是素数，那么根据第七卷命题31，某个素数G度量它。<sup>[2](https://arxiv.org/abs/0902.2465)</sup> 欧几里得然后证明G不可能等于A、B、C中的任何一个：那些素数度量DE，因此G将同时度量DE和EF，从而度量它们的差，即单位，这是荒谬的（ἄτοπον）。<sup>[1](https://mathcs.clarku.edu/~djoyce/java/elements/bookIX/propIX20.html)</sup> 于是产生了一个新素数，而由于起始列表是任意的，所以没有有限列表包含所有素数。<sup>[1](https://mathcs.clarku.edu/~djoyce/java/elements/bookIX/propIX20.html)</sup>

用现代记号，给定素数 \( p_{1}, p_{2}, \ldots, p_{n} \)，考虑

\[ N = p_{1} \cdot p_{2} \cdots p_{n} + 1. \]

每个列出的素数除N时余1，所以没有列出的素数整除N。如果N是素数，它就是新素数；否则它有一个素因子，而该因子不在列表中。<sup>[1](https://mathcs.clarku.edu/~djoyce/java/elements/bookIX/propIX20.html)</sup><sup> • </sup><sup>[6](https://math.hmc.edu/funfacts/how-many-primes/)</sup>

**一个常见的误读。** 许多表述声称N本身必定是素数。事实并非如此：取列表2、3、5，构造得到31，它恰好是素数，但一般来说只能保证N有一个不在列表中的素因子。<sup>[3](https://t5k.org/notes/proofs/infinite/euclids.html)</sup><sup> • </sup><sup>[6](https://math.hmc.edu/funfacts/how-many-primes/)</sup> 找到的新素数也不必超过起始列表中的每个素数。从集合{2, 3, 7, 43, 13, 139, 3263443}开始，P的最小选择分解为 \( 547 \cdot 607 \cdot 1033 \cdot 31051 \)，而这四个素数每一个都小于原集合中的最后一个素数。<sup>[3](https://t5k.org/notes/proofs/infinite/euclids.html)</sup>

**构造性的还是反证法的？** 欧几里得自己的论证从任意有限列表出发，产生一个列表之外的素数，因此它给出的是生成新素数的程序，而不是纯粹的归谬法。许多教科书改写则假设一个包含所有素数的完全有限列表，然后导出矛盾；迪杰斯特拉（Dijkstra）指出，构造性形式避免了这类改写引入的“Q是素数”与“Q不是素数”之间的分情况讨论。<sup>[7](https://www.cs.utexas.edu/~EWD/transcriptions/EWD08xx/EWD803/EWD803.html)</sup> 慕尼黑工业大学（TU München）的马库斯·文策尔（Markus Wenzel）和奈梅亨拉德堡德大学（Radboud University Nijmegen）的弗里克·维迪克（Freek Wiedijk）还在Isabelle证明助手中将一个构造性版本形式化，并从中提取了程序。<sup>[8](https://isabelle.in.tum.de/library/HOL/HOL-Proofs-Extraction/Euclid.html)</sup>

## 欧几里得能说与不能说的话

欧几里得不可能写出“素数有无穷多个”这样的话。古希腊人把整数理解为单位的计数，其中一不算作数，并用线段长度来表示整数；现代数学讲整除的地方，欧几里得写的是一个长度“度量”另一个长度。他们也没有现代的无穷概念，而是把线看作可以无限延长的线段，而不是无穷对象。欧几里得的说法——素数的数量超过任何指定的有限数量——是现代陈述的古代等价物。<sup>[3](https://t5k.org/notes/proofs/infinite/euclids.html)</sup> 他的证明在表述上同样是几何式的，而且他通过三个素数的特例来论证一般命题，这种风格今天不被认为完全严格，但很容易转化为一般论证。<sup>[9](https://math.libretexts.org/Bookshelves/Mathematical_Logic_and_Proof/An_Introduction_to_Proof_via_Inquiry-Based_Learning_%28Ernst%29/06%253A_New_Page/6.03%253A_New_Page)</sup><sup> • </sup><sup>[3](https://t5k.org/notes/proofs/infinite/euclids.html)</sup>

这个命题与这部著作的其余部分有些脱节：它在《几何原本》的其他地方从未被使用。<sup>[1](https://mathcs.clarku.edu/~djoyce/java/elements/bookIX/propIX20.html)</sup>

## 在数论中的地位

该定理支撑着算术的结构。剑桥的分析学家、与E. M.赖特（E. M. Wright）合著标准教材的G. H.哈代（G. H. Hardy）称这一结果对整个算术结构至关重要，并评论说这个证明“与它被发现时一样新鲜和有意义”，因此“两千年也没有在它上面写下一道皱纹。”<sup>[2](https://arxiv.org/abs/0902.2465)</sup><sup> • </sup><sup>[5](https://mathworld.wolfram.com/EuclidsTheorems.html)</sup> 欧几里得的证明依赖于他先前的结果：每个合数都有一个素因子（第七卷命题31）；而他求最大公因子的算法同时蕴含这一点和欧几里得引理，后者是算术基本定理唯一性部分的核心。<sup>[2](https://arxiv.org/abs/0902.2465)</sup>

这种构造也产生了一些本身就令人感兴趣的数列。当 \( p \) 是第 \( i \) 个素数时，数 \( N = 2 \cdot 3 \cdot 5 \cdots p + 1 \) 称为欧几里得数；它们不一定是素数。一个归于R. K.盖伊（R. K. Guy）的相关猜想认为，如果 \( q \) 是 \( p_{1} p_{2} \cdots p_{n} + 1 \) 之后的下一个素数，那么 \( q - p_{1} p_{2} \cdots p_{n} \) 总是素数；这样的数称为幸运素数（Fortunate primes），该猜想仍未证明。<sup>[5](https://mathworld.wolfram.com/EuclidsTheorems.html)</sup> 类似的论证表明，\( p! \pm 1 \) 要么是素数，要么可被一个大于 \( p \) 的素数整除；库默尔（Kummer）给出了一个反证法变体，用 \( N - 1 \) 代替 \( N + 1 \)。<sup>[5](https://mathworld.wolfram.com/EuclidsTheorems.html)</sup>

## 后来的证明

几个世纪以来积累了数十个替代证明。里本博伊姆的记录书给出了九个半，而黑山大学（University of Montenegro）的罗密欧·梅什特罗维奇（Romeo Meštrović）在2012年的一项调查中收集了从公元前300年到2022年的200个不同证明。<sup>[2](https://arxiv.org/abs/0902.2465)</sup><sup> • </sup><sup>[4](https://arxiv.org/abs/1202.3670)</sup> 值得注意的例子包括菲利普·赛达克（Filip Saidak）2006年的证明，它反复将整数 \( n \) 乘以 \( n + 1 \)，得到素因子越来越多的数，完全避免了使用反证法；希勒尔·弗斯滕伯格（Hillel Furstenberg）使用点集拓扑的证明，它也被用非拓扑术语解释过；以及一个使用正则语言、适合计算机科学课程的证明。<sup>[10](https://www.math.gordon.edu/ntic/ntic2023/section-inf-primes.html)</sup>

欧几里得方法可以推广到全素数集之外。对于等差数列 \( kn + \ell \) 中的素数，欧几里得式证明恰好当 \( \ell^{2} \equiv 1 \pmod{k} \)（且 \( \gcd(k, \ell) = 1 \)）时存在，而这一条件是能给出此类证明的唯一情形。<sup>[11](https://mat.uab.cat/~masdeu/teaching/misc/euclid.php)</sup> 关于素数分布有多稠密的更广泛的定量问题，直到十九世纪才首次得到处理，当时切比雪夫（Chebyshev）在欧几里得的定性结果之后首次获得了素数计数函数的估计。<sup>[12](https://www.math.columbia.edu/department/rama/chapters/chap16.html)</sup>

## References

1. [Euclid's Elements, Book IX, Proposition 20, David E. Joyce, Clark University](https://mathcs.clarku.edu/~djoyce/java/elements/bookIX/propIX20.html)
2. [Shaohua Zhang and colleagues, Euclid's Number-Theoretical Work, arXiv:0902.2465](https://arxiv.org/abs/0902.2465)
3. [Chris Caldwell, Euclid's Proof of the Infinitude of Primes (c. 300 BC), The PrimePages](https://t5k.org/notes/proofs/infinite/euclids.html)
4. [Romeo Meštrović, Euclid's theorem on the infinitude of primes: a historical survey of its proofs (300 B.C.–2022) and another new proof, arXiv:1202.3670](https://arxiv.org/abs/1202.3670)
5. [Euclid's Theorems, Wolfram MathWorld](https://mathworld.wolfram.com/EuclidsTheorems.html)
6. [How many Primes?, Math Fun Facts, Harvey Mudd College](https://math.hmc.edu/funfacts/how-many-primes/)
7. [E. W. Dijkstra, Lecture notes on the structure of programs and proofs (EWD 803)](https://www.cs.utexas.edu/~EWD/transcriptions/EWD08xx/EWD803/EWD803.html)
8. [Theory Euclid, Isabelle/HOL Proof Extraction, TU München](https://isabelle.in.tum.de/library/HOL/HOL-Proofs-Extraction/Euclid.html)
9. [6.3: The Infinitude of Primes, Dana Ernst, Mathematics LibreTexts](https://math.libretexts.org/Bookshelves/Mathematical_Logic_and_Proof/An_Introduction_to_Proof_via_Inquiry-Based_Learning_%28Ernst%29/06%253A_New_Page/6.03%253A_New_Page)
10. [To Infinity and Beyond, Number Theory Through Inquiry, Gordon College](https://www.math.gordon.edu/ntic/ntic2023/section-inf-primes.html)
11. [Euclidean Proofs of the infinitude of primes in arithmetic progressions, Universitat Autònoma de Barcelona](https://mat.uab.cat/~masdeu/teaching/misc/euclid.php)
12. [Chapter 16: The Distribution of Primes, Columbia University](https://www.math.columbia.edu/department/rama/chapters/chap16.html)

---
*Initially written Sep 17, 2026 · Reviewed: Sep 30, 2026; Oct 15, 2026 · Edited: Sep 30, 2026; Oct 15, 2026 · Last review: Oct 15, 2026*

Topic: 物质世界与数学 › 数学与统计学 › 数与代数 › Number theory › Elementary number theory › Prime numbers: elementary aspects

Copyright 2026 Edgepedia

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

Source: https://www.edgepedia.org/zh/euclids-theorem

English original: https://www.edgepedia.org/euclids-theorem
