# モナドとモノイダル圏：随伴から代数を、テンソル積から圏の構造を取り出す

> 随伴がモナドを定め、Eilenberg–Moore 圏が終対象・Kleisli 圏が始対象になることを証明し、モノイドと G 集合をモナドの代数として特徴づける。モノイダル圏・閉モノイダル圏の基本性質と、加群・超ベクトル空間・前層の圏の例を扱う。
> https://rikai.mugen-giken.com/mathematics/category-homological-algebra/monads-monoidal-categories

## 0. この記事の要点

文字の列を「列の列」にして、それを一つの列につなぎ直す操作を考えてみてください。たとえば (ab, c) と (d) という列の列は abcd にまとめられ、どの順序で何度つなぎ直しても同じ結果になります。この記事は、このように「まとめる操作」が満たす規則を取り出した構造（モナド）と、それを使って群やモノイドといった代数系を捉え直す方法を説明します。後半では、加群のテンソル積のように二つの対象から一つの対象を作る操作をもつ圏（モノイダル圏）を整理し、読み終えると、モナドがその圏の中のモノイドとして読めることが分かります。

- 自己関手 $T$ と[自然変換](/mathematics/category-homological-algebra/categories-functors#def-natural-transformation) $\mu : TT \Rightarrow T$、$\eta : \mathrm{Id} \Rightarrow T$ が結合律と単位律を満たすとき、$(T, \mu, \eta)$ を**モナド**といいます。[随伴](/mathematics/category-homological-algebra/adjoint-functors#def-adjunction) $F \dashv G$ は必ずモナド $GF$ を定めます。
- 逆にモナド $T$ からは二つの随伴が作れます。$T$ **代数**の圏（**Eilenberg–Moore 圏**）$\mathcal{C}^{T}$ への自由–忘却随伴と、**Kleisli 圏** $\mathcal{C}_{T}$ への随伴です。$T$ を与える随伴の中で、前者は[終対象](/mathematics/category-homological-algebra/categories-functors#def-initial-terminal)、後者は始対象になります（比較関手の存在と一意性。比較関手とは、$T$ を与える随伴からこれらの圏への関手のことです）。
- リストモナドの代数はモノイドで、$G \times (-)$ モナドの代数は $G$ 集合です。比較関手が[圏同値](/mathematics/category-homological-algebra/categories-functors#def-equivalence)になる関手を**モナド的**といい、「代数系の忘却関手」を圏論の言葉で特徴づける概念です。
- **モノイダル圏**は結合律と単位律を同型の形で満たすテンソル積 $\otimes$ をもつ圏で、組紐・対称の構造を加えられます。モナドは自己関手の圏（合成をテンソル積とする）の**モノイド対象**です。
- **閉モノイダル圏**では $\otimes$ が[余極限](/mathematics/category-homological-algebra/limits-colimits#def-limit)を保ち、内部 Hom（$(-) \otimes Y$ の右随伴として得られる対象 $[Y, Z]$）について $[X \otimes Y, Z] \cong [X, [Y, Z]]$ が成り立ちます。$\mathsf{Set}$、小さい圏の圏 $\mathsf{Cat}$、前層の圏は[デカルト閉](/mathematics/category-homological-algebra/kan-extensions-presheaves#def-cartesian-closed)、$\mathsf{Mod}_A$ は対称モノイダル閉で、超ベクトル空間は Koszul の符号 $(-1)^{|v||w|}$（奇数次どうしを入れ替えるときだけ $-1$ が付く規則）を対称とする対称モノイダル圏です。

<Aside type="tip" title="この記事で使う事前知識">

- **関手と自然変換**: 関手は圏から圏への対応、自然変換は二つの関手の間を、各対象での射でつなぐ対応。→ [自然変換](/mathematics/category-homological-algebra/categories-functors#def-natural-transformation)
- **随伴**: 関手 $F$、$G$ の間の Hom 集合の自然な全単射 $\operatorname{Hom}(FX, Y) \cong \operatorname{Hom}(X, GY)$ を与える関係。→ [随伴](/mathematics/category-homological-algebra/adjoint-functors#def-adjunction)
- **単位・余単位と三角等式**: 随伴に付随する二つの自然変換と、それらが満たす二つの等式。→ [単位・余単位](/mathematics/category-homological-algebra/adjoint-functors#def-unit-counit)
- **圏同値**: 互いに「逆」になる関手の対（合成が恒等関手と自然同型）をもつ二つの圏の関係。→ [圏同値](/mathematics/category-homological-algebra/categories-functors#def-equivalence)
- **デカルト閉圏**: 積をとる関手が右随伴（指数対象）をもつ圏。→ [デカルト閉圏](/mathematics/category-homological-algebra/kan-extensions-presheaves#def-cartesian-closed)

</Aside>

## 1. 動機

[随伴関手と随伴関手定理](/mathematics/category-homological-algebra/adjoint-functors) で、自由群 ⊣ 忘却、自由加群 ⊣ 忘却などの随伴を見ました。集合 $X$ に「$X$ 上の自由群の台集合」を対応させる関手 $T = UF$ には、二つの自然な構造があります。$X$ の元を長さ 1 の語と見る写像 $X \to TX$ と、「語の語」をつなげて一つの語にする写像 $TTX \to TX$ です。群 $G$ の構造は、語を評価する写像 $TG \to G$ で完全に記述できます。こうして「代数系」を自己関手とその上の代数として捉える枠組みがモナドです。モナドは代数的位相幾何学の bar 構成と単体的分解、ホモロジー代数の標準分解（群のコホモロジーの章で使う群環上の分解）の背後にある構造で、計算機科学では副作用をもつ計算を記述する言葉（Moggi）として使われています。

もう一つの主題であるモノイダル圏は、「テンソル積をもつ圏」の公理化です。加群のテンソル積、集合の直積、群の表現のテンソル積、超ベクトル空間の符号つきテンソル積、関手の合成は、どれも結合律と単位律を「同型を除いて」満たします。その同型がどう両立するかを決めたのが Mac Lane（1963）で、この枠組みは表現論のテンソル圏、量子群、位相的場の量子論（Atiyah–Segal の公理は対称モノイダル関手として述べられます）、代数的場の量子論の超選択セクターの理論に共通の言葉を与えます。

記号は前の章までと同じです。とくに随伴の単位・余単位と三角等式は <Ref to="mathematics/category-homological-algebra/adjoint-functors#def-unit-counit" />、自然変換のホイスカリング（$\beta F$、$H\alpha$）と[水平合成](/mathematics/category-homological-algebra/categories-functors#def-functor-category)は <Ref to="mathematics/category-homological-algebra/categories-functors#def-functor-category" /> の記法を使います。

## 2. モナドと代数

### 2.1. モナド

<Definition id="def-monad" title="モナド・余モナド">
圏 $\mathcal{C}$ 上の**モナド**とは、関手 $T : \mathcal{C} \to \mathcal{C}$ と自然変換 $\mu : TT \Rightarrow T$（**乗法**）、$\eta : \mathrm{Id}_{\mathcal{C}} \Rightarrow T$（**単位**）の組 $(T, \mu, \eta)$ で、
$$
\mu \circ T\mu = \mu \circ \mu T, \qquad \mu \circ T\eta = \mathrm{id}_T = \mu \circ \eta T
$$
を満たすものをいう（成分で書けば $\mu_X \circ T(\mu_X) = \mu_X \circ \mu_{TX}$、$\mu_X \circ T(\eta_X) = \mathrm{id}_{TX} = \mu_X \circ \eta_{TX}$）。双対的に、関手 $G$ と自然変換 $\delta : G \Rightarrow GG$、$\varepsilon : G \Rightarrow \mathrm{Id}$ で $G\delta \circ \delta = \delta G \circ \delta$、$\varepsilon G \circ \delta = \mathrm{id}_G = G\varepsilon \circ \delta$ を満たすものを**余モナド**という。
</Definition>

<Proposition id="prop-adjunction-monad" title="随伴はモナドを定める">
$F : \mathcal{C} \to \mathcal{D}$、$G : \mathcal{D} \to \mathcal{C}$ を随伴 $F \dashv G$ とし、単位を $\eta$、余単位を $\varepsilon$ とする。このとき $(GF, G\varepsilon F, \eta)$ は $\mathcal{C}$ 上のモナドであり、$(FG, F\eta G, \varepsilon)$ は $\mathcal{D}$ 上の余モナドである。
</Proposition>

証明のねらいは、モナドの二つの法則を随伴の[三角等式](/mathematics/category-homological-algebra/adjoint-functors#def-unit-counit)から導くことです。結合律には $\varepsilon$ の自然性（射 $f : D \to D'$ について $f \circ \varepsilon_D = \varepsilon_{D'} \circ FG(f)$ が成り立つこと）を射 $\varepsilon_{FX}$ に当てはめて使い、単位律には三角等式を使います。

<Proof of="prop-adjunction-monad">
$T = GF$、$\mu = G\varepsilon F$（成分 $\mu_X = G(\varepsilon_{FX})$）とおく。$\eta$、$\varepsilon$ は三角等式 $\varepsilon F \circ F\eta = \mathrm{id}_F$、$G\varepsilon \circ \eta G = \mathrm{id}_G$ を満たす（<Ref to="mathematics/category-homological-algebra/adjoint-functors#thm-adjunction-equivalent" />）。

**結合律.** $\varepsilon$ の自然性を射 $\varepsilon_{FX} : FGFX \to FX$ に適用すると $\varepsilon_{FX} \circ FG(\varepsilon_{FX}) = \varepsilon_{FX} \circ \varepsilon_{FGFX}$。両辺に $G$ を施すと
$$
\mu_X \circ T(\mu_X) = G(\varepsilon_{FX})\, GFG(\varepsilon_{FX}) = G(\varepsilon_{FX})\, G(\varepsilon_{FGFX}) = \mu_X \circ \mu_{TX}.
$$

**単位律.** 第 2 の三角等式を $FX$ で使うと $\mu_X \circ \eta_{TX} = G(\varepsilon_{FX})\eta_{GFX} = \mathrm{id}_{GFX}$。第 1 の三角等式に $G$ を施すと $\mu_X \circ T(\eta_X) = G(\varepsilon_{FX}F(\eta_X)) = \mathrm{id}_{GFX}$。

$\mu$ が自然変換であることは、ホイスカリングが自然変換を与えること（<Ref to="mathematics/category-homological-algebra/categories-functors#prop-interchange" />）による。余モナドについては、$F \dashv G$ が反対圏の随伴 $G^{\mathrm{op}} \dashv F^{\mathrm{op}}$（単位は $\varepsilon$、余単位は $\eta$ の反対）と同じであることに注意して前半を適用する。
</Proof>

<Example id="ex-monad-examples" title="モナドの例">
(a) **リストモナド**。集合 $X$ に有限列全体 $TX = \bigsqcup_{n \ge 0} X^{n}$（$X^{0}$ は空列だけ）を対応させ、$\eta_X(x) = (x)$、$\mu_X$ を「列の列」を順につなげる写像とします。$TX$ は $X$ 上の自由モノイドの台集合で、このモナドは自由モノイド ⊣ 忘却の随伴から来ます（<Ref to="prop-list-monad" />）。

(b) **作用のモナド**。群 $G$ について $TX = G \times X$、$\eta_X(x) = (e, x)$、$\mu_X(g, (h, x)) = (gh, x)$。

(c) **冪集合モナド**。$\mathcal{P}_*$ を像で作用する共変な冪集合関手（<Ref to="mathematics/category-homological-algebra/categories-functors#ex-functors" /> の (f)）とし、$\eta_X(x) = \{x\}$、$\mu_X(\mathcal{A}) = \bigcup\mathcal{A}$ とします。

(d) **自由群のモナド**。<Ref to="mathematics/category-homological-algebra/adjoint-functors#cor-free-group" /> の随伴 $F \dashv U$ から <Ref to="prop-adjunction-monad" /> で得られるモナド $UF$。$\mu$ は、自由群 $F(UF(X))$ の元（語の語）を、余単位 $FUF(X) \to F(X)$ で評価して一つの語にする写像です。

(e) **閉包作用素**。半順序集合を圏と見ると（<Ref to="mathematics/category-homological-algebra/categories-functors#ex-small-categories" />）、モナドは単調写像 $c$ で $x \le c(x)$、$c(c(x)) \le c(x)$（よって $c(c(x)) = c(x)$）を満たすもの、すなわち閉包作用素です。位相空間の閉包 $A \mapsto \bar A$ や、部分集合が生成する部分群をとる操作がその例です。
</Example>

### 2.2. Eilenberg–Moore 圏

<Definition id="def-em-algebra" title="T 代数と Eilenberg–Moore 圏">
$(T, \mu, \eta)$ を $\mathcal{C}$ 上のモナドとする。**$T$ 代数**とは、対象 $A$ と射 $a : TA \to A$（**構造射**）の組 $(A, a)$ で
$$
a \circ \eta_A = \mathrm{id}_A, \qquad a \circ T(a) = a \circ \mu_A
$$
を満たすものをいう。$T$ 代数の射 $f : (A, a) \to (B, b)$ は $f \circ a = b \circ T(f)$ を満たす $\mathcal{C}$ の射とする。$T$ 代数とその射の圏を $\mathcal{C}^{T}$（**Eilenberg–Moore 圏**）、$(A, a) \mapsto A$ で定まる忘却関手を $U^{T} : \mathcal{C}^{T} \to \mathcal{C}$ と書く。
</Definition>

$T$ 代数の射の合成は射であり（$gf a = g b T(f) = c T(g)T(f)$）、恒等射も射なので、$\mathcal{C}^{T}$ は圏で、$U^{T}$ は忠実です。$\mathcal{C}$ が局所的に小さければ $\mathcal{C}^{T}$ もそうです。

<Theorem id="thm-eilenberg-moore" title="Eilenberg–Moore の随伴">
$(T, \mu, \eta)$ を $\mathcal{C}$ 上のモナドとする。

1. 各 $X$ について $(TX, \mu_X)$ は $T$ 代数（**自由 $T$ 代数**）であり、$F^{T}(X) = (TX, \mu_X)$、$F^{T}(f) = T(f)$ は関手 $F^{T} : \mathcal{C} \to \mathcal{C}^{T}$ を定める。
2. $F^{T} \dashv U^{T}$ で、その単位は $\eta$、余単位は $\varepsilon^{T}_{(A, a)} = a : (TA, \mu_A) \to (A, a)$ である。随伴の全単射は $g \mapsto g \circ \eta_X$、逆は $f \mapsto a \circ T(f)$ で与えられる。
3. この随伴が <Ref to="prop-adjunction-monad" /> で定めるモナドは $(T, \mu, \eta)$ 自身である。

</Theorem>

証明の方針は、自由 $T$ 代数 $(TX, \mu_X)$ が $X$ から忘却関手 $U^{T}$ への[普遍射](/mathematics/category-homological-algebra/yoneda-lemma#def-universal-arrow)になることを直接示し、普遍射から随伴が得られるという前の章の定理に当てはめることです。

<Proof of="thm-eilenberg-moore">
**1.** $(TX, \mu_X)$ の公理は $\mu_X \eta_{TX} = \mathrm{id}$ と $\mu_X T(\mu_X) = \mu_X\mu_{TX}$ で、モナドの単位律と結合律そのものである。$f : X \to Y$ について $T(f)\mu_X = \mu_Y TT(f)$（$\mu$ の自然性）なので $T(f)$ は $T$ 代数の射で、関手性は $T$ の関手性から従う。

**2.** $X$ から $U^{T}$ への普遍射が $(F^{T}X, \eta_X)$ であることを示す。$T$ 代数 $(A, a)$ と射 $f : X \to A$ について $\bar f = a \circ T(f)$ とおく。$\bar f$ は代数の射である：$\mu$ の自然性と代数の公理から
$$
\bar f \circ \mu_X = a\, T(f)\, \mu_X = a\, \mu_A\, TT(f) = a\, T(a)\, TT(f) = a \circ T(\bar f).
$$
$\eta$ の自然性と $a\eta_A = \mathrm{id}$ から $\bar f\eta_X = a\,T(f)\,\eta_X = a\,\eta_A f = f$。一意性：代数の射 $g : (TX, \mu_X) \to (A, a)$ が $g\eta_X = f$ を満たせば、単位律 $\mu_X T(\eta_X) = \mathrm{id}$ と $g$ が射であることから
$$
g = g\,\mu_X\,T(\eta_X) = a\,T(g)\,T(\eta_X) = a\,T(f) = \bar f .
$$
<Ref to="mathematics/category-homological-algebra/adjoint-functors#thm-adjoint-from-universal-arrows" /> により左随伴が得られ、それは $f$ を $U^{T}(F(f))\eta_X = \eta_Y f$ を満たすただ一つの代数の射に送る。$\eta$ の自然性から $T(f)$ がこれを満たすので、左随伴は $F^{T}$ に一致する。全単射は <Ref to="mathematics/category-homological-algebra/adjoint-functors#thm-adjunction-equivalent" /> の $\varphi(g) = U^{T}(g)\eta_X$ で、その逆は上の $\bar f$ である。余単位は $\mathrm{id}_A$ の転置 $a \circ T(\mathrm{id}_A) = a$。

**3.** $U^{T}F^{T} = T$（対象と射の両方で）、単位は $\eta$、乗法は $U^{T}(\varepsilon^{T}_{F^{T}X}) = \mu_X$（自由代数 $(TX, \mu_X)$ の構造射）である。
</Proof>

自由 $T$ 代数への射は生成元 $X$ での値で決まる、という 2 の内容は、自由群・自由加群の普遍性の一般形です。

### 2.3. Kleisli 圏

<Definition id="def-kleisli" title="Kleisli 圏">
$(T, \mu, \eta)$ を $\mathcal{C}$ 上のモナドとする。**Kleisli 圏** $\mathcal{C}_{T}$ を、対象は $\mathcal{C}$ と同じ、$\operatorname{Hom}_{\mathcal{C}_{T}}(X, Y) = \operatorname{Hom}_{\mathcal{C}}(X, TY)$、合成を
$$
g \circ_T f = \mu_Z \circ T(g) \circ f \qquad (f : X \to TY,\ g : Y \to TZ)
$$
恒等射を $\eta_X : X \to TX$ として定める。関手 $F_T : \mathcal{C} \to \mathcal{C}_T$ を $F_T(X) = X$、$F_T(f) = \eta_Y \circ f$ で、$U_T : \mathcal{C}_T \to \mathcal{C}$ を $U_T(X) = TX$、$U_T(f) = \mu_Y \circ T(f)$ で定める。
</Definition>

$\mathcal{C}_T$ の射 $X \to Y$ は「$Y$ の元を返すのではなく、$TY$ の元を返す計算」です。たとえば冪集合モナドでは、$X \to \mathcal{P}(Y)$ は $X$ から $Y$ への関係（多価写像）で、Kleisli 合成は関係の合成です（<Ref to="exr-powerset-kleisli" />）。

<Theorem id="thm-kleisli" title="Kleisli の随伴">
<Ref to="def-kleisli" /> の $\mathcal{C}_T$ は圏で、$F_T$、$U_T$ は関手であり、恒等写像 $\operatorname{Hom}_{\mathcal{C}_T}(F_TX, Y) = \operatorname{Hom}_{\mathcal{C}}(X, U_TY)$ は随伴 $F_T \dashv U_T$ を与える。この随伴が定めるモナドは $(T, \mu, \eta)$ である。
</Theorem>

<Proof of="thm-kleisli">
**圏であること.** 単位法則：$f : X \to TY$ について、$\eta$ の自然性と単位律から $f \circ_T \eta_X = \mu_Y T(f)\eta_X = \mu_Y\eta_{TY}f = f$、$\eta_Y \circ_T f = \mu_Y T(\eta_Y) f = f$。結合法則：$h : Z \to TW$ について、$\mu$ の自然性 $T(h)\mu_Z = \mu_{TW}TT(h)$ と結合律から
$$
h \circ_T (g \circ_T f) = \mu_W T(h) \mu_Z T(g) f = \mu_W \mu_{TW} TT(h) T(g) f = \mu_W T(\mu_W) TT(h) T(g) f = (h \circ_T g) \circ_T f .
$$

**関手であること.** $F_T(\mathrm{id}) = \eta$ は恒等射。$\eta$ の自然性と単位律から $F_T(g) \circ_T F_T(f) = \mu_Z T(\eta_Z)T(g)\eta_Y f = T(g)\eta_Y f = \eta_Z g f = F_T(gf)$。$U_T(\eta_X) = \mu_XT(\eta_X) = \mathrm{id}_{TX}$。$\mu$ の自然性と結合律から
$$
U_T(g \circ_T f) = \mu_Z T(\mu_Z) TT(g) T(f) = \mu_Z \mu_{TZ} TT(g) T(f) = \mu_Z T(g) \mu_Y T(f) = U_T(g)\,U_T(f).
$$

**随伴.** 全単射 $\varphi = \mathrm{id}$ の自然性を確かめる。$h : X' \to X$（$\mathcal{C}$ の射）について $f \circ_T F_T(h) = \mu_Y T(f)\eta_X h = f h$。$k : Y \to Y'$（$\mathcal{C}_T$ の射）について $k \circ_T f = \mu_{Y'}T(k) f = U_T(k) \circ f$。よって $X$、$Y$ の両方について自然である（<Ref to="mathematics/category-homological-algebra/adjoint-functors#def-adjunction" />）。

**モナド.** 単位は $\varphi(\mathrm{id}_{F_TX}) = \eta_X$、$U_TF_T(f) = \mu_Y T(\eta_Y)T(f) = T(f)$ なので $U_TF_T = T$。余単位 $\varepsilon_Y$ は $\mathrm{id}_{TY}$ を $\mathcal{C}_T$ の射 $TY \to Y$ と見たもので、乗法は $U_T(\varepsilon_{F_TX}) = \mu_X T(\mathrm{id}_{TX}) = \mu_X$ である。
</Proof>

### 2.4. 比較関手とモナド的関手

一つのモナド $T$ を与える随伴は一般に多数あります。それらを比べるのが比較関手です。

<Theorem id="thm-comparison-functor" title="比較関手">
$F : \mathcal{C} \to \mathcal{D}$、$G : \mathcal{D} \to \mathcal{C}$ を随伴 $F \dashv G$（単位 $\eta$、余単位 $\varepsilon$）とし、$(T, \mu, \eta) = (GF, G\varepsilon F, \eta)$ をそのモナドとする。

1. （**Eilenberg–Moore 圏は終対象**）$U^{T}K = G$ かつ $KF = F^{T}$ を満たす関手 $K : \mathcal{D} \to \mathcal{C}^{T}$ がただ一つ存在し、$K(D) = (GD, G(\varepsilon_D))$、$K(g) = G(g)$ で与えられる。$K$ を**比較関手**という。
2. （**Kleisli 圏は始対象**）$GL = U_T$ かつ $LF_T = F$ を満たす関手 $L : \mathcal{C}_T \to \mathcal{D}$ がただ一つ存在し、$L(X) = FX$、$L(f) = \varepsilon_{FY} \circ F(f)$（$f : X \to TY$）で与えられる。

</Theorem>

<Figure caption="定理の関手の関係。実線が左随伴、破線が右随伴（忘却側）で、中央の随伴 F ⊣ G から、Kleisli 圏への L と Eilenberg–Moore 圏への K が定まる。">
<svg viewBox="0 0 640 260" width="100%" role="img" aria-label="随伴、Kleisli 圏、Eilenberg–Moore 圏と比較関手の関係図">
  <defs>
    <marker id="mn-arr2" markerWidth="8" markerHeight="8" refX="6" refY="3" orient="auto">
      <path d="M 0 0 L 6 3 L 0 6 z" fill="currentColor" />
    </marker>
  </defs>
  <text x="90" y="60" fill="currentColor" font-size="16" text-anchor="middle">C_T</text>
  <text x="320" y="60" fill="currentColor" font-size="16" text-anchor="middle">D</text>
  <text x="550" y="60" fill="currentColor" font-size="16" text-anchor="middle">C^T</text>
  <text x="320" y="225" fill="currentColor" font-size="16" text-anchor="middle">C</text>
  <line x1="115" y1="52" x2="298" y2="52" stroke="var(--sl-color-accent)" stroke-width="2" marker-end="url(#mn-arr2)" />
  <text x="205" y="42" fill="currentColor" font-size="14" text-anchor="middle">L</text>
  <line x1="342" y1="52" x2="523" y2="52" stroke="var(--sl-color-accent)" stroke-width="2" marker-end="url(#mn-arr2)" />
  <text x="432" y="42" fill="currentColor" font-size="14" text-anchor="middle">K</text>
  <line x1="305" y1="205" x2="305" y2="80" stroke="currentColor" stroke-width="1.5" marker-end="url(#mn-arr2)" />
  <text x="292" y="145" fill="currentColor" font-size="14" text-anchor="end">F</text>
  <line x1="335" y1="80" x2="335" y2="205" stroke="currentColor" stroke-width="1.5" stroke-dasharray="5 4" marker-end="url(#mn-arr2)" />
  <text x="348" y="145" fill="currentColor" font-size="14">G</text>
  <line x1="288" y1="206" x2="128" y2="86" stroke="currentColor" stroke-width="1.5" marker-end="url(#mn-arr2)" />
  <text x="205" y="162" fill="currentColor" font-size="14" text-anchor="end">F_T</text>
  <line x1="135" y1="76" x2="295" y2="196" stroke="currentColor" stroke-width="1.5" stroke-dasharray="5 4" marker-end="url(#mn-arr2)" />
  <text x="212" y="122" fill="currentColor" font-size="14">U_T</text>
  <line x1="352" y1="206" x2="512" y2="86" stroke="currentColor" stroke-width="1.5" marker-end="url(#mn-arr2)" />
  <text x="435" y="162" fill="currentColor" font-size="14">F^T</text>
  <line x1="505" y1="76" x2="345" y2="196" stroke="currentColor" stroke-width="1.5" stroke-dasharray="5 4" marker-end="url(#mn-arr2)" />
  <text x="428" y="122" fill="currentColor" font-size="14" text-anchor="end">U^T</text>
</svg>
</Figure>

証明の方針は、存在については $K$、$L$ を式で与えて関手であることを確かめ、一意性については、条件 $U^{T}K = G$、$KF = F^{T}$（および $GL = U_T$、$LF_T = F$）だけから $K$ の構造射と $L$ の射への作用が決まってしまうことを示すことです。

<Proof of="thm-comparison-functor">
**1, 存在.** $(GD, G\varepsilon_D)$ は $T$ 代数である。単位の公理は第 2 の三角等式 $G(\varepsilon_D)\eta_{GD} = \mathrm{id}$。結合の公理は、$\varepsilon$ の自然性を射 $\varepsilon_D$ に適用した $\varepsilon_D \circ FG(\varepsilon_D) = \varepsilon_D \circ \varepsilon_{FGD}$ に $G$ を施して
$$
G(\varepsilon_D) \circ T(G\varepsilon_D) = G(\varepsilon_D) \circ G(\varepsilon_{FGD}) = G(\varepsilon_D) \circ \mu_{GD}.
$$
$g : D \to D'$ について、$\varepsilon$ の自然性 $g\varepsilon_D = \varepsilon_{D'}FG(g)$ に $G$ を施すと $G(g)G(\varepsilon_D) = G(\varepsilon_{D'})T(G(g))$ で、$G(g)$ は代数の射である。よって $K$ は関手で $U^{T}K = G$。$KF(X) = (GFX, G\varepsilon_{FX}) = (TX, \mu_X) = F^{T}X$、$KF(f) = GF(f) = T(f) = F^{T}(f)$。

**1, 一意性.** $K'$ も条件を満たすとする。$U^{T}K' = G$ から $K'(D) = (GD, a_D)$、$K'(g) = G(g)$ と書ける。射 $\varepsilon_D : FGD \to D$ の像 $K'(\varepsilon_D) = G(\varepsilon_D)$ は代数の射 $K'FGD = F^{T}GD = (TGD, \mu_{GD}) \to (GD, a_D)$ なので、$G(\varepsilon_D)\mu_{GD} = a_D\, T(G\varepsilon_D)$。右から $T(\eta_{GD})$ を合成すると、左辺は単位律から $G(\varepsilon_D)$、右辺は第 2 の三角等式から $a_D\,T(G(\varepsilon_D)\eta_{GD}) = a_D$。よって $a_D = G(\varepsilon_D)$ で、$K' = K$。

**2, 一意性.** $L$ が条件を満たすとする。$LF_T = F$ から $L(X) = FX$。$\mathcal{C}_T$ の任意の射 $f : X \to Y$（$\mathcal{C}$ の射 $X \to TY$）は、$\mathrm{id}_{TY}$ を $\mathcal{C}_T$ の射 $e_Y : TY \to Y$ と見ると $e_Y \circ_T F_T(f) = \mu_Y T(\mathrm{id})\eta_{TY}f = f$ と分解するので、$L(f) = L(e_Y) \circ F(f)$。$L(e_Y) : FTY \to FY$ の転置（<Ref to="mathematics/category-homological-algebra/adjoint-functors#thm-adjunction-equivalent" /> の $\varphi(g) = G(g)\eta$）は、$GL = U_T$ と第 2 の三角等式から
$$
G(L(e_Y))\,\eta_{TY} = U_T(e_Y)\,\eta_{TY} = \mu_Y\,\eta_{TY} = G(\varepsilon_{FY})\,\eta_{GFY} = \mathrm{id}_{TY}
$$
で、$\varepsilon_{FY}$ の転置 $G(\varepsilon_{FY})\eta_{GFY}$ も $\mathrm{id}_{TY}$ である。転置は全単射なので $L(e_Y) = \varepsilon_{FY}$、よって $L(f) = \varepsilon_{FY}F(f)$。

**2, 存在.** この $L$ が関手であること：$L(\eta_X) = \varepsilon_{FX}F(\eta_X) = \mathrm{id}$（第 1 の三角等式）。$g : Y \to TZ$ について、$\varepsilon$ の自然性を射 $F(g) : FY \to FTZ$ と射 $\varepsilon_{FZ}$ に適用すると、$F(g)\varepsilon_{FY} = \varepsilon_{FTZ}\,FG(F(g))$、$\varepsilon_{FZ}\,FG(\varepsilon_{FZ}) = \varepsilon_{FZ}\,\varepsilon_{FGFZ}$ なので
$$
L(g)L(f) = \varepsilon_{FZ}F(g)\varepsilon_{FY}F(f) = \varepsilon_{FZ}\varepsilon_{FTZ}FGF(g)F(f) = \varepsilon_{FZ}F(G\varepsilon_{FZ})F(GF(g))F(f) = L(g \circ_T f).
$$
最後の等号は $g \circ_T f = G(\varepsilon_{FZ})\,GF(g)\,f$ による。$GL(f) = G(\varepsilon_{FY})GF(f) = \mu_Y T(f) = U_T(f)$、$LF_T(f) = \varepsilon_{FY}F(\eta_Y)F(f) = F(f)$。
</Proof>

<Definition id="def-monadic" title="モナド的関手">
関手 $G : \mathcal{D} \to \mathcal{C}$ が**モナド的**であるとは、$G$ が左随伴 $F$ をもち、随伴 $F \dashv G$ のモナド $T = GF$ についての比較関手 $K : \mathcal{D} \to \mathcal{C}^{T}$（<Ref to="thm-comparison-functor" />）が圏同値（<Ref to="mathematics/category-homological-algebra/categories-functors#def-equivalence" />）であることをいう。
</Definition>

モナド的な関手 $G$ では、$\mathcal{D}$ の対象は「$G$ で見た台と、$T$ 代数の構造」で記述できます。具体例を示すには、次の補題が便利です。

<Lemma id="lem-iso-monadic" title="代数の圏と同型ならモナド的">
$(T, \mu, \eta)$ を $\mathcal{C}$ 上のモナド、$G : \mathcal{D} \to \mathcal{C}$ を関手とし、圏の同型 $\Phi : \mathcal{D} \to \mathcal{C}^{T}$（逆関手 $\Phi^{-1}$ をもつ関手）で $U^{T}\Phi = G$ を満たすものがあるとする。このとき $F = \Phi^{-1}F^{T}$ は $G$ の左随伴で、随伴 $F \dashv G$ のモナドは $(T, \mu, \eta)$、比較関手は $\Phi$ である。とくに $G$ はモナド的である。
</Lemma>

<Proof of="lem-iso-monadic">
$\Phi$ は Hom 集合の間の全単射を与えるので、<Ref to="thm-eilenberg-moore" /> の全単射と合成して
$$
\operatorname{Hom}_{\mathcal{D}}(\Phi^{-1}F^{T}X, D) \cong \operatorname{Hom}_{\mathcal{C}^{T}}(F^{T}X, \Phi D) \cong \operatorname{Hom}_{\mathcal{C}}(X, U^{T}\Phi D) = \operatorname{Hom}_{\mathcal{C}}(X, GD)
$$
が $X$、$D$ について自然な全単射になり、$F \dashv G$。単位は $\mathrm{id}_{FX}$ の像 $\eta_X$、余単位は $\varepsilon_D = \Phi^{-1}(\varepsilon^{T}_{\Phi D})$ である。$GF = U^{T}F^{T} = T$ で、乗法は $G(\varepsilon_{FX}) = U^{T}(\varepsilon^{T}_{F^{T}X}) = \mu_X$（<Ref to="thm-eilenberg-moore" /> の 3）。$\Phi$ は $U^{T}\Phi = G$、$\Phi F = F^{T}$ を満たすので、<Ref to="thm-comparison-functor" /> の 1 の一意性から比較関手は $\Phi$ で、同型は圏同値である。
</Proof>

<Remark id="rem-beck" title="Beck のモナド性定理">
どの関手がモナド的かを判定するのが **Beck のモナド性定理**です。主張は次のとおりです：$G : \mathcal{D} \to \mathcal{C}$ がモナド的であるための必要十分条件は、$G$ が左随伴をもち、同型を反映し、$G$ で分裂する平行な射の組（$G$ を施すと分裂余等化子をもつ組）が $\mathcal{D}$ で余等化子をもち、$G$ がそれを保つことである。この定理から、群・環・加群など「有限個の演算と等式で定義される代数系」の忘却関手はすべてモナド的であり、コンパクト Hausdorff 空間の忘却関手も（超フィルターのモナドについて）モナド的であることが分かります。一方 $\mathsf{Top} \to \mathsf{Set}$ はモナド的ではありません。このテーマでは具体例を <Ref to="lem-iso-monadic" /> で直接扱うので、Beck の定理は使いません。証明は Mac Lane の第 VI 章 §7、Riehl の第 5 章にあります。
</Remark>

### 2.5. モノイドと G 集合

<Proposition id="prop-list-monad" title="リストモナドの代数はモノイド">
$\mathsf{Set}$ 上で、$TX = \bigsqcup_{n \ge 0} X^{n}$（有限列の全体）、$T(f)$ を成分ごとに $f$ を施す写像、$\eta_X(x) = (x)$、$\mu_X$ を列の列を順につなげる写像とする（**リストモナド**）。

1. $(T, \mu, \eta)$ はモナドである。
2. モノイド（結合的な二項演算と単位元をもつ小さい集合）$M$ に、$a_M(x_1, \ldots, x_n) = x_1 x_2 \cdots x_n$（空列は単位元 $1$）を対応させると $(M, a_M)$ は $T$ 代数で、これはモノイドとモノイド準同型の圏 $\mathsf{Mon}$ から $\mathsf{Set}^{T}$ への圏の同型を与える。
3. 忘却関手 $\mathsf{Mon} \to \mathsf{Set}$ はモナド的で、左随伴は $X \mapsto (TX, \text{連結})$（$X$ 上の**自由モノイド**）である。

</Proposition>

<Proof of="prop-list-monad">
**1.** $TX$ は小さい（<Ref to="mathematics/category-homological-algebra/categories-functors#prop-universe-closure" />）。成分ごとの写像は 1 元の列を 1 元の列に、連結を連結に写すので $\eta$、$\mu$ は自然である。$\mu_X T(\mu_X)$ と $\mu_X\mu_{TX}$ はどちらも「列の列の列」を、最も内側の列を順に全部つなげた列に送る。$\mu_XT(\eta_X)$ と $\mu_X\eta_{TX}$ はどちらも $(x_1, \ldots, x_n)$ をそれ自身に送る。

**2.** 列 $w$ について左から順に掛けた積を $P(w)$（$P(()) = 1$、$P(w x) = P(w)\,x$。$wx$ は $w$ の後ろに $x$ を付けた列）とする。列の連結 $uv$ について $P(uv) = P(u)P(v)$ が成り立つ：$v$ の長さについての帰納法で、$v$ が空なら $P(u) = P(u)1$、$P(u v' x) = P(uv')x = (P(u)P(v'))x = P(u)(P(v')x) = P(u)P(v'x)$。これを繰り返し使うと、列の列 $(w_1, \ldots, w_k)$ について
$$
P(w_1 w_2 \cdots w_k) = P(w_1)P(w_2)\cdots P(w_k) = P\bigl((P(w_1), \ldots, P(w_k))\bigr)
$$
（$k$ についての帰納法）。これは $a_M \circ \mu_M = a_M \circ T(a_M)$ で、$a_M\eta_M(x) = 1 \cdot x = x$ と合わせて $(M, a_M)$ は $T$ 代数である。モノイド準同型 $f$ は $f(P(w)) = P(T(f)(w))$（長さについての帰納法）を満たすので代数の射である。

逆に $T$ 代数 $(A, a)$ について、$xy = a((x, y))$、$1 = a(())$ とおく。$\mu((x_1, \ldots, x_{n-1}), (x_n)) = (x_1, \ldots, x_n)$ と $a \circ \mu = a \circ T(a)$、$a((x)) = x$ から
$$
a((x_1, \ldots, x_n)) = a\bigl((a((x_1, \ldots, x_{n-1})), x_n)\bigr) \qquad (\dagger)
$$
である。同様に $\mu$ が列 $((x, y), (z))$ と $((x), (y, z))$ をどちらも $(x, y, z)$ に送ることから $(xy)z = a((x, y, z)) = x(yz)$、$((), (x))$ と $((x), ())$ がどちらも $(x)$ に送られることから $1x = x = x1$。よって $A$ はモノイドで、$(\dagger)$ により $a = P$ である。代数の射 $f$ は、長さ 2 と 0 の列で $f \circ a = a \circ T(f)$ を見れば $f(xy) = f(x)f(y)$、$f(1) = 1$ を満たし、モノイド準同型である。

この二つの対応は互いに逆（モノイドから作った代数の演算は $P((x, y)) = xy$、$P(()) = 1$ に戻り、代数から作ったモノイドの $P$ は $a$ に戻る）で、射は同じ写像なので、$\Phi(M) = (M, a_M)$ は圏の同型 $\mathsf{Mon} \to \mathsf{Set}^{T}$ で、$U^{T}\Phi$ は忘却関手である。

**3.** <Ref to="lem-iso-monadic" /> を $\Phi$ に適用する。左随伴 $\Phi^{-1}F^{T}$ は $X$ を $(TX, \mu_X)$ に対応するモノイド、すなわち連結を積とする $TX$ に送る。
</Proof>

<Proposition id="prop-action-monad" title="作用のモナドの代数は G 集合">
$G$ を小さい群とし、$TX = G \times X$、$T(f) = \mathrm{id}_G \times f$、$\eta_X(x) = (e, x)$、$\mu_X(g, (h, x)) = (gh, x)$ とする。

1. $(T, \mu, \eta)$ は $\mathsf{Set}$ 上のモナドである。
2. $T$ 代数 $(X, a)$ は、$g \cdot x = a(g, x)$ によって $X$ への $G$ の（左）作用（<Ref to="mathematics/algebra/group-actions-sylow#def-action" />）と 1 対 1 に対応し、代数の射は同変写像 $f(g \cdot x) = g \cdot f(x)$ と一致する。とくに $G$ 集合の圏は $\mathsf{Set}^{T}$ と同型である。
3. $G$ 集合の忘却関手はモナド的で、左随伴は $X \mapsto G \times X$（$G$ は左の成分に掛け算で作用する）である。

</Proposition>

<Proof of="prop-action-monad">
**1.** $\eta$、$\mu$ は $X$ 成分に触れないので自然である。$\mu_XT(\mu_X)(g, (h, (k, x))) = (g(hk), x)$、$\mu_X\mu_{TX}(g, (h, (k, x))) = ((gh)k, x)$ で、群の結合法則から等しい。$\mu_XT(\eta_X)(g, x) = (ge, x)$、$\mu_X\eta_{TX}(g, x) = (eg, x)$ はどちらも $(g, x)$。

**2.** 写像 $a : G \times X \to X$ について、$a \circ \eta_X = \mathrm{id}$ は $a(e, x) = x$、$a \circ T(a) = a \circ \mu_X$ は $a(g, a(h, x)) = a(gh, x)$ のことで、これは作用の 2 条件そのものである。$f \circ a = b \circ T(f)$ は $f(a(g, x)) = b(g, f(x))$、すなわち同変性である。

**3.** 2 の同型に <Ref to="lem-iso-monadic" /> を適用する。左随伴は $X$ を自由代数 $(G \times X, \mu_X)$、すなわち $g \cdot (h, x) = (gh, x)$ で作用する $G$ 集合に送る。
</Proof>

二つの命題は同じ形をしています。リストモナドは「$X$ 上の自由モノイド」、作用のモナドは「群 $G$ を $X$ と組にする」もので、後者は次の節の言葉でいえば、モノイダル圏 $(\mathsf{Set}, \times)$ のモノイド対象 $G$ が定めるモナドです。

## 3. モノイダル圏

### 3.1. 定義

この節の目的は、加群のテンソル積や集合の直積に共通する性質を公理にまとめることです。たとえば加群では $(M \otimes N) \otimes P$ と $M \otimes (N \otimes P)$ は別の対象で、自然な同型で結ばれます。その同型（結合子）どうしが、括弧のつけ替えの順序によらず矛盾しないための条件が、次の五角形等式です。

<Definition id="def-monoidal" title="モノイダル圏">
**モノイダル圏** $(\mathcal{M}, \otimes, I, a, l, r)$ とは、圏 $\mathcal{M}$、双関手 $\otimes : \mathcal{M} \times \mathcal{M} \to \mathcal{M}$（**テンソル積**）、対象 $I$（**単位対象**）と、自然同型
$$
a_{X, Y, Z} : (X \otimes Y) \otimes Z \to X \otimes (Y \otimes Z), \qquad l_X : I \otimes X \to X, \qquad r_X : X \otimes I \to X
$$
（**結合子**・左右の**単位子**）の組で、次の二つの等式（**五角形等式**と**三角形等式**）を満たすものをいう。
$$
\begin{aligned}
a_{W, X, Y \otimes Z} \circ a_{W \otimes X, Y, Z} &= (\mathrm{id}_W \otimes a_{X, Y, Z}) \circ a_{W, X \otimes Y, Z} \circ (a_{W, X, Y} \otimes \mathrm{id}_Z), \\
(\mathrm{id}_X \otimes l_Y) \circ a_{X, I, Y} &= r_X \otimes \mathrm{id}_Y .
\end{aligned}
$$
$a$、$l$、$r$ がすべて恒等射であるものを**厳密**なモノイダル圏という。
</Definition>

五角形等式の両辺は $((W \otimes X) \otimes Y) \otimes Z \to W \otimes (X \otimes (Y \otimes Z))$ で、括弧のつけ替えを二通りの順序で行ったものが一致することを言っています。Mac Lane のコヒーレンス定理（<Ref to="rem-coherence" />）によれば、この二つの等式から、結合子と単位子だけで作った図式はすべて可換になります。

<Figure caption="五角形等式。4 つの対象のテンソル積の括弧を、上から右回り（2 本）と左回り（3 本）でつけ替えた結果が一致する。">
<svg viewBox="0 0 640 300" width="100%" role="img" aria-label="モノイダル圏の五角形等式の図">
  <defs>
    <marker id="mn-arr" markerWidth="8" markerHeight="8" refX="6" refY="3" orient="auto">
      <path d="M 0 0 L 6 3 L 0 6 z" fill="currentColor" />
    </marker>
  </defs>
  <text x="320" y="32" fill="currentColor" font-size="15" text-anchor="middle">((W⊗X)⊗Y)⊗Z</text>
  <text x="105" y="135" fill="currentColor" font-size="15" text-anchor="middle">(W⊗(X⊗Y))⊗Z</text>
  <text x="535" y="135" fill="currentColor" font-size="15" text-anchor="middle">(W⊗X)⊗(Y⊗Z)</text>
  <text x="160" y="270" fill="currentColor" font-size="15" text-anchor="middle">W⊗((X⊗Y)⊗Z)</text>
  <text x="480" y="270" fill="currentColor" font-size="15" text-anchor="middle">W⊗(X⊗(Y⊗Z))</text>
  <line x1="360" y1="42" x2="505" y2="115" stroke="var(--sl-color-accent)" stroke-width="2" marker-end="url(#mn-arr)" />
  <text x="450" y="68" fill="currentColor" font-size="13">a</text>
  <line x1="535" y1="145" x2="495" y2="250" stroke="var(--sl-color-accent)" stroke-width="2" marker-end="url(#mn-arr)" />
  <text x="528" y="205" fill="currentColor" font-size="13">a</text>
  <line x1="280" y1="42" x2="135" y2="115" stroke="currentColor" stroke-width="1.5" marker-end="url(#mn-arr)" />
  <text x="160" y="68" fill="currentColor" font-size="13">a ⊗ id</text>
  <line x1="110" y1="145" x2="148" y2="250" stroke="currentColor" stroke-width="1.5" marker-end="url(#mn-arr)" />
  <text x="70" y="205" fill="currentColor" font-size="13">a</text>
  <line x1="230" y1="265" x2="405" y2="265" stroke="currentColor" stroke-width="1.5" marker-end="url(#mn-arr)" />
  <text x="300" y="255" fill="currentColor" font-size="13">id ⊗ a</text>
</svg>
</Figure>

<Definition id="def-symmetric-monoidal" title="組紐モノイダル圏・対称モノイダル圏">
モノイダル圏の**組紐**とは、自然同型 $c_{X, Y} : X \otimes Y \to Y \otimes X$ で、次の二つの**六角形等式**を満たすものをいう。
$$
\begin{aligned}
a_{Y, Z, X} \circ c_{X, Y \otimes Z} \circ a_{X, Y, Z} &= (\mathrm{id}_Y \otimes c_{X, Z}) \circ a_{Y, X, Z} \circ (c_{X, Y} \otimes \mathrm{id}_Z), \\
a^{-1}_{Z, X, Y} \circ c_{X \otimes Y, Z} \circ a^{-1}_{X, Y, Z} &= (c_{X, Z} \otimes \mathrm{id}_Y) \circ a^{-1}_{X, Z, Y} \circ (\mathrm{id}_X \otimes c_{Y, Z}).
\end{aligned}
$$
組紐をもつモノイダル圏を**組紐モノイダル圏**、さらに $c_{Y, X} \circ c_{X, Y} = \mathrm{id}_{X \otimes Y}$ を満たすものを**対称モノイダル圏**という。
</Definition>

六角形等式は「$X$ を $Y \otimes Z$ の向こう側へ一度に移すことは、$Y$、$Z$ の順に一つずつ越えることと同じ」という条件です。組紐では $c_{Y, X}c_{X, Y} \ne \mathrm{id}$ がありえ、$X$ が $Y$ の前を通って越えるか後ろを通って越えるかを区別します。この区別が組紐群・結び目の不変量・量子群の表現論と結びつくのですが、このテーマで扱う例はすべて対称です。

<Lemma id="lem-cartesian-monoidal" title="有限積はモノイダル構造を与える">
圏 $\mathcal{C}$ が終対象 $1$ と任意の 2 対象の積をもつとし、積 $X \times Y$ と射影を選んでおく。$X \otimes Y = X \times Y$、$f \otimes g = f \times g$（$f : X \to X'$、$g : Y \to Y'$ について $p_{X'}(f \times g) = f p_X$、$p_{Y'}(f \times g) = g p_Y$ で定まる射）、$I = 1$ とし、$a$、$l$、$r$、$c$ を「射影との合成が対応する射影になる」ただ一つの射とすると、$\mathcal{C}$ は対称モノイダル圏になる。これを**デカルト・モノイダル構造**という。
</Lemma>

<Proof of="lem-cartesian-monoidal">
$\times$ が双関手であることは <Ref to="mathematics/category-homological-algebra/limits-colimits#prop-limit-unique" /> の 2 による。$X_1, \ldots, X_n$ を何らかの括弧のつけ方で積をとった対象（$1$ を含んでよい）を「反復積」と呼び、それから各 $X_i$ への射影の合成を**葉の射影**と呼ぶ。反復積への 2 本の射は、すべての葉の射影との合成が一致すれば等しい。これは括弧の深さについての帰納法と、積の普遍性の一意性（積への射は射影との合成で決まる）から従う。$1$ の成分は終対象への射なので条件は不要である。

$a$、$l$、$r$、$c$ と、それらと恒等射との $\times$ はどれも、行き先の各葉の射影との合成が、出発点の対応する葉の射影になる射である（$l_X$ は $1 \times X \to X$ の第 2 射影、$r_X$ は第 1 射影、$c_{X, Y}$ は $(p_Y, p_X)$）。この性質は合成で保たれるので、五角形等式・三角形等式・六角形等式の両辺はそれぞれ、葉の射影との合成が同じ射になる、同じ反復積の間の射であり、前段により等しい。$c_{Y, X}c_{X, Y}$ も葉の射影を保つので恒等射である。自然性も、両辺の葉の射影との合成が $f p$ の形で一致することから同様に従い、$a$、$l$、$r$、$c$ は逆も同じ方法で作れるので同型である。
</Proof>

<Remark id="rem-coherence" title="Mac Lane のコヒーレンス定理">
**Mac Lane のコヒーレンス定理**は、モノイダル圏において、結合子・単位子とその逆を $\otimes$ と合成で組み合わせて作った「形式的な」図式がすべて可換であることを主張します。同値な言い方として、任意のモノイダル圏は厳密なモノイダル圏とモノイダル同値です。対称モノイダル圏では対称 $c$ を加えた形式的図式もすべて可換ですが、組紐の場合は組紐群の分だけ非可換な図式が残ります。証明は語の書き換えの議論で長く、このテーマの命題はこの定理を使わずに、具体的な圏で必要な等式を直接確かめます。文献は Mac Lane の第 VII 章 §2 と第 XI 章、Etingof–Gelaki–Nikshych–Ostrik の第 2 章です。
</Remark>

<Definition id="def-monoidal-functor" title="モノイダル関手">
モノイダル圏 $\mathcal{M}$、$\mathcal{N}$ の間の（**緩い**）**モノイダル関手**とは、関手 $F : \mathcal{M} \to \mathcal{N}$ と、自然変換 $\varphi_{X, Y} : FX \otimes FY \to F(X \otimes Y)$、射 $\varphi_0 : I_{\mathcal{N}} \to F(I_{\mathcal{M}})$ の組で、
$$
\begin{aligned}
F(a_{X, Y, Z}) \circ \varphi_{X \otimes Y, Z} \circ (\varphi_{X, Y} \otimes \mathrm{id}) &= \varphi_{X, Y \otimes Z} \circ (\mathrm{id} \otimes \varphi_{Y, Z}) \circ a_{FX, FY, FZ}, \\
F(l_X) \circ \varphi_{I, X} \circ (\varphi_0 \otimes \mathrm{id}) &= l_{FX}, \\
F(r_X) \circ \varphi_{X, I} \circ (\mathrm{id} \otimes \varphi_0) &= r_{FX}
\end{aligned}
$$
を満たすものをいう。$\varphi$、$\varphi_0$ が同型のとき**強**モノイダル関手、恒等射のとき**厳密**なモノイダル関手という。$\mathcal{M}$、$\mathcal{N}$ が対称（組紐）で、さらに $F(c_{X, Y}) \circ \varphi_{X, Y} = \varphi_{Y, X} \circ c_{FX, FY}$ を満たすものを**対称**（**組紐**）**モノイダル関手**という。
</Definition>

忘却関手 $(\mathsf{Mod}_A, \otimes_A) \to (\mathsf{Set}, \times)$ は、$\varphi(m, n) = m \otimes n$、$\varphi_0(\ast) = 1$ によって緩いモノイダル関手で、一般には強ではありません。双線形写像 $M \times N \to M \otimes N$ は一般に全単射でないからです（たとえば $A = k$ が体で $M = N = k^{2}$ なら、像は階数 1 以下のテンソルだけで全射ではありません）。

<Definition id="def-monoid-object" title="モノイド対象">
モノイダル圏 $(\mathcal{M}, \otimes, I)$ の**モノイド対象**とは、対象 $A$ と射 $m : A \otimes A \to A$（乗法）、$u : I \to A$（単位）の組で
$$
m \circ (m \otimes \mathrm{id}_A) = m \circ (\mathrm{id}_A \otimes m) \circ a_{A, A, A}, \qquad m \circ (u \otimes \mathrm{id}_A) = l_A, \qquad m \circ (\mathrm{id}_A \otimes u) = r_A
$$
を満たすものをいう。モノイド対象の射 $f : (A, m, u) \to (A', m', u')$ は $f \circ m = m' \circ (f \otimes f)$、$f \circ u = u'$ を満たす射とする。$\mathcal{M}$ が対称で $m \circ c_{A, A} = m$ のとき、**可換**モノイド対象という。
</Definition>

$(\mathsf{Set}, \times, 1)$（<Ref to="lem-cartesian-monoidal" />）のモノイド対象は、定義を書き下せばモノイドそのものです（$u$ は単位元 $u(\ast)$ を指定し、二つの単位の等式は $1x = x = x1$）。

### 3.2. モナドは自己関手のモノイド

<Proposition id="prop-monad-monoid" title="モナドは自己関手の圏のモノイド対象">
圏 $\mathcal{C}$ について、自己関手の圏 $[\mathcal{C}, \mathcal{C}]$ に、$F \otimes G = F \circ G$、自然変換については水平合成 $\beta \otimes \alpha = \beta * \alpha$、$I = \mathrm{Id}_{\mathcal{C}}$ を入れ、$a$、$l$、$r$ を恒等射とすると、厳密なモノイダル圏になる。そのモノイド対象 $(T, \mu, \eta)$ は $\mathcal{C}$ 上のモナドにほかならず、モノイド対象の射は $\theta \circ \mu = \mu' \circ (\theta * \theta)$、$\theta \circ \eta = \eta'$ を満たす自然変換 $\theta : T \Rightarrow T'$（モナドの射）である。
</Proposition>

証明のねらいは、モナドの三つの等式とモノイド対象の三つの等式が、記号を書き換えるだけで一致することを見ることです。先に、自己関手の圏が（厳密な）モノイダル圏になることを確かめます。

<Proof of="prop-monad-monoid">
**双関手であること.** $\otimes$ の射への作用が合成を保つことは交換法則 $(\beta' \circ \beta) * (\alpha' \circ \alpha) = (\beta' * \alpha') \circ (\beta * \alpha)$（<Ref to="mathematics/category-homological-algebra/categories-functors#prop-interchange" />）そのもので、$\mathrm{id}_H * \mathrm{id}_F = \mathrm{id}_{HF}$ は定義から明らか（成分は $\mathrm{id}_{HFX} \circ H(\mathrm{id}_{FX})$）。

**厳密な結合律と単位律.** 関手の合成は結合的で $\mathrm{Id}$ を単位とする。自然変換についても、$\alpha : F \Rightarrow F'$、$\beta : H \Rightarrow H'$、$\gamma : K \Rightarrow K'$ について
$$
((\gamma * \beta) * \alpha)_X = \gamma_{H'F'X}\, K(\beta_{F'X})\, KH(\alpha_X) = \gamma_{H'F'X}\, K\bigl(\beta_{F'X} H(\alpha_X)\bigr) = (\gamma * (\beta * \alpha))_X
$$
で、$\mathrm{id}_{\mathrm{Id}} * \alpha = \alpha = \alpha * \mathrm{id}_{\mathrm{Id}}$ も成分を見れば分かる。したがって $a$、$l$、$r$ を恒等射とすると自然同型で、五角形・三角形等式は恒等射どうしの等式として成り立つ。

**モノイド対象.** <Ref to="mathematics/category-homological-algebra/categories-functors#def-functor-category" /> の記法で $\mu * \mathrm{id}_T = \mu T$、$\mathrm{id}_T * \mu = T\mu$、$\eta * \mathrm{id}_T = \eta T$、$\mathrm{id}_T * \eta = T\eta$ である。よって <Ref to="def-monoid-object" /> の三つの等式は $\mu \circ \mu T = \mu \circ T\mu$、$\mu \circ \eta T = \mathrm{id}_T$、$\mu \circ T\eta = \mathrm{id}_T$ となり、<Ref to="def-monad" /> の公理と一致する。射についても定義を書き直しただけである。
</Proof>

「モナドは自己関手の圏のモノイドにすぎない」という標語の内容がこの命題です。$\mathcal{C}$ が大きいと $[\mathcal{C}, \mathcal{C}]$ の Hom は小さいとは限りませんが、モノイダル圏の定義に局所的な小ささは要りません。

## 4. 閉モノイダル圏

<Definition id="def-closed-monoidal" title="閉モノイダル圏と内部 Hom">
モノイダル圏 $(\mathcal{M}, \otimes, I)$ が**閉**であるとは、各 $Y$ について関手 $(-) \otimes Y : \mathcal{M} \to \mathcal{M}$ が右随伴 $[Y, -]$ をもつことをいう。$[Y, Z]$ を**内部 Hom** という。対称モノイダル圏で閉なものを**対称モノイダル閉圏**という。デカルト閉圏（<Ref to="mathematics/category-homological-algebra/kan-extensions-presheaves#def-cartesian-closed" />）は、<Ref to="lem-cartesian-monoidal" /> のデカルト・モノイダル構造について閉な対称モノイダル圏である。
</Definition>

<Proposition id="prop-internal-hom-adjunction" title="内部 Hom の随伴とその内部化">
$(\mathcal{M}, \otimes, I)$ を局所的に小さい閉モノイダル圏とし、各 $Y, Z$ に内部 Hom $[Y, Z]$ と、$X$ について自然な全単射 $\operatorname{Hom}(X \otimes Y, Z) \cong \operatorname{Hom}(X, [Y, Z])$ を選ぶ。

1. $(Y, Z) \mapsto [Y, Z]$ は双関手 $\mathcal{M}^{\mathrm{op}} \times \mathcal{M} \to \mathcal{M}$ に一意に延び、全単射は $X$、$Y$、$Z$ の三つについて自然になる。
2. $X, Y, Z$ について自然な同型 $[X \otimes Y, Z] \cong [X, [Y, Z]]$ がある。
3. $Z$ について自然な同型 $[I, Z] \cong Z$ がある。

</Proposition>

証明のねらいは、$Y$、$Z$ を動かしても全単射が自然であること（1）と、それを使ってカリー化 $[X \otimes Y, Z] \cong [X, [Y, Z]]$ を示すこと（2）です。1 では前の章の「パラメータ付き表現可能性」（Hom の自然な全単射を表現する対象は、パラメータについても関手的に定まるという命題）を使います。

<Proof of="prop-internal-hom-adjunction">
**1.** $F(X, (Y, Z)) = \operatorname{Hom}(X \otimes Y, Z)$ は $\otimes$ と Hom 双関手（<Ref to="mathematics/category-homological-algebra/categories-functors#prop-hom-bifunctor" />）の合成なので、$\mathcal{M}^{\mathrm{op}} \times (\mathcal{M}^{\mathrm{op}} \times \mathcal{M}) \to \mathsf{Set}$ の双関手である。各 $(Y, Z)$ で $F(-, (Y, Z))$ は $[Y, Z]$ で表現されるので、<Ref to="mathematics/category-homological-algebra/yoneda-lemma#prop-parametrized-representability" /> を $\mathcal{D} = \mathcal{M}^{\mathrm{op}} \times \mathcal{M}$ に、$\mathrm{id}_{[Y, Z]}$ の像を普遍元として適用すれば主張が従う（全単射を自然にする延長は、$\mathrm{id}_{[Y, Z]}$ での自然性から同命題の 1 の条件を満たすので、ほかにない）。

**2.** 対象 $W$ について、次の全単射の合成を考える。
$$
\operatorname{Hom}(W, [X \otimes Y, Z]) \cong \operatorname{Hom}(W \otimes (X \otimes Y), Z) \cong \operatorname{Hom}((W \otimes X) \otimes Y, Z) \cong \operatorname{Hom}(W \otimes X, [Y, Z]) \cong \operatorname{Hom}(W, [X, [Y, Z]]).
$$
1 つ目・3 つ目・4 つ目は 1 の随伴、2 つ目は $a_{W, X, Y}$ との合成である。1 と $a$ の自然性から、合成は $W, X, Y, Z$ のすべてについて自然である。<Ref to="mathematics/category-homological-algebra/yoneda-lemma#prop-parametrized-representability" /> の 3 を、パラメータの圏 $\mathcal{M}^{\mathrm{op}} \times \mathcal{M}^{\mathrm{op}} \times \mathcal{M}$ 上の二つの関手 $(X, Y, Z) \mapsto [X \otimes Y, Z]$ と $(X, Y, Z) \mapsto [X, [Y, Z]]$ に適用すると、両者は自然に同型である。

**3.** 同様に $\operatorname{Hom}(W, [I, Z]) \cong \operatorname{Hom}(W \otimes I, Z) \cong \operatorname{Hom}(W, Z)$（2 つ目は $r_W$ との合成）は $W$、$Z$ について自然なので、同じ命題から $[I, -] \cong \mathrm{Id}$。
</Proof>

2 は「$X \otimes Y$ から $Z$ への射の対象は、$X$ から『$Y$ から $Z$ への射の対象』への射の対象」という、カリー化を対象のレベルで述べたものです。

<Proposition id="prop-closed-colimits" title="閉モノイダル圏のテンソル積は余極限を保つ">
$(\mathcal{M}, \otimes, I)$ を局所的に小さい閉モノイダル圏とする。

1. 各 $Y$ について、$(-) \otimes Y$ は $\mathcal{M}$ に存在する余極限をすべて保ち、$[Y, -]$ は存在する極限をすべて保つ。とくに $\mathcal{M}$ が始対象 $0$ をもてば $0 \otimes Y$ も始対象である。
2. $\mathcal{M}$ が組紐（とくに対称）モノイダル圏なら、$Y \otimes (-)$ も余極限を保つ。さらに各 $Z$ について、$(L, \iota)$ が図式 $D : J \to \mathcal{M}$ の余極限なら、$([L, Z], ([\iota_j, Z])_j)$ は図式 $j \mapsto [D_j, Z]$（$J^{\mathrm{op}} \to \mathcal{M}$）の極限である。

</Proposition>

<Proof of="prop-closed-colimits">
**1.** $(-) \otimes Y \dashv [Y, -]$ なので <Ref to="mathematics/category-homological-algebra/adjoint-functors#thm-rapl" /> による。始対象は空図式の余極限なので保たれる。

**2.** 組紐 $c_{Y, -} : Y \otimes (-) \Rightarrow (-) \otimes Y$ は自然同型である。自然同型 $\gamma : P \Rightarrow P'$ があり $P'$ が余極限 $(L, \iota)$ を保つなら $P$ も保つ。実際、$P$ の像の余錐 $\mu_j : PD_j \to X$ は $\mu_j\gamma_{D_j}^{-1} : P'D_j \to X$ という $P'D$ 下の余錐と 1 対 1 に対応し（自然性から余錐の条件が移る）、$\gamma_L$ がこの対応と $P(\iota)$、$P'(\iota)$ を結ぶので、$(PL, P\iota)$ の普遍性は $(P'L, P'\iota)$ の普遍性から従う。

後半：対象 $W$ について、写像 $\operatorname{Hom}(W, [L, Z]) \to \operatorname{Cone}(W, [D_{-}, Z])$、$u \mapsto ([\iota_j, Z] \circ u)_j$ が全単射であることを示せばよい（<Ref to="mathematics/category-homological-algebra/limits-colimits#prop-hom-continuous" /> の 2）。<Ref to="prop-internal-hom-adjunction" /> の 1 の全単射は $Y$ について自然なので、この写像は随伴で
$$
\operatorname{Hom}(W \otimes L, Z) \to \{(v_j : W \otimes D_j \to Z)_j \text{ で余錐をなすもの}\}, \qquad v \mapsto (v \circ (\mathrm{id}_W \otimes \iota_j))_j
$$
に移る。前半により $(W \otimes L, \mathrm{id}_W \otimes \iota)$ は $W \otimes D$ の余極限なので、これは全単射である。
</Proof>

たとえば $\mathsf{Mod}_A$ では、$M \otimes (\bigoplus_i N_i) \cong \bigoplus_i (M \otimes N_i)$ と $\operatorname{Hom}(\bigoplus_i N_i, P) \cong \prod_i \operatorname{Hom}(N_i, P)$ がこの命題の特別な場合です（下の <Ref to="prop-module-symmetric-closed" /> で $\mathsf{Mod}_A$ が対称モノイダル閉であることを示します）。テンソル積が余核を保つこと、すなわち右完全性もこの命題から従います。

<Proposition id="prop-cartesian-closed-examples" title="デカルト閉圏の例">
次の圏はデカルト閉である。

1. $\mathsf{Set}$。指数対象は写像全体 $Z^{Y}$ で、評価射は $(g, y) \mapsto g(y)$。
2. 小さい圏と関手の圏 $\mathsf{Cat}$。積は積圏、指数対象は関手圏 $[\mathcal{D}, \mathcal{E}]$。
3. 小さい圏 $\mathcal{C}$ 上の前層の圏 $\mathrm{PSh}(\mathcal{C})$。

</Proposition>

<Proof of="prop-cartesian-closed-examples">
**1.** 積と終対象は直積と 1 点集合である（<Ref to="mathematics/category-homological-algebra/limits-colimits#thm-concrete-limits" />）。$Z^{Y}$ は小さい（<Ref to="mathematics/category-homological-algebra/categories-functors#prop-universe-closure" />）。$\Lambda(f)(x) = f(x, -)$ と $\Lambda'(g)(x, y) = g(x)(y)$ は互いに逆の写像 $\operatorname{Hom}(X \times Y, Z) \rightleftarrows \operatorname{Hom}(X, Z^{Y})$ である。$h : X' \to X$、$k : Z \to Z'$ について $\Lambda(k \circ f \circ (h \times \mathrm{id}))(x') = k \circ f(h(x'), -) = k^{Y}(\Lambda(f)(h(x')))$（$k^{Y}(g) = k \circ g$）なので、$\Lambda$ は $X$、$Z$ について自然で、$(-) \times Y \dashv (-)^{Y}$。余単位は $\Lambda'(\mathrm{id}_{Z^{Y}})(g, y) = g(y)$。

**2.** 積圏 $\mathcal{C} \times \mathcal{D}$（<Ref to="mathematics/category-homological-algebra/categories-functors#def-functor" />）は射影関手とともに $\mathsf{Cat}$ の積である（関手 $\mathcal{B} \to \mathcal{C} \times \mathcal{D}$ は成分の関手の組と同じ）。終対象は 1 対象・恒等射だけの圏 $\mathbf{1}$。$[\mathcal{D}, \mathcal{E}]$ は小さい（<Ref to="mathematics/category-homological-algebra/categories-functors#prop-functor-category" /> の 2）。関手 $F : \mathcal{C} \times \mathcal{D} \to \mathcal{E}$ に、$\hat F(c) = F(c, -)$、$\hat F(f) = (F(f, \mathrm{id}_d))_d : F(c, -) \Rightarrow F(c', -)$ を対応させる。$\hat F(f)$ の自然性は、$g : d \to d'$ について $F(f, \mathrm{id}_{d'})F(\mathrm{id}_c, g) = F(f, g) = F(\mathrm{id}_{c'}, g)F(f, \mathrm{id}_d)$ から従い、$\hat F$ が関手であることは $F$ の関手性から従う。逆に関手 $\hat G : \mathcal{C} \to [\mathcal{D}, \mathcal{E}]$ からは、$G(c, -) = \hat G(c)$、$G(-, d) = (c \mapsto \hat G(c)(d),\ f \mapsto \hat G(f)_d)$ とおくと、$\hat G(f)$ の自然性が <Ref to="mathematics/category-homological-algebra/categories-functors#lem-bifunctor" /> の条件そのものなので、ただ一つの双関手 $G$ が得られる。二つの対応は互いに逆で、$\mathcal{C}$ 側の関手との合成、$\mathcal{E}$ 側の関手との合成と可換なので、$\operatorname{Hom}_{\mathsf{Cat}}(\mathcal{C} \times \mathcal{D}, \mathcal{E}) \cong \operatorname{Hom}_{\mathsf{Cat}}(\mathcal{C}, [\mathcal{D}, \mathcal{E}])$ は自然な全単射である。

**3.** <Ref to="mathematics/category-homological-algebra/kan-extensions-presheaves#thm-presheaf-topos" /> の 2。
</Proof>

<Ref to="prop-closed-colimits" /> を 3 に適用すると、前層の圏では積が余極限と分配します（$F \times \operatorname{colim}_j G_j \cong \operatorname{colim}_j (F \times G_j)$）。これはトポス一般で成り立つ性質で、アーベル群の圏のような「加法的」な圏では成り立ちません（<Ref to="exr-ab-not-cartesian-closed" />）。

## 5. 加群・表現・超ベクトル空間

<Proposition id="prop-module-symmetric-closed" title="加群の圏は対称モノイダル閉圏">
$A$ を可換環とする。$\mathsf{Mod}_A$ に、テンソル積 $\otimes_A$、単位対象 $A$ と、
$$
a((m \otimes n) \otimes p) = m \otimes (n \otimes p), \quad l(x \otimes m) = xm, \quad r(m \otimes x) = xm, \quad c(m \otimes n) = n \otimes m
$$
で定まる準同型を入れると、対称モノイダル圏になり、内部 Hom $[N, P] = \operatorname{Hom}_A(N, P)$ によって閉である。とくに体 $k$ 上のベクトル空間の圏 $\mathsf{Vect}_k$ は対称モノイダル閉圏である。
</Proposition>

<Proof of="prop-module-symmetric-closed">
$\otimes$ が双関手であることは <Ref to="mathematics/category-homological-algebra/yoneda-lemma#prop-tensor-representable" /> の 2 による。$a$、$l$、$c$ が well-defined な同型であることは <Ref to="mathematics/commutative-algebra/tensor-flatness-projective-injective#prop-tensor-basic-iso" /> の 2・4・1 で、$r = l \circ c_{M, A}$ も同型である。

**生成元.** $M \otimes N$ は純テンソルで生成される（<Ref to="mathematics/commutative-algebra/tensor-flatness-projective-injective#thm-tensor-existence-module" />）。$(M \otimes N) \otimes P$ の生成元 $z \otimes p$ は、$z = \sum_i m_i \otimes n_i$ と書けば $\sum_i (m_i \otimes n_i) \otimes p$ に等しいので、$(M \otimes N) \otimes P$ は $(m \otimes n) \otimes p$ の形の元で生成される。同様に、何重のテンソル積も、各因子の元の反復した純テンソルで生成される。したがって、二つの準同型が反復した純テンソルの上で一致すれば等しい。

**自然性と等式.** 以下はすべて反復した純テンソルの上で確かめればよい。自然性：たとえば $a \circ ((\alpha \otimes \beta) \otimes \gamma)$ と $(\alpha \otimes (\beta \otimes \gamma)) \circ a$ はどちらも $(m \otimes n) \otimes p \mapsto \alpha(m) \otimes (\beta(n) \otimes \gamma(p))$ で、$l$、$r$、$c$ も同様。五角形等式の両辺はどちらも $((w \otimes x) \otimes y) \otimes z \mapsto w \otimes (x \otimes (y \otimes z))$。三角形等式は、左辺が $(m \otimes x) \otimes n \mapsto m \otimes xn$、右辺が $xm \otimes n$ で、テンソル積の双線形性から $m \otimes xn = x(m \otimes n) = xm \otimes n$。第 1 の六角形等式の両辺は $(m \otimes n) \otimes p \mapsto n \otimes (p \otimes m)$、第 2 の両辺は $m \otimes (n \otimes p) \mapsto (p \otimes m) \otimes n$。$c \circ c = \mathrm{id}$ は明らか（$m \otimes n \mapsto n \otimes m \mapsto m \otimes n$）。

**閉であること.** <Ref to="mathematics/category-homological-algebra/adjoint-functors#prop-tensor-hom-adjunction" /> の 1 により $(-) \otimes N \dashv \operatorname{Hom}_A(N, -)$。
</Proof>

有限次元ベクトル空間では、内部 Hom はさらに $\operatorname{Hom}(V, W) \cong V^{*} \otimes W$ とテンソル積で書けます（<Ref to="mathematics/linear-algebra/tensor-products#thm-tensor-hom" />）。各対象が「双対」をもつこの性質をもつモノイダル圏を剛（rigid）な圏といい、テンソル圏の理論の出発点になります。無限次元では $V^{*} \otimes W \to \operatorname{Hom}(V, W)$ は有限階数の写像の全体にしか届かず、同型ではありません。

<Example id="ex-monoid-objects" title="モノイド対象の例">
(a) $(\mathsf{Ab}, \otimes_{\mathbb{Z}}, \mathbb{Z})$ のモノイド対象は（単位元をもつ）環です。準同型 $m : A \otimes A \to A$ は双加法的な写像 $A \times A \to A$、$(x, y) \mapsto xy$ と同じもので（<Ref to="mathematics/category-homological-algebra/yoneda-lemma#prop-tensor-representable" /> の 1）、準同型 $u : \mathbb{Z} \to A$ は元 $1_A = u(1)$ で決まります。双加法性が分配法則、<Ref to="def-monoid-object" /> の結合の等式を生成元 $(x \otimes y) \otimes z$ で読んだものが積の結合法則、単位の等式が $1_A x = x = x 1_A$ です。モノイド対象の射は環準同型で、可換モノイド対象は可換環です。

(b) 同様に $(\mathsf{Mod}_A, \otimes_A, A)$ のモノイド対象は $A$ 代数（$A$ 双線形な結合的乗法と単位元をもつ $A$ 加群）で、多項式環 $A[x]$ や行列環 $M_n(A)$ がその例です。

(c) <Ref to="prop-monad-monoid" /> により、自己関手の圏のモノイド対象はモナドです。
</Example>

<Example id="ex-representation-tensor" title="群の表現の圏の対称モノイダル構造">
群 $G$ と体 $k$ について、表現 $V, W$ のテンソル積 $V \otimes W$ に $\rho_{V \otimes W}(g) = \rho_V(g) \otimes \rho_W(g)$、すなわち $g(v \otimes w) = gv \otimes gw$ で作用させます。$\otimes$ の関手性 $(\alpha \otimes \beta)(\alpha' \otimes \beta') = \alpha\alpha' \otimes \beta\beta'$ から、これは群準同型 $G \to \mathrm{GL}(V \otimes W)$ です。単位対象は自明な表現 $k$（$g$ は恒等写像で作用）とします。$\mathsf{Vect}_k$ の $a$、$l$、$r$、$c$ は $G$ 準同型です。たとえば $a(g((u \otimes v) \otimes w)) = gu \otimes (gv \otimes gw) = g\,a((u \otimes v) \otimes w)$、$l(g(x \otimes v)) = x\,gv = g(xv)$。$G$ 準同型 $f$、$f'$ のテンソル積も $G$ 準同型です。こうして表現の圏は対称モノイダル圏になり、忘却関手は厳密な対称モノイダル関手です。

さらに $\operatorname{Hom}_k(V, W)$ に $(g \cdot f)(v) = g\,f(g^{-1}v)$ で作用させると、$G$ 準同型 $h : U \otimes V \to W$ と $\hat h(u) = h(u \otimes -)$ の対応で $\operatorname{Hom}_G(U \otimes V, W) \cong \operatorname{Hom}_G(U, \operatorname{Hom}_k(V, W))$ となり、閉でもあります（$\hat h(gu)(v) = h(g(u \otimes g^{-1}v)) = g\,h(u \otimes g^{-1}v) = (g \cdot \hat h(u))(v)$）。有限群の有限次元複素表現（<Ref to="mathematics/algebra/group-representations#def-representation" />）はこれらの操作で閉じているので、それ自身が対称モノイダル閉圏をなします。
</Example>

### 5.1. 超ベクトル空間と Koszul の符号

体 $k$ 上の**超ベクトル空間**とは、ベクトル空間 $V$ と部分空間の直和分解 $V = V_0 \oplus V_1$ の組で、$V_i$ の元を次数 $i$ の斉次元といい $|v| = i$ と書きます（[外積代数・Clifford 代数・超代数](/mathematics/algebra/exterior-clifford-superalgebras) の超代数 <Ref to="mathematics/algebra/exterior-clifford-superalgebras#def-superalgebra" /> から乗法を忘れたもの）。射は $f(V_i) \subseteq W_i$ を満たす線形写像とし、この圏を $\mathsf{SVect}_k$ と書きます。<Ref to="mathematics/commutative-algebra/tensor-flatness-projective-injective#prop-tensor-basic-iso" /> の 3（と、もう一方の変数については 1 と 3）から $V \otimes W = \bigoplus_{i, j} V_i \otimes W_j$ なので、$(V \otimes W)_0 = V_0 \otimes W_0 \oplus V_1 \otimes W_1$、$(V \otimes W)_1 = V_0 \otimes W_1 \oplus V_1 \otimes W_0$ とおけば $V \otimes W$ は超ベクトル空間で、斉次元について $|v \otimes w| = |v| + |w|$（$\mathbb{Z}/2$ で）です。

<Proposition id="prop-super-symmetric" title="超ベクトル空間の対称モノイダル構造">
$\mathsf{SVect}_k$ は、上のテンソル積、単位対象 $k$（$k_0 = k$、$k_1 = 0$）と $\mathsf{Vect}_k$ の $a$、$l$、$r$ によってモノイダル圏であり、斉次元について
$$
c^{s}_{V, W}(v \otimes w) = (-1)^{|v||w|}\, w \otimes v
$$
で定まる $c^{s}$（**Koszul の符号規則**）を対称として、対称モノイダル圏になる。
</Proposition>

<Proof of="prop-super-symmetric">
**モノイダル圏.** 次数を保つ写像のテンソル積は次数を保つ。$a$、$l$、$r$ は斉次元の反復した純テンソルを同じ次数の斉次元に送るので、$\mathsf{SVect}_k$ の射である。五角形・三角形等式と自然性は $\mathsf{Vect}_k$ での等式（<Ref to="prop-module-symmetric-closed" />）で、$\mathsf{SVect}_k$ の射の合成は線形写像としての合成なので、そのまま成り立つ。

**$c^{s}$ の定義.** $v \in V$ を $v = v_0 + v_1$（$v_i \in V_i$）と分解する写像は線形なので、$(v, w) \mapsto \sum_{i, j} (-1)^{ij}\, w_j \otimes v_i$ は双線形で、テンソル積の普遍性（<Ref to="mathematics/commutative-algebra/tensor-flatness-projective-injective#thm-tensor-existence-module" />）から線形写像 $c^{s}_{V, W} : V \otimes W \to W \otimes V$ が定まり、斉次元では上の式になる。$v$、$w$ が斉次なら $w \otimes v$ の次数は $|v| + |w|$ なので、$c^{s}$ は次数を保つ。

**等式.** 各 $v$ は斉次元の和なので、反復したテンソル積は斉次元の反復した純テンソルで生成される（<Ref to="prop-module-symmetric-closed" /> の証明と同じ議論）。以下はその上で確かめればよい。自然性：次数を保つ $f$、$g$ について $(g \otimes f)c^{s}(v \otimes w) = (-1)^{|v||w|}g(w) \otimes f(v) = c^{s}(f(v) \otimes g(w))$（$|f(v)| = |v|$）。対称性：$c^{s}c^{s}(v \otimes w) = (-1)^{2|v||w|}v \otimes w = v \otimes w$。第 1 の六角形等式：左辺は
$$
(u \otimes v) \otimes w \mapsto u \otimes (v \otimes w) \mapsto (-1)^{|u|(|v| + |w|)} (v \otimes w) \otimes u \mapsto (-1)^{|u|(|v| + |w|)}\, v \otimes (w \otimes u),
$$
右辺は $(-1)^{|u||v|}(v \otimes u) \otimes w \mapsto (-1)^{|u||v|} v \otimes (u \otimes w) \mapsto (-1)^{|u||v| + |u||w|}\, v \otimes (w \otimes u)$ で、符号が一致する。第 2 の六角形等式も同様に、両辺とも $u \otimes (v \otimes w) \mapsto (-1)^{(|u| + |v|)|w|}(w \otimes u) \otimes v$ である。
</Proof>

<Remark id="rem-superalgebra-monoid" title="超代数はモノイド対象">
$\mathsf{SVect}_k$ のモノイド対象は、乗法 $A \otimes A \to A$ が次数を保つこと、すなわち $A_aA_b \subseteq A_{a+b}$ を満たす結合代数で、超代数（<Ref to="mathematics/algebra/exterior-clifford-superalgebras#def-superalgebra" />）そのものです。可換性 $m \circ c^{s} = m$ は $ab = (-1)^{|a||b|}ba$、すなわち超可換性になります。対称モノイダル圏では二つのモノイド対象 $A$、$B$ のテンソル積 $A \otimes B$ に、乗法を「中央の $B \otimes A$ を対称で入れ替えてから $m_A \otimes m_B$」で入れられ、$\mathsf{SVect}_k$ でこれを計算すると $(a \otimes b)(a' \otimes b') = (-1)^{|b||a'|}aa' \otimes bb'$ となって、次数付きテンソル積 <Ref to="mathematics/algebra/exterior-clifford-superalgebras#def-graded-tensor" /> が得られます。同じ超ベクトル空間の圏に、符号のない入れ替え $v \otimes w \mapsto w \otimes v$ を対称として入れることもでき、そのときは符号のないテンソル積代数になります。どちらの対称を選ぶかで「可換」の意味が変わる、というのがこの例の要点です。
</Remark>

## 6. 応用への注意

<Remark id="rem-curry-howard" title="単純型付きラムダ計算とデカルト閉圏">
単純型付きラムダ計算（単位型・積型・関数型をもつもの）の型を対象、文脈 $x : A \vdash M : B$ の項（の $\beta\eta$ 同値類）を射 $A \to B$ とすると、デカルト閉圏が得られます。単位型が終対象、積型が積、関数型 $A \to B$ が指数対象 $B^{A}$ で、ラムダ抽象 $\lambda x. M$ が随伴の全単射 $\operatorname{Hom}(C \times A, B) \cong \operatorname{Hom}(C, B^{A})$、関数適用が評価射に当たり、$\beta$ 規則と $\eta$ 規則は随伴の二つの合成が恒等であることに対応します（Lambek）。[単純型付きラムダ計算とカリー＝ハワード対応](/mathematics/logic-and-type-theory/simple-types-curry-howard) の含意の断片の対応（<Ref to="mathematics/logic-and-type-theory/simple-types-curry-howard#thm-curry-howard" />）と並べると、「命題・証明」「型・項」「対象・射」の三つ組が同じ構造をもつことになります。半順序集合としてのデカルト閉圏で有限の余積（最小元と結び）ももつものは Heyting 代数で、直観主義命題論理の代数的意味論を与えます。この注意の内容は読み替えにとどめ、証明には使いません。文献は Lambek–Scott です。
</Remark>

<Remark id="rem-dhr-tensor" title="超選択セクターの対称テンソル圏">
代数的場の量子論では、DHR の超選択セクター（局所化された自己準同型）が、自己準同型の合成をテンソル積、統計作用素を対称とする対称テンソル C* 圏をなします。[超選択セクターと荷電状態](/physics/axiomatic-qft/superselection-charged-sectors) の Doplicher–Roberts の再構成定理（<Ref to="physics/axiomatic-qft/superselection-charged-sectors#thm-doplicher-roberts" />）は、その圏がコンパクト群の有限次元表現の対称モノイダル圏と同値であることを主張します。そこでは主張のみの定理として扱われており、このテーマのどの証明もこの定理を使いません。ここでの関心は、群の表現の圏（<Ref to="ex-representation-tensor" />）がこのような再構成の「答え」の側に現れる、という点にあります。
</Remark>

<Remark id="rem-segal" title="対称モノイダル関手としての場の理論">
Atiyah と Segal の公理系では、$n$ 次元の位相的（または共形）場の量子論は、$(n-1)$ 次元の閉多様体を対象、その間の $n$ 次元の境界つき多様体（コボルディズム）を射とし、非交和をテンソル積とする対称モノイダル圏から、$(\mathsf{Vect}_{\mathbb{C}}, \otimes)$ への対称モノイダル関手として定義されます（<Ref to="def-monoidal-functor" />）。非交和がテンソル積に移ることが、独立な系の状態空間がテンソル積になるという量子力学の原理の表現です。コボルディズム圏の構成は多様体論の準備が要るので、ここでは定義の形だけを紹介します。
</Remark>

## 7. 演習

<Exercise id="exr-maybe-monad" difficulty="易">
$\mathsf{Set}$ 上で $TX = X \sqcup \{\star\}$、$T(f) = f \sqcup \mathrm{id}$、$\eta_X$ を包含、$\mu_X : (X \sqcup \{\star\}) \sqcup \{\star\} \to X \sqcup \{\star\}$ を $X$ 上で恒等、二つの $\star$ をともに $\star$ に送る写像とする。これがモナドであることを確かめ、$T$ 代数が基点つき集合 $(X, x_0)$ と、代数の射が基点を保つ写像と 1 対 1 に対応することを示せ。また Kleisli 圏の射 $X \to Y$ は何と同じものか。
<Solution>
$\eta$、$\mu$ は $X$ の元に触れないので自然です。$\mu_X T(\mu_X)$ と $\mu_X\mu_{TX}$ は $TTTX = X \sqcup \{\star\} \sqcup \{\star\} \sqcup \{\star\}$ の $X$ の元を固定し、三つの $\star$ をすべて $\star$ に送るので等しく、$\mu_XT(\eta_X)$、$\mu_X\eta_{TX}$ はどちらも $TX$ の恒等写像です。

$a : X \sqcup \{\star\} \to X$ について、$a \circ \eta_X = \mathrm{id}$ は「$a$ は $X$ 上で恒等」を意味し、$x_0 = a(\star)$ は任意です。結合の条件 $a \circ T(a) = a \circ \mu_X$ は、$X$ の元では両辺とも恒等、内側の $\star$ では左辺 $a(a(\star)) = a(x_0) = x_0$、右辺 $a(\star) = x_0$、外側の $\star$ では両辺とも $a(\star) = x_0$ なので、自動的に成り立ちます。代数の射の条件 $f \circ a = b \circ T(f)$ は、$X$ の元では自明、$\star$ では $f(x_0) = y_0$ です。Kleisli 圏の射 $X \to Y \sqcup \{\star\}$ は、$\star$ に行く元を「定義されない」とみなせば $X$ から $Y$ への部分写像で、Kleisli 合成は部分写像の合成（どちらかで未定義なら未定義）です。
</Solution>
</Exercise>

<Exercise id="exr-powerset-kleisli" difficulty="標準">
<Ref to="ex-monad-examples" /> の (c) の冪集合モナドがモナドであることを確かめ、その Kleisli 圏が、集合を対象、関係 $R \subseteq X \times Y$ を射とし、合成を $S \circ R = \{(x, z) \mid \exists y,\ (x, y) \in R,\ (y, z) \in S\}$ とする圏と同型であることを示せ。
<Solution>
$\mathfrak{A} \in \mathcal{P}\mathcal{P}\mathcal{P}(X)$ について $\mu_X\mathcal{P}_*(\mu_X)(\mathfrak{A}) = \bigcup_{\mathcal{A} \in \mathfrak{A}} \bigcup\mathcal{A}$ と $\mu_X\mu_{\mathcal{P}X}(\mathfrak{A}) = \bigcup\bigcup\mathfrak{A}$ はどちらも「$\mathfrak{A}$ の元の元の元」全体です。単位律は $\bigcup_{x \in A}\{x\} = A = \bigcup\{A\}$ です。自然性は像と和集合・1 点集合の可換性から従います。Kleisli 圏の射 $f : X \to \mathcal{P}(Y)$ に関係 $R_f = \{(x, y) \mid y \in f(x)\}$ を対応させると全単射で、$g \circ_T f(x) = \bigcup_{y \in f(x)} g(y)$ は $\{z \mid \exists y \in f(x),\ z \in g(y)\}$ なので $R_{g \circ_T f} = R_g \circ R_f$、恒等射 $\eta_X(x) = \{x\}$ は対角関係に対応します。対象の上で恒等、射の上で全単射で合成を保つので、圏の同型です。
</Solution>
</Exercise>

<Exercise id="exr-ab-not-cartesian-closed" difficulty="標準">
アーベル群の圏 $\mathsf{Ab}$ で、積は直和 $A \oplus B$ である。$B \ne 0$ のとき関手 $(-) \times B$ が右随伴をもたないことを示し、$\mathsf{Ab}$ がデカルト閉でないことを結論せよ。一方、$(\mathsf{Ab}, \otimes_{\mathbb{Z}})$ は閉モノイダル圏であることと比べよ。
<Solution>
右随伴をもてば $(-) \times B$ は余極限、とくに始対象を保ちます（<Ref to="mathematics/category-homological-algebra/adjoint-functors#thm-rapl" />）。$\mathsf{Ab}$ の始対象は $0$ ですが、$0 \times B \cong B$ で、$B \ne 0$ なら $\operatorname{Hom}(B, B)$ は恒等写像と零写像という異なる 2 元を含むので $B$ は始対象ではありません。よって右随伴はなく、デカルト閉ではありません。一方 <Ref to="prop-module-symmetric-closed" /> により $(-) \otimes B$ は右随伴 $\operatorname{Hom}(B, -)$ をもち、実際 $0 \otimes B = 0$ です。同じ圏でも、どのモノイダル構造を選ぶかで閉かどうかが変わります。
</Solution>
</Exercise>

<Exercise id="exr-eckmann-hilton" difficulty="難">
モノイドの圏 $\mathsf{Mon}$ に、直積モノイド（成分ごとの積）によるデカルト・モノイダル構造（<Ref to="lem-cartesian-monoidal" />）を入れる。$(\mathsf{Mon}, \times, 1)$ のモノイド対象は可換モノイドにほかならず、そのモノイド対象としての乗法は元のモノイドの積に一致することを示せ（Eckmann–Hilton の議論）。
<Solution>
直積モノイドと射影が $\mathsf{Mon}$ の積であることは、成分ごとの写像が準同型になることから分かります。モノイド $(M, \cdot, 1)$ 上のモノイド対象の構造を $m(x, y) = x * y$、$u(\ast) = e$ とします。$u$ は準同型なので $e = 1$ で、単位の等式から $1 * x = x = x * 1$。$m$ が準同型であることは $(a \cdot c) * (b \cdot d) = (a * b) \cdot (c * d)$ です。すると
$$
a * b = (a \cdot 1) * (1 \cdot b) = (a * 1) \cdot (1 * b) = a \cdot b, \qquad a * b = (1 \cdot a) * (b \cdot 1) = (1 * b) \cdot (a * 1) = b \cdot a .
$$
よって $*$ は $\cdot$ に一致し、$M$ は可換です。逆に可換モノイドでは $(a \cdot c)(b \cdot d) = (a \cdot b)(c \cdot d)$ なので積 $M \times M \to M$ は準同型で、$u(\ast) = 1$ とすればモノイド対象になります。同じ議論は、群の圏の群対象が可換群であることや、位相空間の基本群の高次版（高次ホモトピー群）が可換であることの証明にも現れます。
</Solution>
</Exercise>

## 参考文献

- S. Eilenberg, J. C. Moore, "Adjoint functors and triples", *Illinois Journal of Mathematics* 9 (1965), 381–398.
- H. Kleisli, "Every standard construction is induced by a pair of adjoint functors", *Proceedings of the American Mathematical Society* 16 (1965), 544–546.
- S. Mac Lane, *Categories for the Working Mathematician*, 2nd ed., Graduate Texts in Mathematics 5, Springer, 1998 — 第 VI 章（モナドと代数）、第 VII 章（モノイドとモノイダル圏）、第 XI 章（モノイダル圏の対称と組紐）。
- E. Riehl, *Category Theory in Context*, Dover, 2016 — 第 5 章（モナドとその代数）。
- P. Etingof, S. Gelaki, D. Nikshych, V. Ostrik, *Tensor Categories*, Mathematical Surveys and Monographs 205, American Mathematical Society, 2015 — 第 2 章（モノイダル圏）。
- J. Lambek, P. J. Scott, *Introduction to Higher Order Categorical Logic*, Cambridge Studies in Advanced Mathematics 7, Cambridge University Press, 1986 — 第 I 部（デカルト閉圏とラムダ計算）。
