# 幺半群

幺半群是一种代数结构，由一个集合配上一个满足结合律的二元运算以及一个双侧单位元组成。它是抽象代数中最简单的结构之一：一个半群（带结合运算的集合）加上单位元，或一个群去掉对逆元的要求。<sup>[1](https://math.umd.edu/~pbrosnan/notes/ugalg/sect0011.html)</sup><sup> • </sup><sup>[2](https://itamar.web.illinois.edu/Teaching/417_FW26/Notes/node-What-is-abstract-algebra-anyway.html)</sup>

| 关键事实 | 详情 |
|---|---|
| 定义 | 一个集合 \( M \) 配上一个二元运算 \( M \times M \to M \)，满足结合律 \( (x \ast y) \ast z = x \ast (y \ast z) \) 与单位性 \( x \ast e = x = e \ast x \)<sup>[2](https://itamar.web.illinois.edu/Teaching/417_FW26/Notes/node-What-is-abstract-algebra-anyway.html)</sup> |
| 单位元 | 单位元是唯一的；通常写作 \( 1 \)，当运算写作加法时写作 \( 0 \)<sup>[2](https://itamar.web.illinois.edu/Teaching/417_FW26/Notes/node-What-is-abstract-algebra-anyway.html)</sup><sup> • </sup><sup>[1](https://math.umd.edu/~pbrosnan/notes/ugalg/sect0011.html)</sup> |
| 基本例子 | \( (\mathbb{N}, +) \) 以 0 为单位元，\( (\mathbb{N}, \cdot) \) 以 1 为单位元；两者都是幺半群但不是群<sup>[1](https://math.umd.edu/~pbrosnan/notes/ugalg/sect0011.html)</sup> |
| 与群的关系 | 群恰好是每个元素都可逆的幺半群；任何幺半群的可逆元素 \( M^{\times} \) 构成一个群<sup>[1](https://math.umd.edu/~pbrosnan/notes/ugalg/sect0011.html)</sup> |
| 范畴论视角 | 幺半群是只有一个对象的范畴；更一般地，幺半群对象可以在任何幺半范畴中定义<sup>[3](https://ncatlab.org/nlab/show/monoid)</sup><sup> • </sup><sup>[4](https://math.mit.edu/~hrm/palestine/maclane-categories.pdf)</sup> |
| 自动机理论 | 一个语言是正则的，当且仅当它被某个有限幺半群接受<sup>[5](https://lat.inf.tu-dresden.de/teaching/ss2015/AL/lecture-log.html)</sup> |
| 字问题 | 有限表现幺半群的字问题一般是不可判定的；马尔可夫与波斯特于 1947 年证明了这类幺半群的存在<sup>[6](https://research.vu.nl/en/publications/certifying-the-decidability-of-the-word-problem-in-monoids-at-lar/)</sup><sup> • </sup><sup>[7](https://link.springer.com/article/10.1007/s00233-021-10216-8)</sup> |

## 定义与初步性质

形式地说，幺半群 \( (M, \ast) \) 由一个集合 \( M \) 和一个运算 \( (x, y) \mapsto x \ast y \) 组成，满足两条公理：结合律 \( (x \ast y) \ast z = x \ast (y \ast z) \)，以及单位性，即存在元素 \( e \)，使得对所有 \( x \) 都有 \( x \ast e = x = e \ast x \)。这个运算常被称为乘法，即使它与数字的乘法毫无关系；定义只要求把 \( M \) 中两个元素结合起来得到 \( M \) 中另一个元素。<sup>[2](https://itamar.web.illinois.edu/Teaching/417_FW26/Notes/node-What-is-abstract-algebra-anyway.html)</sup>

单位元是唯一的。若 \( e \) 与 \( e' \) 都满足单位性等式，则 \( e = e \ast e' = e' \)。<sup>[2](https://itamar.web.illinois.edu/Teaching/417_FW26/Notes/node-What-is-abstract-algebra-anyway.html)</sup> 记号随运算而变：\( 1 \) 是单位元的默认符号，当运算写作加法时用 \( 0 \)，偶尔也出现 \( e \)；当同时涉及多个幺半群时，用 \( 1_M \) 表示 \( M \) 的单位元。<sup>[1](https://math.umd.edu/~pbrosnan/notes/ugalg/sect0011.html)</sup>

结合律使得运算可以从二元推广到任意有限序列：对一组元素的乘积以不同方式加括号会得到相同结果，因此乘法可以看作以整个元素词为输入，而不仅仅是两个元素。<sup>[8](https://www.mimuw.edu.pl/~bojan/20142015-2/alg/1-introduction-to-monoids)</sup>

## 例子

- 自然数在加法下 \( (\mathbb{N}, +) \)，单位元为 0；在乘法下 \( (\mathbb{N}, \cdot) \)，单位元为 1。两者都不是群，因为大多数自然数没有逆元。<sup>[1](https://math.umd.edu/~pbrosnan/notes/ugalg/sect0011.html)</sup>
- 整数在加法下构成幺半群（事实上是群）；行列式为 1 的 \( n \times n \) 实矩阵在矩阵乘法下构成群。<sup>[2](https://itamar.web.illinois.edu/Teaching/417_FW26/Notes/node-What-is-abstract-algebra-anyway.html)</sup>
- 对任意集合 \( S \)，其幂集在并集下 \( (S, \cup) \) 是幺半群，单位元为 \( \varnothing \)；在交集下 \( (S, \cap) \) 是幺半群，单位元为 \( S \)。<sup>[9](https://cs.yale.edu/homes/aspnes/pinewiki/AlgebraicStructures.html)</sup>

## 与群及其他结构的关系

幺半群 \( M \) 中的元素 \( m \) 称为可逆的，如果存在 \( n \) 使得 \( mn = nm = 1 \)；这样的逆元若存在则唯一。可逆元素之集 \( M^{\times} \) 对乘法封闭，满足 \( (xy)^{-1} = y^{-1}x^{-1} \)，并构成一个群。幺半群是群，当且仅当 \( M = M^{\times} \)。<sup>[1](https://math.umd.edu/~pbrosnan/notes/ugalg/sect0011.html)</sup>

幺半群位于代数结构的层级之中。半群是带结合运算而不要求单位元的集合；加上单位元得到幺半群；再要求逆元得到群。更大的结构建立在幺半群之上：环是加法下的阿贝尔群连同乘法下的幺半群结构，两者由分配律联系。<sup>[10](https://www.csee.umbc.edu/~artola/studyaids/AbstractAlgebraPrimer.pdf)</sup> 在半环中，加法部分是一个交换幺半群而非阿贝尔群。<sup>[9](https://cs.yale.edu/homes/aspnes/pinewiki/AlgebraicStructures.html)</sup>

## 范畴论中的幺半群

幺半群可以描述为只有一个对象的范畴：幺半群的元素成为该对象到自身的态射，单位元成为恒等态射，幺半群运算成为态射的复合，而复合自动满足结合律。<sup>[3](https://ncatlab.org/nlab/show/monoid)</sup><sup> • </sup><sup>[11](https://www.andreaminini.net/math/monoid-category)</sup>

定义可以进一步推广。幺半范畴是配有张量积双函子、单位对象以及协调的结合同构与单位同构的范畴；这样的范畴中的幺半群对象是一个对象 \( M \)，配有乘法态射 \( \mu : M \otimes M \to M \) 与单位态射 \( \eta : I \to M \)，使结合律与单位律图表交换。集合的笛卡尔幺半范畴中的幺半群就是普通的幺半群，而环是配备张量积的阿贝尔群范畴中的幺半群对象。<sup>[4](https://math.mit.edu/~hrm/palestine/maclane-categories.pdf)</sup><sup> • </sup><sup>[12](https://math.jhu.edu/~tclingm1/store/cats.pdf)</sup> 在这个意义上，幺半范畴的概念是幺半群概念的范畴化。<sup>[13](https://math.mit.edu/~etingof/egnobookfinal.pdf)</sup>

## 计算与自动机理论中的幺半群

幺半群是自动机理论的代数骨架。在 1958 年至 1962 年间的一系列论文中，马塞尔-保罗·舒岑贝格尔（Marcel-Paul Schützenberger）确立了幺半群——带单位的半群——作为自动机理论的基本结构，他证明了有限状态机的状态，看作机器无法区分的字符串等价类的同态像，构成一个幺半群。<sup>[14](https://rutherfordjournal.org/article030107.html)</sup> 该领域的中心定理指出，一个语言是正则的，当且仅当它被某个有限幺半群接受。<sup>[5](https://lat.inf.tu-dresden.de/teaching/ss2015/AL/lecture-log.html)</sup>

在编程中，幺半群公理刻画了可组合的聚合。Haskell 将该结构编码为 `Monoid` 类型类，带有一个二元运算和一个单位元，而 `Foldable` 库用它把任意集合折叠为单个值。<sup>[15](https://downloads.haskell.org/~ghc/8.6.2/docs/html/libraries/base-4.12.0.0/Data-Foldable.html)</sup>

## 字问题

对于由表现 \( \mathrm{Mon}\langle A \mid R \rangle \) 给出的幺半群，字问题要求一个算法，给定生成元上的两个词 \( u, v \)，判定在该幺半群中是否有 \( u = v \)。1947 年，安德烈·马尔可夫（Andrey Markov）与埃米尔·波斯特（Emil Post）几乎同时证明了存在字问题不可判定的有限表现幺半群，这一结果被称为数学基础之外的首个不可判定性结果。<sup>[7](https://link.springer.com/article/10.1007/s00233-021-10216-8)</sup> 由于幺半群的字问题一般是不可判定的，近年来的工作集中于为特定感兴趣的幺半群验证可判定性：一个面向 Rocq 证明助手的工具箱可以验证给定幺半群字问题的可判定性，有时还能给出判定过程，这一方法已被应用于文献中的大型表现以及一个包含一百万个单关系幺半群的数据库。<sup>[6](https://research.vu.nl/en/publications/certifying-the-decidability-of-the-word-problem-in-monoids-at-lar/)</sup>

## 历史

幺半群——带单位元的半群——这一概念相对年轻。“semigroupe”一词于 1904 年首次出现在 J.-A. 德·塞吉耶（J.-A. de Séguier）的《抽象群论基础》（*Éléments de la théorie des groupes abstraits*）中，当时指的是如今所谓的可消半群；德·塞吉耶引入这一概念，是为了命名那些在有限时构成群、在无限时不构成群的系统。伦纳德·尤金·迪克森（Leonard Eugene Dickson）在 1904 年对德·塞吉耶著作的书评以及 1905 年的一篇论文中将该词带入英语世界，后者是首篇使用“semigroup”一词的原创论文，其中将半群定义为可消的结合结构。1905 年至 1940 年间，该词被用于若干相关概念，而半群的代数理论本身直到二十世纪下半叶才发展起来。<sup>[16](https://old.maa.org/node/448084)</sup><sup> • </sup><sup>[17](https://api.pageplace.de/preview/DT0400.9783110812909_A19971971/preview-9783110812909_A19971971.pdf)</sup>

## References

1. [UMD 403: Undergraduate Algebra, Monoids and Groups](https://math.umd.edu/~pbrosnan/notes/ugalg/sect0011.html)
2. [MATH 417: What is abstract algebra, anyway? University of Illinois](https://itamar.web.illinois.edu/Teaching/417_FW26/Notes/node-What-is-abstract-algebra-anyway.html)
3. [Monoid, nLab](https://ncatlab.org/nlab/show/monoid)
4. [VII. Monoids, in Categories for the Working Mathematician (Mac Lane), MIT mirror](https://math.mit.edu/~hrm/palestine/maclane-categories.pdf)
5. [Automata and Logic, lecture log, TU Dresden](https://lat.inf.tu-dresden.de/teaching/ss2015/AL/lecture-log.html)
6. [Certifying the Decidability of the Word Problem in Monoids at Large, Vrije Universiteit Amsterdam](https://research.vu.nl/en/publications/certifying-the-decidability-of-the-word-problem-in-monoids-at-lar/)
7. [The word problem for one-relation monoids: a survey, Semigroup Forum](https://link.springer.com/article/10.1007/s00233-021-10216-8)
8. [Introduction to monoids, Mikołaj Bojańczyk, University of Warsaw](https://www.mimuw.edu.pl/~bojan/20142015-2/alg/1-introduction-to-monoids)
9. [AlgebraicStructures, Yale University](https://cs.yale.edu/homes/aspnes/pinewiki/AlgebraicStructures.html)
10. [An Abstract Algebra Primer, UMBC](https://www.csee.umbc.edu/~artola/studyaids/AbstractAlgebraPrimer.pdf)
11. [Monoid Category Explained, Andrea Minini](https://www.andreaminini.net/math/monoid-category)
12. [Monoids in monoidal categories, Johns Hopkins University notes](https://math.jhu.edu/~tclingm1/store/cats.pdf)
13. [Etingof et al., Introduction to representation theory, Chapter 2: Monoidal categories](https://math.mit.edu/~etingof/egnobookfinal.pdf)
14. [The Rutherford Journal: history of automata theory and Schützenberger](https://rutherfordjournal.org/article030107.html)
15. [Data.Foldable, GHC base library documentation](https://downloads.haskell.org/~ghc/8.6.2/docs/html/libraries/base-4.12.0.0/Data-Foldable.html)
16. [Mathematics Across the Iron Curtain: A History of the Algebraic Theory of Semigroups, MAA](https://old.maa.org/node/448084)
17. [de Gruyter Expositions in Mathematics 29, preview (history of the monoid concept)](https://api.pageplace.de/preview/DT0400.9783110812909_A19971971/preview-9783110812909_A19971971.pdf)

---
*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: 物质世界与数学 › 数学与统计学 › 数与代数 › Algebraic structures › Universal algebra and category theory › Universal algebra foundations

Copyright 2026 Edgepedia

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

Source: https://www.edgepedia.org/zh/monoid

English original: https://www.edgepedia.org/monoid
