<<

Elementary topoi

Jordan Mitchell Barrett

November 13, 2020

1 Introduction

As the prototypical , has many properties which make it special amongst categories. From the point of view of mathematical logic, one such property is that Set has enough structure to “properly” formalise logic. However, we could ask what it might mean to formalise logic in another category C. The notion of an (elementary) distills the essential features of Set which allow us to do this. Throughout this report, a boldface C will denote an arbitrary category (and later, a topos). Objects of C are denoted by uppercase letters A, B, C, . . ., and by lowercase f, g, h, . . .. We assume familiarity with basic , but let us recall some of the important categorical notions we will need.

Definition 1.1. An arrow f : B → C in C is monic (denoted f : B,→ C) if for all arrows g, h: A → B, fg = fh implies g = h. Dually, f is epi if for all arrows g, h: C → D, gf = hf implies g = h.

Definition 1.2. A pullback is a over a diagram of shape • • •. More con- cretely, the pullback of two maps f : B → D ← C :g is a pair h: B ← A → C :k making the square commute: A k C

h g

f B D

and which is universal—any other such pair h0 : B ← A0 → C :k0 factors through h, k via a unique t: A0 → A: k0 A0 t arXiv:2011.13070v1 [math.CT] 26 Nov 2020 A k C

0 h h g

f B D

1 Calling it the pullback is justified, since pullbacks are unique up to unique isomor- phism. A useful fact is that if f is monic, its pullback k is monic too [Mac98, Ex. III.4.5].

Definition 1.3. An object 0 ∈ C is initial if for every object A ∈ C, there is a unique arrow !: 0 → A. Dually, 1 ∈ C is terminal if there is a unique arrow !: A → 1 from any object A.

For example, the ∅ is initial in Set, while any set {∗} is terminal. The trivial group {0} is both initial and terminal in Grp and Ab. Definitions 1.1 and 1.3 imply any map 1 → B is monic.

2 classifiers

Henceforth, we will assume that C has all finite limits and colimits. This implies that C has an initial object 0 and terminal object 1, since they are the colimit and limit, respectively, of the empty diagram. For X ∈ C, Xn denotes the n-fold categorical product. The object 2 = {0, 1} in Set plays a very special role, in that for any set X, there is a correspondence between Y ⊆ X and characteristic functions χY : X → 2. In more general categories, this idea is captured by the notion of a subobject classifier.

Definition 2.1. A subobject classifier is an object Ω ∈ C, along with a t: 1 → Ω, such that for every monic f : A,→ B in C, there is a unique map χf : B → Ω, called the character of f, making the following a pullback:

A ! 1

f t χ B f Ω This definition can be recast in a more “categorical” way, using the intuition that Ω determines a natural between Hom(B, Ω) and the “” of B.

Remark 2.2. For B ∈ C, its subobjects Sub(B) are the monics f : A,→ B for some A, modulo of the domain, i.e. f : A,→ B and f 0 : A0 ,→ B are equivalent if there is invertible g : A → A0 making the following commute: A f

g g−1 B

f 0 A0

Define the (contravariant) subobject Sub: C → Set by B 7→ Sub(B), and f : B0 → B maps to Sf : Sub(B) → Sub(B0), the pullback along f:

2 g A B

f

A0 B0 Sf(g) This is well-defined on equivalence classes. Then, a subobject classifier can equivalently be defined as a representation (Ω, ϕ) of Sub, where ϕ: Sub(−) =∼ Hom(−, Ω) is a natural isomorphism. The unique map id1 : 1 → 1 is monic, so a subobject of 1, whence the truth map can be defined t = ϕ1(id1) [Gok97; Lei11, §2]. As expected, the object 2 is indeed a subobject classifier for Set. Let’s see a more interesting example. Example 2.3. For an object X ∈ C, the slice category C/X has maps f : A → X as objects, where morphisms (f : A) → (f 0 : A0) are maps g : A → A0 making the following commute: A f g X

f 0 A0

C/X has a terminal object idX : X → X. Now, if C has subobject classifier (Ω, t), then C/X has subobject classifier π2 :Ω×X → X, the canonical projection from the product, with truth map t¯ = t × idX : (id: X) → (π2 :Ω × X). To see this, a map f :(a: A) → (b: B) is monic iff f : A → B is. In C, we get χf : B → Ω; then, the composite ∆ χf ×b B B B2 Ω×X 2 is the character of f in C/X, where ∆B : B → B is the diagonal. Ω should be interpreted as an object containing all possible “truth values” for the category C—we will develop this interpretation in Section 4.

3 Topoi

We are nearly ready to give the definition of a topos. We require the extra structure of cartesian closure, meaning for any two objects A, B ∈ C, there is an object BA which acts like the set of functions A → B. The formal definition follows. Definition 3.1. The exponential of two objects A, B ∈ C is an object BA and a mor- phism ev: BA ×A → B, such that for any morphism g : C ×A → B, there is unique g¯: C → BA making the following commute: C C×A

g g¯ g¯×idA

A A B B ×A ev B

3 The prototypical example is in Set: BA = {f : A → B}, with ev(f, a) = f(a). As with Definition 2.1, this has a more categorical interpretation—a natural isomorphism Hom(C ×A, B) =∼ Hom(C,BA). We could alternatively define BA as a representation of the functor Hom(−×A, B): C → Set; ev is recovered by mapping idBA through the associated natural isomorphism (for C = BA). Furthermore, if A is such that BA exists for all B, then (−)A : C → C is a right adjoint to the product functor (−)×A: C → C.

Definition 3.2. A cartesian (ccc) is one with all finite products and exponentials. A ccc+ is a ccc with all finite limits and colimits.

Definition 3.3. An (elementary) topos (plural topoi or ) is a ccc+ with a sub- object classifier.

We can verify Set is a ccc+, hence a topos. Furthermore, we saw in Example 2.3 that whenever C has a subobject classifier, so does C/X for any object X ∈ C. Even better, whenever C is a topos, so is C/X. This fact is sometimes called the fundamental theorem of topoi, and apart from showing that C/X has exponentials, the proof is straightforward [MM92, §IV.7]. There are many more examples of topoi; a particularly important one is the functor op category SetC for any category C, whose objects are called presheaves on C. Topoi can also be characterised by the existence of objects PX which act like the “” of an object X.

Definition 3.4. A power object of an object X ∈ C consists of objects PX, K ∈ C and a monic 3: K,→ PX ×X such that for every monic r : A,→ B ×X, there is a unique morphismχ ¯r : B → PX such that the following is a pullback:

A K

r 3

χ¯ ×id B×X r X PX ×X

As always, the motivating example is in Set, where PX is the actual power set of X, and 3 the usual membership relation. We have written 3 backwards to match the definition of an exponential; we now expound the connection.

Theorem 3.5. A ccc+ C has a subobject classifier if and only if C has all power objects.

Proof. (⇐)Ω := P1 is the required subobject classifier. Taking X = 1 in Definition 3.4, and mapping through the natural isomorphism 1×B =∼ B gives Definition 2.1, since it is necessarily true that K =∼ 1 [Lei11, Fact 2.4].

(⇒) PX := ΩX is the required power object. Pulling back t: 1 → Ω along ev: ΩX × X → Ω gives 3: K,→ ΩX ×X, which is monic since t is. Now, for any monic r : A,→ B ×X, Definition 2.1 gives χr : B ×X → Ω, whence Definition 3.1 gives X the requiredχ ¯r : B → Ω .

4 4 The internal logic of a topos

For A ∈ C, the definition of the product A2 = A×A gives the diagonal ∆: A → A2 as the unique map making the following commute:

π π A 1 A2 2 A

∆ idA idA A This extends to n-fold products in the obvious way. More generally, suppose σ = (m1, . . . , mn) is an n-tuple of positive integers, with d = max{mi : i ≤ n}. The diagonal d n of signature σ is the unique map ∆σ : A → A making the following commute for each i ≤ n: π An i A

∆σ πmi Ad The regular diagonals ∆: A → An have signature (1, 1,..., 1). Henceforth, let C be a topos. We introduced topoi on the promise that they would allow a good formalisation of logic. In this section, we make good on that promise, by showing how first-order logic can be internalised in a topos. Using exponentials, topoi can also formalise higher-order logic—for simplicity, we will not explore this here. We assume familiarity with basic first-order model theory, as in [Mar02; CK90]. In particular, for L a language, L-terms and L-formulae have their usual definitions. Definition 4.1. An L-structure M in C consists of the following data: (i) An object M ∈ C called the support or domain;

(ii) For every n-ary symbol f ∈ L, a morphism f M : M n → M;

(iii) For every n-ary relation symbol R ∈ L, a morphism RM : M n → Ω;

(iv) For every constant symbol c ∈ L, a morphism cM : 1 → M. A well-known example is a group object in a category C, which is a structure in the language {∗, (·)−1, e} satisfying certain axioms. Now, we define interpretations of terms and formulae in M. Essentially, a term with n free variables will be interpreted as a morphism M n → M, while a formula with n free variables will be interpreted as a morphism M n → Ω. We assume the variables are numbered x1, x2,...; let v(t) list the free variables appearing in a term t, and v(ϕ) those appearing in a formula ϕ. Definition 4.2. Each L-term t receives an interpretation tM : M n → M in M as follows. Note that all constant symbols c ∈ L have already been given interpretations cM : 1 → M.

5 M (i) Each variable x has interpretation x = idM : M → M.

M ki (ii) For L-terms t1, . . . , tn with interpretations ti : M → M, the product term M (t1, . . . , tn) has interpretation (t1, . . . , tn) the composite t ×···×t M d ∆σ M k 1 k M n P where k = ki, and ∆σ is the diagonal of signature σ = (m1, . . . , mk), where  (xm1 , . . . , xmk ) = v(t1), . . . , v(tn) . M (iii) A function term f(t1, . . . , tn) has interpretation [f(t1, . . . , tn)] the composite

(t ,...,t )M f M M d 1 n M n M

The point of ∆σ is to ensure that variables shared between different terms are identified with each other. Before giving interpretations of L-formulae, we need to define Boolean connectives in a topos, which are maps Ωn → Ω, and quantifiers, which are maps ΩM → Ω.

Definition 4.3 Boolean connectives [Gol84, p. 139].

(i) f: 1 → Ω (called false) is the character of !: 0 → 1, and ¬:Ω → Ω is the character of f. In sum, f and ¬ are the unique maps making both squares pullbacks: ! = id 0 ! 1 1 1

! f t

1 t Ω ¬ Ω

(ii) ∧:Ω2 → Ω is the character of t2 : 1 → Ω2.

(iii) By the definition of the Ω+Ω, there is a unique map k : Ω+Ω → Ω2 making the following commute: i i Ω 1 Ω+Ω 2 Ω

k t×idΩ idΩ×t Ω2 Then, ∨:Ω2 → Ω is the character of im k.1

π1 (iv) →:Ω2 → Ω is the character of the of Ω2 Ω. ∧

(v) ↔:Ω2 → Ω is the character of the diagonal ∆: Ω → Ω2.

Definition 4.3 is the appropriate generalisation of the usual Boolean connectives in Set.

1As in abelian categories, any arrow f in a topos has a unique epi-monic factorisation f = im f ◦ coim f.

6 Definition 4.4 Quantifiers [Gol84, p. 245]. Fix an object M ∈ C.

(i) By Definition 3.1, the composite M ! 1 t Ω corresponds to a mapa ¯: 1 → ΩM , implicitly using the natural isomorphism 1×M =∼ M. Then, M ∀M :Ω → Ω is the character ofa ¯.

M M (ii) Let 3M : K,→ Ω ×M be as in Definition 3.4. Then, ∃M :Ω → Ω is the character of π1 ◦ 3M .

In Set, ∀M , ∃M : P(M) → 2 are such that ∀M (B) = 1 ⇐⇒ B = M and ∃M (B) = 1 ⇐⇒ B 6= ∅. Definition 4.4 generalises this to any topos. Now we can define interpretations ϕM of formulae ϕ: Definition 4.5. Every L-formula ϕ has an interpretation ϕM : M n → Ω as follows: (i) For L-terms s, t, the formula (s = t) has interpretation (s = t)M the composite

(s,t)M χ M d M 2 ∆ Ω 2 where χ∆ is the character of the usual diagonal ∆: M → M .

(ii) For L-terms t1, . . . , tn and a relation symbol R ∈ L, the formula R(t1, ··· , tn) has M interpretation [R(t1, . . . , tn)] the composite

(t ,...,t )M M M d 1 n M n R M

(iii) For an L-formula ϕ, the formula ¬ϕ has interpretation (¬ϕ)M the composite

ϕM M n Ω ¬ Ω

(iv) For L-formulae ϕ, ψ with interpretations ϕM : M n → Ω, ψM : M k → Ω, the formula ϕ ∧ ψ has interpretation (ϕ ∧ ψ)M the composite

ϕM×ψM M d ∆σ M n+k Ω2 ∧ Ω  where ∆σ has signature σ = (m1, . . . , mn+k) for (xm1 , . . . , xmn+k ) = v(ϕ), v(ψ) . (ϕ ∨ ψ), (ϕ → ψ), (ϕ ↔ ψ) are interpreted similarly.

(v) For an L-formula ϕ with interpretation ϕM : M n+1 → Ω, the formula ∀x ϕ is M n interpreted as follows. As in Definition 3.1, ϕ corresponds to a mapϕ ¯x : M → ΩM , where we “curry” in the position corresponding to the variable x. Then, (∀x ϕ)M is the composite ϕ¯ ∀ M n x ΩM M Ω

(vi) Similarly, ∃x ϕ has intepretation (∃x ϕ)M the composite ϕ¯ ∃ M n x ΩM M Ω

M n Definition 4.6. Let ϕ be an L-formula with interpretation ϕ : M → Ω, and a1, . . . , an : 1 → M. We say M  ϕ(a1, . . . , an) if the following diagram commutes:

7 M n M a1×···×an ϕ

1 t Ω

M In particular, for an L-sentence ϕ, M  ϕ ⇐⇒ ϕ = t. The usual internal logic of a topos is intuitionistic logic, where the law of excluded middle ϕ ∨ ¬ϕ ≡ > may fail. Definition 4.6 gives some insight into why this might be the case. Just because ϕM 6= t doesn’t necessarily mean (¬ϕ)M = t;(¬ϕ)M could be equal to some other “truth value” 1 → Ω.

Definition 4.7. The definition of the coproduct 1+1 gives a unique map k : 1+1 → Ω making the following commute: i i 1 1 1+1 2 1

k t f Ω A topos C is Boolean or classical if k is an isomorphism.

So a Boolean topos is one where the subobject classifier Ω is essentially the coproduct t+f. These are exactly the topoi in which the law of excluded middle always holds, i.e. the internal logic is classical. However, it must be emphasised that this is not the general case.

Example 4.8. The arrow category Set→ is that whose objects are functions f : A → B (in Set), and morphisms from f : A → B to g : C → D are commutative squares: A C

f g

B D Set→ forms a topos whose internal logic is three-valued. The three truth values have a natural interpretation as a time-like logic: fixing a point in time t0, the truth values are always true (t), always false (f), and false before t0, true afterwards (c). The truth tables for the Boolean connectives are as follows (the row is the first argument). ∧ t c f ∨ t c f → t c f t t c f t t t t t t c f c c c f c t c c c t t f f f f f f t c f f t t t

8 5 Categorical

Having formalised model theory within a topos, we now turn to set theory. The reader may have previously heard the vague assertion that “category theory can serve as an alternative foundation for mathematics”. Here, we give one way to make this precise. There is a key difference between material (classical) and structural (categorical) set theory. In material set theory, sets are defined by their elements; for example, the sets (A×A)×A and A×(A×A), although (naturally) isomorphic, are different since they have different elements. Structural set theory is “set theory up to isomorphism”—any two objects with an isomorphism between them should be considered “the same”. In this section, we will examine which axioms of ZFC are true in a topos. Indeed, Theorem 3.5 says exactly that any topos satisfies the power set axiom. Furthermore, [Gol84, §4.8] shows how the existence of a subobject classifier can be construed as a comprehension principle, hence any topos satisfies the axiom of comprehension.2 So what’s missing? General topoi do not have to be extensional: two distinct mor- phisms could act the same with regards to composition. Definition 5.1. An element of X ∈ C is a map x: 1 → X. Definition 5.2. A topos is well-pointed if for every f, g : A → B, whenever fx = gx for all elements x: 1 → A, then f = g. So, a well-pointed topos is one satisfying extensionality. We still don’t have the ax- iom of infinity—the category of finite sets is a well-pointed topos. To amend this, we introduce an “infinite” object which behaves like the natural numbers. z s Definition 5.3. A (NNO) is a diagram 1 N N c v such that for every diagram 1 A A there is a unique arrow h: N → A making the following commute: s N N z 1 h h c A v A

Intuitively, we should think of N as analogous to the natural numbers, z : 1 → N as analogous to the number zero, and s: N → N as analogous to the successor function. Then, Definition 5.3 says that, given c ∈ A and v : A → A, we can define a map h: N → A “by recursion”, i.e. h(0) = c, h(n + 1) = v(h(n)), and this gives a unique function h.3 What about the axiom of choice? The standard formulation is that for any collection {Ai : i ∈ I} of sets, there is a sequence (ai)i∈I with each ai ∈ Ai. But an indexed F collection {Ai : i ∈ I} is simply a surjective function f : A → I, where A = i∈I Ai, and a sequence (ai)i∈I is simply a function g : I → A. The requirement that ai ∈ Ai is equivalent to saying that fg = idI . This leads to a categorical formulation: 2The situation with regularity is complex; [Awo14] shows that any topos can be construed both as a model of foundation, and as a model of anti-foundation. [Bau20] gives a good explanation. 3 Definition 5.3 does not claim that all functions h: N → A are defined this way.

9 Definition 5.4. A topos C satisfies the axiom of choice if any epi f : A → I in C has a right inverse g : I → A, i.e. fg = idI . At this stage, we have almost all of the ZFC axioms. The first attempt to axiomatise mathematics with category theory was Lawvere’s ETCS. In modern language, ETCS says the is a well-pointed topos with an NNO, satisfying the axiom of choice. This is equiconsistent with BZC (bounded Zermelo with choice), which is ZFC without replacement, and where comprehension is restricted to formulae having bounded quantifiers. To get the full strength of ZFC, we need to add replacement. [McL04, §8] shows one way to do this. The language of categories has two sorts: objects X and morphisms f, with symbols {source, range, ◦} of the appropriate signature. Suppose R(f, X) is a predicate definable in this logic, and A ∈ C is such that for any x: 1 → A, there is unique (up to isomorphism) Sx ∈ C with R(x, Sx). Then, replacement asserts that there is g : S → A such that every Sx is obtained from x by pullback along g:

Sx S

! g

1 x A The replacement axiom R asserts that this is true for every such predicate R(f, X) and object A ∈ C. [McL04] shows that ETCS+R is equivalent to ZFC. We can also formalise additional set theory axioms (such as large cardinal axioms) in a topos. Since every set admits a bijection to a unique cardinal, from the point of view of structural set theory, a cardinal is just a set. For objects X,Y ∈ C, we say X ≤ Y if there is a monic X → Y , and say X < Y if not Y ≤ X. Then, we can give the usual definitions of uncountable sets, limit cardinals, etc. For example, here is one way to define inaccessible cardinals in a topos. Definition 5.5. (i) Objects X ∈ C induce discrete categories X¯ = {x : 1 → X}. X ∈ C is regular if for every Y < X and diagram D : Y¯ → C with colimit Z, if Dy < X for all y ∈ Y¯ , then Z < X.

(ii) X is inaccessible if it is an uncountable, regular, strong limit.

References

[Awo14] Steve Awodey et al. Relating first-order set theories, toposes and categories of classes. Annals of Pure and Applied Logic 165(2), pp. 428–502, 2014. [Bau20] Andrej Bauer. Answer to “When does a topos satisfy the axiom of regularity?” url: https://mathoverflow.net/a/375548. [CK90] C. C. Chang and H. J. Keisler. Model Theory. Elsevier, 1990.

10 [Gok97] Dmitry Gokhman. Subobject classifier and the category of actions. url: http: //zeta.math.utsa.edu/~gokhman/ftp/courses/notes/topos.pdf. [Gol84] Robert Goldblatt. Topoi: The Categorial Analysis of Logic. 2nd ed. Studies in Logic and the Foundations of Mathematics 98, Elsevier, Amsterdam, 1984. [Lei11] Tom Leinster. An informal introduction to topos theory. Publications of the nLab 1(1), 2011. [Lei14] Tom Leinster. Basic Category Theory. Cambridge Studies in Advanced Math- ematics, Cambridge University Press, Cambridge, 2014. [Mac98] . Categories for the Working Mathematician. 2nd ed. Grad- uate Texts in Mathematics 5, Springer, New York, 1998. [Mar02] David Marker. Model Theory: An Introduction. Graduate Texts in Mathemat- ics 217, Springer-Verlag, New York, 2002. [McL04] Colin McLarty. Exploring categorical structuralism. Philosophia Mathematica 12(1), pp. 37–53, 2004. [MM92] Saunders Mac Lane and Ieke Moerdijk. Sheaves in Geometry and Logic. Uni- versitext, Springer, New York, 1992. [nLa] The nLab. url: https://ncatlab.org.

11