1命題と集合の対応
全体集合 U を固定し、述語 P(x) の真理集合を
S_P=\{x\in U\mid P(x)\}
とする。このとき、論理演算と集合演算は次のように対応する。
| 論理 | 集合 |
| P\land Q | S_P\cap S_Q |
| P\lor Q | S_P\cup S_Q |
| \lnot P | U\setminus S_P |
| P\Rightarrow Q | S_P\subseteq S_Q |
| P\Leftrightarrow Q | S_P=S_Q |
この対応により、論理式の変形を集合演算として読むことができる。
1Correspondence between propositions and sets
Fix a universal set U, and let the truth set真理集合しんりしゅうごう of a predicate P(x) be
S_P=\{x\in U\mid P(x)\}.
Then logical operations and set operations correspond as follows.
| Logic | Set |
| P\land Q | S_P\cap S_Q |
| P\lor Q | S_P\cup S_Q |
| \lnot P | U\setminus S_P |
| P\Rightarrow Q | S_P\subseteq S_Q |
| P\Leftrightarrow Q | S_P=S_Q |
This correspondence lets us read transformations of logical formulas as set operations集合演算しゅうごうえんざん.
2冪集合べきしゅうごうpower setはブール代数Boolean algebraになる
任意にんいの集合しゅうごう U に対たいして、冪集合べきしゅうごうpower set \mathcal P(U) は、包含順序ほうがんじゅんじょ、和集合わしゅうごう、共通部分きょうつうぶぶん、補集合ほしゅうごうによってブール代数Boolean algebraになる。
X\vee Y=X\cup Y
X\wedge Y=X\cap Y
\neg X=U\setminus X
ここで \vee は結むすびjoin、\wedge は交まじわりmeetに対応たいおうする。
data/lecture/math/discrete-math/べき集合の基本-講義.n.md
2A power set冪集合べきしゅうごう is a Boolean algebraブール代数だいすう
For any set U, the power set冪集合べきしゅうごう \mathcal P(U) becomes a Boolean algebra using the inclusion order, union, intersection, and complement.
X\vee Y=X\cup Y
X\wedge Y=X\cap Y
\neg X=U\setminus X
Here \vee corresponds to join結むすび, and \wedge corresponds to meet交まじわり.
data/lecture/math/discrete-math/べき集合の基本-講義.n.md
3ド・モルガンの法則De Morgan's laws
ド・モルガンの法則De Morgan's lawsは、否定ひていが「かつ」と「または」を入いれ替かえることを表あらわす。
論理ろんりでは
\lnot(P\land Q)\Leftrightarrow (\lnot P)\lor(\lnot Q)
\lnot(P\lor Q)\Leftrightarrow (\lnot P)\land(\lnot Q)
である。集合しゅうごうでは
U\setminus(A\cap B)=(U\setminus A)\cup(U\setminus B)
U\setminus(A\cup B)=(U\setminus A)\cap(U\setminus B)
である。
3De Morgan's lawsド・モルガンの法則
De Morgan's lawsド・モルガンの法則 say that negation interchanges “and” and “or.”
In logic,
\lnot(P\land Q)\Leftrightarrow (\lnot P)\lor(\lnot Q)
\lnot(P\lor Q)\Leftrightarrow (\lnot P)\land(\lnot Q)
and for sets,
U\setminus(A\cap B)=(U\setminus A)\cup(U\setminus B)
U\setminus(A\cup B)=(U\setminus A)\cap(U\setminus B).
4何なにを抽象化ちゅうしょうかしているか
ブール代数Boolean algebraは、対象たいしょうが命題めいだいなのか集合しゅうごうなのかをいったん忘わすれて、演算えんざんの満みたす法則ほうそくだけを見みる。保存ほぞんされるのは、結むすび、交まじわり、補元ほげん、最大元さいだいげん、最小元さいしょうげんに関かんする構造こうぞうである。
この抽象化ちゅうしょうかにより、論理回路ろんりかいろ、集合族しゅうごうぞく、条件分岐じょうけんぶんき、検索条件けんさくじょうけんの組くみ合あわせを同おなじ形式けいしきで扱あつかえる。
具体的ぐたいてきな命題めいだいpropositionや集合しゅうごうsetを置おき換かえても、同おなじ結むすびjoin・交まじわりmeet・補元ほげんcomplementの法則ほうそくで計算けいさんできることが要点ようてんである。対象たいしょうそのものではなく、演算えんざんが保存ほぞんする構造こうぞうを見みている。
4What is being abstracted
Boolean algebraブール代数だいすう temporarily ignores whether the objects are propositions or sets, and focuses only on the laws satisfied by the operations. The preserved structure concerns joins結むすび, meets交まじわり, complements補元ほげん, greatest elements, and least elements.
This abstraction lets logical circuits, families of sets, conditional branches, and search conditions be handled by the same formal rules.
The point is that even after replacing concrete propositions命題めいだい or sets集合しゅうごう, calculations use the same laws for joins結むすび, meets交まじわり, and complements補元ほげん. We are looking at the structure preserved by the operations, not at the objects themselves.
5証明しょうめい補足ほそく:補元ほげんcomplementの一意性いちいせい
ブール代数だいすうBoolean algebra で x の補元ほげんcomplement が一意いちいであることを示しめす。y と z がどちらも x の補元ほげんだとする。つまり
x\wedge y=0,
\quad x\vee y=1,
\qquad
x\wedge z=0,
\quad x\vee z=1
である。このとき
y=y\wedge 1
=y\wedge (x\vee z)
=(y\wedge x)\vee (y\wedge z)
=0\vee (y\wedge z)
=y\wedge z
\le z.
同おなじ議論ぎろんで z\le y も従したがうので、反対称性はんたいしょうせいantisymmetryより y=z である。
5Proof supplement: uniqueness of complements補元ほげん
In a Boolean algebraブール代数だいすう, the complement補元ほげん of x is unique. Suppose y and z are both complements of x, meaning
x\wedge y=0,
\quad x\vee y=1,
\qquad
x\wedge z=0,
\quad x\vee z=1.
Then
y=y\wedge 1
=y\wedge (x\vee z)
=(y\wedge x)\vee (y\wedge z)
=0\vee (y\wedge z)
=y\wedge z
\le z.
The same argument gives z\le y, so antisymmetry反対称性はんたいしょうせい implies y=z.
6証明しょうめい補足ほそく:ド・モルガンの法則De Morgan's laws
補元ほげんcomplementの一意性いちいせいを使つかうと、ド・モルガンの法則ほうそくDe Morgan's laws も見通みとおしよく証明しょうめいできる。たとえば x\wedge y の補元ほげんが x'\vee y' であることを示しめせばよい。
(x\wedge y)\wedge (x'\vee y')
=((x\wedge y)\wedge x')\vee((x\wedge y)\wedge y')=0,
(x\wedge y)\vee (x'\vee y')
=(x\vee x'\vee y')\wedge (y\vee x'\vee y')=1.
よって補元ほげんの一意性いちいせいから
(x\wedge y)'=x'\vee y'
である。同おなじ方法ほうほうで (x\vee y)'=x'\wedge y' も得えられる。
6Proof supplement: De Morgan's lawsド・モルガンの法則
Using uniqueness of complements補元ほげん, De Morgan's lawsド・モルガンの法則 can be proved cleanly. For example, it is enough to show that x'\vee y' is a complement of x\wedge y.
(x\wedge y)\wedge (x'\vee y')
=((x\wedge y)\wedge x')\vee((x\wedge y)\wedge y')=0,
(x\wedge y)\vee (x'\vee y')
=(x\vee x'\vee y')\wedge (y\vee x'\vee y')=1.
Therefore uniqueness of complements gives
(x\wedge y)'=x'\vee y'.
The same method gives (x\vee y)'=x'\wedge y'.