10.2 Cardinal numbers
Definition 10.2.1.
The type of cardinal numbers
is the 0-truncation of the type \setof sets:
π’πΊππ½:β‘β₯\setβ₯0 |
Thus, a cardinal number, or cardinal, is an inhabitant of Cardβ‘β₯\setβ₯0.
Technically, of course, there is a separate type CardU associated to each universe U.
As usual for truncations, if A is a set, then |A|0 denotes its image under the canonical projection \setββ₯\setβ₯0β‘π’πΊππ½; we call |A|0 the cardinality of A.
By definition, π’πΊππ½ is a set.
It also inherits the structure of a semiring from \set.
Definition 10.2.2.
The operation of cardinal addition
(β+β):π’πΊππ½βπ’πΊππ½βπ’πΊππ½ |
is defined by induction on truncation:
|A|0+|B|0:β‘|A+B|0. |
Proof.
Since π’πΊππ½βπ’πΊππ½ is a set, to define (Ξ±+β):π’πΊππ½βπ’πΊππ½ for all Ξ±:π’πΊππ½, by induction it suffices to assume that Ξ± is |A|0 for some A:\set. Now we want to define (|A|0+β):π’πΊππ½βπ’πΊππ½, i.e. we want to define |A|0+Ξ²:π’πΊππ½ for all Ξ²:π’πΊππ½. However, since π’πΊππ½ is a set, by induction it suffices to assume that Ξ² is |B|0 for some B:\set. But now we can define |A|0+|B|0 to be |A+B|0. β
Definition 10.2.3.
Similarly, the operation of cardinal multiplication
(ββ β):π’πΊππ½βπ’πΊππ½βπ’πΊππ½ |
is defined by induction on truncation:
|A|0β |B|0:β‘|AΓB|0 |
Lemma 10.2.4.
π’πΊππ½ is a commutative semiring, i.e. for Ξ±,Ξ²,Ξ³:Card we have the following.
(Ξ±+Ξ²)+Ξ³ | =Ξ±+(Ξ²+Ξ³) | ||
Ξ±+0 | =Ξ± | ||
Ξ±+Ξ² | =Ξ²+Ξ± | ||
(Ξ±β Ξ²)β Ξ³ | =Ξ±β (Ξ²β Ξ³) | ||
Ξ±β 1 | =Ξ± | ||
Ξ±β Ξ² | =Ξ²β Ξ± | ||
Ξ±β (Ξ²+Ξ³) | =Ξ±β Ξ²+Ξ±β Ξ³ |
where 0:β‘|0|0 and 1:β‘|1|0.
Proof.
We prove the commutativity of multiplication, Ξ±β
Ξ²=Ξ²β
Ξ±; the others are exactly analogous.
Since π’πΊππ½ is a set, the type Ξ±β
Ξ²=Ξ²β
Ξ± is a mere proposition, and in particular a set.
Thus, by induction it suffices to assume Ξ± and Ξ² are of the form |A|0 and |B|0 respectively, for some A,B:\set.
Now |A|0β
|B|0β‘|AΓB|0 and |B|0Γ|A|0β‘|BΓA|0, so it suffices to show AΓB=BΓA.
Finally, by univalence, it suffices to give an equivalence AΓBβBΓA.
But this is easy: take (a,b)β¦(b,a) and its obvious inverse.
β
Definition 10.2.5.
The operation of cardinal exponentiation is also defined by induction on truncation:
|A|0|B|0:β‘|BβA|0. |
Lemma 10.2.6.
For Ξ±,Ξ²,Ξ³:Card we have
Ξ±0 | =1 | ||
1Ξ± | =1 | ||
Ξ±1 | =Ξ± | ||
Ξ±Ξ²+Ξ³ | =Ξ±Ξ²β Ξ±Ξ³ | ||
Ξ±Ξ²β Ξ³ | =(Ξ±Ξ²)Ξ³ | ||
(Ξ±β Ξ²)Ξ³ | =Ξ±Ξ³β Ξ²Ξ³ |
Proof.
Exactly like \autorefcard:semiring. β
Definition 10.2.7.
The relation of cardinal inequality
(ββ€β):π’πΊππ½βπ’πΊππ½βπ―πππ |
is defined by induction on truncation:
|A|0β€|B|0:β‘β₯πππ(A,B)β₯ |
where inj(A,B) is the type of injections from A to B. In other words, |A|0β€|B|0 means that there merely exists an injection from A to B.
Lemma 10.2.8.
Cardinal inequality is a preorder, i.e. for Ξ±,Ξ²:Card we have
Ξ±β€Ξ± | ||
(Ξ±β€Ξ²)β(Ξ²β€Ξ³)β(Ξ±β€Ξ³) |
Proof.
As before, by induction on truncation.
For instance, since (Ξ±β€Ξ²)β(Ξ²β€Ξ³)β(Ξ±β€Ξ³) is a mere proposition, by induction on 0-truncation we may assume Ξ±, Ξ², and Ξ³ are |A|0, |B|0, and |C|0 respectively.
Now since |A|0β€|C|0 is a mere proposition, by induction on (-1)-truncation we may assume given injections f:AβB and g:BβC.
But then gβf is an injection from A to C, so |A|0β€|C|0 holds.
Reflexivity is even easier.
β
We may likewise show that cardinal inequality is compatible with the semiring operations.
Lemma 10.2.9.
Consider the following statements:
-
1.
There is an injection AβB.
-
2.
There is a surjection BβA.
Then, assuming excluded middle:
- β’
- β’
-
β’
Assuming the axiom of choice
, we have 2 β merely 1.
Proof.
If f:AβB is an injection, define g:BβA at b:B as follows. Since f is injective, the fiber of f at b is a mere proposition. Therefore, by excluded middle, either there is an a:A with f(a)=b, or not. In the first case, define g(b):β‘a; otherwise set g(b):β‘a0. Then for any a:A, we have a=g(f(a)), so g is surjective.
The second statement follows from this by induction on truncation. For the third, if g:BβA is surjective, then by the axiom of choice, there merely exists a function f:AβB with g(f(a))=a for all a. But then f must be injective. β
Theorem 10.2.10 (SchroederβBernstein).
Assuming excluded middle, for sets A and B we have
πππ(A,B)βπππ(B,A)β(Aβ B) |
Proof.
The usual βback-and-forthβ argument applies without significant changes.
Note that it actually constructs an isomorphism Aβ
B (assuming excluded middle so that we can decide whether a given element belongs to a cycle, an infinite chain, a chain beginning in A, or a chain beginning in B).
β
Corollary 10.2.11.
Assuming excluded middle, cardinal inequality is a partial order, i.e. for Ξ±,Ξ²:Card we have
(Ξ±β€Ξ²)β(Ξ²β€Ξ±)β(Ξ±=Ξ²). |
Proof.
Since Ξ±=Ξ² is a mere proposition, by induction on truncation we may assume Ξ± and Ξ² are |A|0 and |B|0, respectively, and that we have injections f:AβB and g:BβA. But then the SchroederβBernstein theorem gives an isomorphism AβB, hence an equality |A|0=|B|0. β
Finally, we can reproduce Cantorβs theorem, showing that for every cardinal there is a greater one.
Theorem 10.2.12 (Cantor).
For A:\set, there is no surjection Aβ(Aβ2).
Proof.
Suppose f:Aβ(Aβπ) is any function, and define g:Aβπ by g(a):β‘Β¬f(a)(a).
If g=f(a0), then g(a0)=f(a0)(a0) but g(a0)=Β¬f(a0)(a0), a contradiction.
Thus, f is not surjective.
β
Corollary 10.2.13.
Assuming excluded middle, for any Ξ±:Card, there is a cardinal Ξ² such that Ξ±β€Ξ² and Ξ±β Ξ².
Proof.
Let Ξ²=2Ξ±. Now we want to show a mere proposition, so by induction we may assume Ξ± is |A|0, so that Ξ²β‘|Aβπ|0. Using excluded middle, we have a function f:Aβ(Aβπ) defined by
f(a)(aβ²):β‘{1πa=aβ²0πaβ aβ². |
And if f(a)=f(aβ²), then f(aβ²)(a)=f(a)(a)=1π, so a=aβ²; hence f is injective. Thus, Ξ±β‘|A|0β€|Aβπ|0β‘2Ξ±.
On the other hand, if 2Ξ±β€Ξ±, then we would have an injection (Aβπ)βA. By \autorefthm:injsurj, since we have (Ξ»x.β0π):Aβπ and excluded middle, there would then be a surjection Aβ(Aβπ), contradicting Cantorβs theorem. β
Title | 10.2 Cardinal numbers |
---|---|
\metatable |