Type Theories, Toposes and Constructive Set Theory - CiteSeerX

Report 15 Downloads 57 Views
Type Theories, Toposes and Constructive Set Theory: Predicative Aspects of AST Ieke Moerdijk (Utrecht) and Erik Palmgren (Uppsala) January 2000 Dedicated to Anne S. Troelstra on the occasion of his 60th birthday.

1 Introduction We are honoured to have the opportunity to dedicate this paper to Anne S. Troelstra. Anne supervised Moerdijk's PhD thesis, and was closely involved (as an "opponent") with Palmgren's thesis. We were both privileged to get to know Anne as a very scholarly mathematician, who generously gave his time and ideas to younger mathematicians. Many of the ideas in this paper go back to what he implicitly or explicitly taught us about intuitionistic logical systems, predicative and constructive set theories and type theories. Here, we study the relation between these theories and "Algebraic Set Theory" (AST), developed in the context of categorical logic and topos theory [10, 19, 5]. In categorical logic an important tool is the correlation between type theories and categorical structures; for example, between simply typed lambda calculus and cartesian closed categories, or between higher order intuitionistic logic and elementary toposes. The axioms for a topos can be seen as type-theoretic in nature, and have a type construction for the \power set". Much of ordinary (constructive) mathematics can be formalised inside intuitionistic type theory, or, what is the same, in a topos. The scope of formalisation is even larger for intuitionistic set theory (IZF, [7]), which allows trans nite iterations of the power set operation. For many particular toposes, it is possible to model IZF inside them. In fact, using an auxiliary notion of \small map", it is possible to extend the axioms for a topos, and provide a general theory for building models of set theory out of toposes (\algebraic set theory", [10, 19, 5]). Topos theory and IZF are essentially impredicative in nature. However, the study of constructive logical systems, such as Martin-Lof type theory, Aczel{Myhill set theory (CZF) and Feferman's systems for explicit mathematics, has shown (or indicates) that large parts of mathematics can be formalised without the use of an \impredicative" notion of power set. Instead, these systems use generalized inductive de nitions. These predicative systems are closely related to each other. For example, Aczel showed how CZF can be interpreted in Martin-Lof type theory [13]. 1

Thus the question naturally arises as to what would be a useful notion of \predicative topos". On the one hand, such a notion should serve as a categorical counterpart for constructive predicative type theories such as Martin-Lof's. On the other hand, it should allow such crucial constructions as that of the topos of sheaves and of presheaves, and of constructions of toposes by glueing and realizability. Furthermore, it is desirable that these constructions can be performed \internally", so as to provide extensions of an arbitrary \predicative topos" by sheaves, presheaves, etc., just as in the case of ordinary toposes. In addition, given such a notion of \predicative topos", the question arises whether the algebraic set theory based on small maps in a topos can be adapted to predicative toposes so as to give sheaf and other categorical models for CZF. One of the purposes of this paper is to present one possible such notion of \predicative topos", and show that for this notion, all these desiderata can in fact be proved. This is the notion of what we call a strati ed pseudotopos. (The de nitions of strati ed pseudotopos vs topos bear some formal resemblance to those of strati ed pseudomanifold vs manifold, whence our choice of terminology.) The basic ingredients of a strati ed pseudotopos are, on the one hand, the structure of a pretopos with dependent products and W-types, as discussed in our earlier [15]; and on the other hand, a ltration or strati cation of the pretopos by classes of small maps, similar to but di erent from the classes discussed in [10]. One of our main results, then, is that the sheaves on an internal site in a strati ed pseudotopos again form such a pseudotopos. Another main result is that any strati ed pseudotopos provides a model of CZF. The combination of these two results provides many di erent kinds of models of CZF. For instance, one can combine CZF with choice sequences, in order to model an extension of CZF validating Brouwer's continuity principles, or with various omniscience principles and countable choice in order to model a set theory for predicative classical mathematics (cf. Remark 12.8). Since forcing extensions can be seen as sheaf models, these results also provide a general framework for proving independence results for CZF by (forcing) methods similar to those used for ZF. Our method for obtaining CZF models from strati ed pseudotoposes is related to Aczel's original interpretation of CZF into type theory. A complication arises in our case, however, because Aczel's construction uses the fact that Martin-Lof type theory satis es a general choice principle for types | or in categorical terms, it uses the existence of \enough" projectives. As is well-known, the property of having enough projectives is in general destroyed by sheaf constructions. Because of this, we modify Aczel's model construction and employ instead a choice principle to be called the Axiom of Multiple Choice (AMC). This principle is weaker than the existence of enough projectives, and related to the categorical Collection Axiom introduced in [10]. It suces for many constructions where one would perhaps natural be inclined to use these projectives, and, crucially, it is preserved under the construction of sheaves. We brie y outline the plan of this paper. In Section 2, we recall the basic properties of the categories with which we shall work. These are pretoposes with dependent products and W-types. In Section 3, we discuss a variation on the axioms for small maps presented in [10], suitable for such pretoposes with dependent products and W-types. One of the main new axioms for such a class of small maps is the Axiom of Multiple Choice. This 2

axiom, which is introduced and discussed in Section 4, is based on the notion of a so-called \collection map", also de ned in Section 4. In Section 5, we discuss some general properties of the extensional | or \Mostowski" | collapse of W-types. This Mostowski collapse has particularly good, \universal", properties in the special case of a W-type associated to a collection map, as we will explain in Section 6. Using these general properties, it is now quite straightforward to prove that the Mostowski collapse of a universal small map is a model for Aczel's constructive set theory CZF; this is done in Section 7. The next three sections are concerned with the stability under internal sheaf constructions of the categorical properties introduced in Section 3 and 4. In Section 8, AMC is identi ed as a sucient condition for the existence of the (internal) associated sheaf functor. In Section 9 and 10 the class of \point-wise small" natural transformations between sheaves is shown to satisfy the axioms for small maps and AMC. Up to this point in the paper, we have only assumed that the underlying category is a pretopos with dependent products and W-types, and equipped with a single class of small maps. In the next section, however, we will introduce the notion of a strati ed pseudotopos, which is, roughly speaking, such a pretopos with dependent products and W-types, which is moreover ltered by an entire sequence of classes of small maps. In the last section, we explain how theories in a standard version of type theory with universes naturally give rise to strati ed pseudotoposes.

Acknowledgements: This paper is part of a series (together with [15] and [16]), the

research for which was done during mutual visits, supported by the Netherlands Science Organisation (NWO) and the Swedish Research Council for Natural Sciences (NFR), and during a stay at the Mathematisches Forschungsinstitut Oberwolfach, January 18 { 24, 1998. We are grateful to these three institutions for support. We would also like to thank Peter Aczel, for posing the question whether there is a constructive model of CZF extended with omniscience principles (see Remark 12.8), and Michael Rathjen for helpful discussions on CZF.

2 Preliminaries The basic categorical context in which we shall work is that of a pretopos with dependent products and W-types. We brie y recall the relevant de nitions here. A pretopos is a category with nite limits, nite sums which are stable and disjoint, - X there exists a stable quotient X=R, i.e. and where for each equivalence relation R an object which ts into a diagram

- X - X=R R -

which is exact and remains so after pulling back along any map into X=R. The \internal logic" of a pretopos is an intuitionistic rst order logic (coherent logic with sums and quotients). We will often exploit this fact, and work inside a pretopos E as if it is a universe of sets with this logic. 3

A pretopos E is said to have dependent products if, for any map : Y ?! X , the pullback functor  : E =X ?! E =Y has a right adjoint. This condition is equivalent to E being locally cartesian closed. In a pretopos E with dependent products, any map f : B ?! A gives rise to a \polynomial functor" Pf : E ?! E , de ned by

Pf (X ) =

X XB a2A

a

(1)

where Ba = f ? (a). The W-type of signature f is the initial algebra for this endofunctor, and is denoted W (f ) (if it exists). One can think of W (f ) as the free algebra with a Ba -ary operation for each a 2 A. For a 2 A and a morphism t : Ba ?! W (f ), the value under this operation is denoted supa(t): A pretopos with dependent products E is said to have W-types if for any map f this initial algebra W (f ) exists. This implies that the same is true for any slice pretopos E =X . Note that if such a pretopos E has W-types, it has in particular a natural number object N , the W-type of the coproduct inclusion 1 ,! 1 + 1. We refer to [15] for an extensive discussion of W-types in pretoposes. 1

3 Small Maps

Consider a pretopos E with dependent products and W-types, and a class S  E of arrows in E . We will discuss a variation of the axioms in [10] which intuitively express that maps in S should be thought of as maps all of whose bers are \small" in some sense. The axioms for S naturally fall apart in three groups. The rst axioms S1-3 should naturally be required of any class of maps determined by the properties of the bers, and state that S is a stack (cf. Remark 3.2 below). On any such class one can impose fullness and representability conditions. These conditions (together with S1-3) apply in a much more general context, e.g. E could be a regular category with (stable) sums. If E has more structure, stable under slicing (i.e. each E =X has the same structure and change-of-base preserves the structure), it is natural to require that the category S =X  E =X , of \small" maps into X , is closed under this structure. In the case of a pretopos E as above, this is expressed in Axioms F1{5 below. De nition 3.1 A class of maps S  E is said to be stable if it satis es the following three axioms S1{3: (S1) (Pullback stability) In a pullback square Y0 - Y f f0 ?0 - ? (2) X p X 4

f 0 belongs to S whenever f does. (S2) (Descent) If in a pullback square (2), the map p is epi, then f belongs to S whenever f 0 does. (S3) (Sum) If two maps Y ?! X and Y 0 ?! X 0 both belong to S then so does their sum Y + Y 0 ?! X + X 0 . Any map  : E ?! U in E determines a stable class S (), consisting of those maps f : Y ?! X which t into a double pullback diagram -E (3) Y  Y0 f  f0 ? p ? - U? X  X 0 where p is epi as indicated. In the internal logic of E , one can think of S () as the class of those maps f : Y ?! X for which every ber is isomorphic to some ber of : f 2 S () i 8x 2 X 9u 2 U 9 iso f ? (x)  = ? (u): A class S of the form S = S () is said to be representable, and we often refer to  as the universal small map in this context. Note, however, that given a representable class S , there can be many di erent maps  for which S = S (). For example, for any pullback diagram E0 - E  0 ?0 -- ? U U with an epi on the bottom, one has S () = S (0 ). Remark 3.2 (For readers familiar with stacks; see e.g. [4].) For any object X of E , let SX be the full subcategory of E =X whose objects belong to S . Then the axioms S1-3 express that S ? is a stack on E . Any map  : E ?! U determines a full internal subcategory Full() in E (see [9]), and hence a (representable) sheaf of categories Full(). The stack completion of this sheaf is precisely the stack S () just described. A stable class S  E is said to be a locally full subcategory if (S4) For any two composable arrows f and g with f 2 S , the map g belongs to S i the composite fg does. In this paper, we will only consider classes S which are locally full subcategories. In the particular context we are interested in, our ambient category E is a pretopos with dependent products and W-types, as is each of its slices E =X . We require the same for each of the subcategories SX  E =X : 1

(

)

5

1

De nition 3.3 A collection of maps S  E is said to be a (representable) class of small maps if S is a stable, (representable) locally full subcategory, and if for every object X 2 E , the category SX is a pretopos with dependent products and W-types, and the inclusion SX ,! E =X preserves this structure. In this context, we refer to an object X of E for which X ?! 1 belongs to S as a small object. More generally, we refer to a small map Y ?! X (i.e. a map in S ) as a small object over X .

Remark 3.4 The last condition in the previous de nition is equivalent to the following ve properties: (F1) 1X 2 S for every object X of E . (F2) 0 ?! X is in S , and if Y ?! X and Z ?! X are in S then so is Y + Z ?! X . (F3) For an exact diagram in E =X ,

R

@ @

-- Y

@@

@@R ?? ?

- Y=R ? ? ??

(4)

X if R ?! X and Y ?! X belong to S then so does Y=R ?! X . (F4) For any Y ?! X and Z ?! X in S , their exponent (Z Y )X ?! X in E =X belongs to S. (F5) For a commutative diagram f B A

@@R

??

X with all maps in S , the W-type WX (f ) taken in E =X (which is a map in E with codomain X ) belongs to S . Indeed, (F1) states that the terminal object of E =X belongs to SX . Since S is closed under pullback and composition (S1,4), it follows that SX  E =X is closed under all nite limits. (F2) states that SX  E =X is closed under nite sums, and (F3) similarly concerns quotients of equivalence relations, (F4) exponentials and (F5) W-types.

Remark 3.5 (Slicing) The structure of a pretopos E with dependent products and Wtypes, equipped with a (representable) class of small maps S , is stable under slicing: for any object X of E , the slice E =X is again such a pretopos equipped with a class of small maps S =X . 6

Remark 3.6 (S -separated objects) Let S be a class of small maps. Call a map Y ?! X (S -)separated, or an (S -)separated object over X , if its diagonal Y ?! Y X Y belongs to S . If Y ?! X is small then it is also separated. If, in a diagram

-Y g@@ R ? ?f X f is separated and g is small, then Im( ) is a small object over X . (These remarks are immediate consequences of the axioms for a class of small maps.) Remark 3.7 (S -separation) Recall from [10] that, for a representable class of small maps, each object X of E has a corresponding power object Ps(X ), representing small subobjects of X . Thus, arrows I ?! Ps(X ) correspond to subobjects A  I  X for which A ?! I belongs to S . These power objects are closed under the propositional connectives. Moreover, if f : Y ?! X is small then there is a pullback operation f : Ps(X ) ?! Ps(Y ): If X and Y are separated objects, this operation has both adjoints 8f and 9f . Let us call a rst order formula ' of the language of E an S -bounded formula if it contains quanti ers over \small sets" (i.e. along small maps) only. Then each power object Ps(X ) of a separated object X satis es \S -separation", in the sense that if A  X is small and '(x) is S -bounded then fx 2 A : '(x)g  X is small (i.e. belongs to Ps(X )). B

#

4 The Axiom of Multiple Choice The axioms we are about to discuss will be expressed using quasi-pullbacks. Recall that a commutative square C -B g f

?

?

(5) A -X is called a quasi-pullback whenever the canonical map C ?! A X B is an epi. Thus if g is epi, then so is f . Note also that juxtaposing two quasi-pullbacks with a common edge yields a quasi-pullback. We recall from [10] that a class of small maps S is said to satisfy the collection axiom (CA) if (CA) For any map f : A ?! X in S and any epi C ?! A there exists a quasi-pullback of the form B - C -- A

?

-- X;?

Y

7

(6)

where Y ?! X is epi as indicated and B ?! Y belongs again to S . In the internal logic of the ambient pretopos E , this axiom can be stated as a schema (CA) 8 small A[8a 2 A 9c 2 C '(a; c) ) 9 small B (9f : B ?! C )8a 2 A 9b 2 B '(a; fb)]: Here ' is a formula of the internal language of E , and the quanti ers \8 small A", \9 small B " range over small objects in (slices of) E . These make sense in the usual interpretation | in fact, one can replace these quanti ers by quanti cation over the \universal small object" U . We will often use the internal language of E in a more informal way, and apply the collection axiom in the following form: (CA) (informal) For any small set A and any surjection C ?! A there exists a surjection B ?! A from a small set which factors through C . This collection axiom was partly inspired by the axiom with the same name of (intuitionistic) Zermelo-Fraenkel set theory. (In fact, one of the goals in [10] was to construct models of IZF from classes of small maps.) For our present purposes, related to Aczel's constructive set theory CZF, we need a strengthening of this categorical collection axiom, which we call the axiom of multiple choice, and which we will now explain. First, we introduce the notion of a collection map. Informally, a map g : D ?! C in E is a collection map if (it holds in the internal logic of E that) for any surjection E  Dc on some ber Dc = g? (c) of g, there is another ber Dc for which there is a surjection Dc ?! Dc which factors through E ?! Dc by some map Dc ?! E . Diagrammatically, we can express this by asking that for any map c : T ?! C and any epi E ?! T C D there is a diagram of the form D  D C T 0 - E -- T C D - D p.b. q.p.b. p.b. ? ?0 ? -- T - C? (7) C T 1

0

0

0

where the middle square is a quasi-pullback, involving the given map E  T C D and with an epi on the bottom, while the other two squares are pullbacks. More generally, if D ?! C is a map over an object A of E , we say that D ?! C is a collection map over A if it is a collection map in the pretopos E =A.

Example 4.1 The collection axiom (CA) stated above is equivalent to the axiom that the universal small map E ?! U is a collection map. This is easily seen, using the fact that in a pretopos, pasting a pullback to a quasi-pullback yields a quasi-pullback. Remark 4.2 We observe some basic properties of collection maps: (i) If D ?! C is a collection map over A then for any A0 ?! A, the pullback D A A0 ?! C A A0 is a collection map over A0 . 8

(ii) If D ?! C is a collection map over A then for any map A ?! B the map D ?! C is also a collection map over B . (iii) In a pullback square over A of the form

D0

-D

? - ? C D0 ?! C 0 is a collection map over A i D ?! C is, provided the map C 0 ?! C is epi. P P (iv) For aPfamily of maps Di ?! Ci over Ai, the sum Di ?! Ci is a collection map over Ai i each Di ?! Ci is a collection map over Ai. C0

We now introduce a strengthening of the Collection Axiom called the Axiom of Multiple Choice. In the internal language of E , where we think of objects of E as \sets", this axiom can informally be expressed as follows (AMC) (\internal") For any small set B there exists a collection map D ?! C where D and C are small, and C is inhabited, together with a map D ?! B making D ?! B  C into a surjection. Diagrammatically, the small set B (in any slice of E !) is the ber of a small map B ?! A, and the interpretation of \there exists" takes place on a cover A0  A, so that (AMC) takes the following form: (AMC) (\diagrammatic") For any map B ?! A in S , there exists an epi A0  A and a quasi-pullback of the form -B D

? -- 0 A

C

-- A?

(8)

where D ?! C is a small collection map over A0 and C ?! A0 is a small epi. We will use both versions of (AMC) in the sequel.

Proposition 4.3 AMC implies the Collection Axiom. Proof. By way of example we will give both an informal and a diagrammatic proof.

To show that the informal version of (CA) follows from the informal version of (AMC), take any small \set" A and any epi E  A. By (AMC) there exists a surjection (f; g) : D ?! A  C where g : D ?! C is a collection map, and C is inhabited. For any x 2 C , we get f : g? (x)  A. Applying the fact that g is a collection map to the cover E A g? (x)  1

1

9

g? (x), we nd another y 2 C and a surjection t : g? (y) ?! g? (x) so that f  t factors through E ?! A. Thus B = g? (y) shows that (CA) holds. A possible diagrammatic proof would go as follows. First, for a given small map A ?! X , (AMC) gives a quasi-pullback of the form -A D 1

1

1

1

? -- 0 -- ? X X

(9)

C

where D ?! C is small collection map over X 0. Applying the description of a collection map (7) to the cover E A D  D, we nd a diagram of the shape

D  D C T 0 - E A D p.b. q.p.b. ? ?0 C T

-- D

-A

q.p.b.

-- C? -- X 0 -- X?

(10)

Since D ?! C is small, so is D C T 0 ?! T 0. Hence the composition of the two right hand quasi-pullbacks yields a quasi-pullback witnessing (CA).

Remark 4.4 , about the di erence between (AMC) and (CA): For a small set A and an epi E  A, (CA) gives an epi B  A from a small B which factors through E . This B depends in general on the cover E . (AMC) bounds the choice of the B 's needed to a small family, which does not depend on E , namely the bers of the collection map D ?! C . The (AMC) is related to the axiom of choice in the following way. In many examples (e.g. realizability categories, or categories de ned from Martin-Lof type theories), the class S of small maps in E is de ned from a class of choice maps A in E (see [10, p. 97]). More precisely, each map in A is internally projective, and for any map f : B ?! A in S there exists a quasi-pullback of the form D -B g f ? -? C A with g 2 A. In this situation, (AMC) is always satis ed, by the proposition below. We remark, however, that (AMC) is much more exible then any condition having to do with the existence of (internal) projectives. Indeed, (AMC) is always stable under the sheafconstruction (see Section 9), while the existence of projectives rarely is.

Proposition 4.5 A map D ?! C is a collection map over C if, and only if, it is a choice map.

10

Proof. Working informally inside E , this is quite clear: By de nition the map D ?! C

is a choice map precisely when its bers are projective. Then the proposition asserts the obvious fact that, internally, a \set" P is projective i P ?! 1 is a collection map. By way of illustration, we also give a diagrammatic proof of the implication ((). Suppose D ?! C is a choice map. Recall from [10, p. 96] that this means that D is internally projective in E =C , so that given any T ?! C and any epi E  T C D, there will exist an epi T 0  T and a map T 0 C D ?! E which ts into a commutative square of the form -E T 0 C D

? 1- ? T C D T C D

From this square we obtain a diagram D  T 0 C D - E -- T C D - D p.b. p.b. p.b. ? ?0 ? ? C C T T

(11)

which is more than required for (AMC). We wish to apply the (AMC) to a small map B ?! A where the object A is also small. Informally in E , this means that we are given a small family fBa : a 2 Ag of small sets. The informal version of (AMC) applied to each member of this family gives for each a 2 A a collection map Dx ?! Cx with a surjection Dx ?! Cx  Ba , etc. Lacking the axiom of choice, we cannot choose one x for each a. But, applying collection (CA) to the quanti er combination 8a 2 A 9x (  ), we nd that a small family of such collection maps suce. This gives a quasi-pullback -B D

?

?

C -- X -- A where D ?! C is a collection map over X while C ?! X and X ?! A are both small surjections. Using Remark 4.2.(ii), we obtain an informal proof of the following assertion:

Proposition 4.6 (Preliminary formulation) Suppose (AMC) holds. Then, internally in E , it holds that for any small map B ?! A into a small object A there exists a quasi-pullback D -B

? -- ? A where all objects and maps are small and D ?! C is a collection map over A. C

11

Taking the existential quanti er in this proposition outside E , we can rephrase it as follows. Proposition 4.6 (AMC) Let B ?! A be a small map into a small object A. Then there exists a T  1 and a quasi-pullback of the form D -BT

? ? C -- A  T where D ?! C is a small collection map over A  T , and C ?! T is small. Proof. Although this proposition has already been proved informally, we also give a diagrammatic proof. (AMC) gives a diagram D - A0 A B - B 0

?q.p.b. ? ? C -- A0 -- A

(12) where D ?! C is a small collection map over A0 and C ?! A0 is small. The collection axiom gives a quasi-pullback of the form - A0 -- A V 0

0

0

0

?

?

-- 1 (13) T where V ?! T is small. Pulling back the collection map D ?! C over A0 along V ?! A0 yields a map D ?! C which ts into a pullback square -D D = D A V 0

0

0

?

0

0

?

C = C A V -- C (14) with a small collection map over V on the left. Juxtaposing (14) with the outer quasipullback of (12) on the right gives the upper quasi-pullback in D -B 0

0

0

? -- ? A

C

? -- ? 1

T

12

(15)

The bottom is a quasi-pullback because C ?! V is epi and V ts into the quasi-pullback (13). It follows, using the pasting lemma for quasi-pullbacks, that D -BT

?

?

(16) C -- A  T is a quasi-pullback with an epi on the bottom, and on the left a small collection map over V , hence a fortiori over A  T . Finally, it is easy to check that C ?! T is small.

5 Mostowski Collapse of W-types

We continue to work in a pretopos E , with dependent products and W-types, which is equipped with a class of small maps S . Consider the W-type W (f ) associated to a small map f : B ?! A in E . By the universal property of W (f ), one can de ne a map E : W (f )  W (f ) ?! Ps(1) by \double induction". The E here stands for \extensional equality". If x = supa(t) and y = supa (t0 ), then E (x; y) i 8b 2 f ? (a) 9b0 2 f ? (a0 ) E (t(b); t0(b0 )) and 8b0 2 f ? (a0) 9b 2 f ? (a) E (t(b); t0(b0 )): 0

1

1

1

1

Note that the value E (x; y) indeed lies in Ps(1), because the inductive de nition only involves quanti ers ranging over the bers of f : B ?! A, and these are assumed to be small. We also de ne two other relations W (f )  W (f ) ?! Ps (1) by induction, M for membership and I for inclusion, by M (y; x) i 9b 2 f ? (a) E (y; t(b)); I (y; x) i 8b0 2 f ? (a0) 9b 2 f ? (a) E (t(b); t0 (b0 )): Notice that these de nitions are intertwined, as follows I (x; y) i 8u 2 W (f ) (M (u; x) ?! M (u; y)) (17) E (x; y) i I (x; y) and I (y; x): (18) We will also write M; I; E  W (f )  W (f ) for the corresponding subobjects. We observe that the map E  W (f )  W (f ) is small by construction, and is easily seen to be an equivalence relation, by induction on elements of W (f ). Thus we can form the quotient, which we denote by -- W (f ) f - V (f ) E (19) 1

1

1

13

and call the Mostowski (or extensional) collapse of W (f ). Note that I and M pass down to well-de ned relations on V (f ), denoted by  and ". Thus, in the internal logic of E ,

8x; y 2 W (f ) : (I (x; y) , f (x)  f (y)) & (M (x; y) , f (x) " f (y)):

(20)

Lemma 5.1 (i) The diagonal  : V (f ) ?! V (f )  V (f ) is small, i.e. V (f ) is S separated.

(ii) The composition "-

- V (f )  V (f ) - V (f ) is small. 2

(iii) If f : B ?! A and A are both small then so is V (f ).

Proof. (i): By construction of V (f ) there is a pullback

-- V (f )

E?



? ? W (f )  W (f ) -- V (f )  V (f ) Since E ?! W (f )  W (f ) is small, so is  by axiom (S2). (ii): We argue in the internal logic of E . Take any v 2 V (f ), and write v = f (x), where x = supa (t) is some element of W (f ). We need to show that fw 2 V (f ) : w " vg is small. But this set is the image of the map

 f ? (a)- t - W (f ) f - V (f ) 1

and this image is small by part (i) and Remark 3.6. (iii): By Remark 3.4, (F5) applied with X = 1 gives that W (f ) is small. But then so is V (f ), by (F3) and the fact that E  W (f )  W (f ) is small. By part (ii) of this lemma, any v 2 V (f ) de nes a small subobject (\subset") Ext(v) = fw 2 V (f ) : w " vg of V (f ), the \externalization" of v (from elements of V (f ) to objects of E ).

Lemma 5.2 (\extensionality") The map Ext : V (f ) ?! Ps(V (f )) is injective.

14

Proof. This is just another way of phrasing (17) { (18) above.

We next consider the functoriality of the construction of V (f ) out of a small map f . To this end, we rst introduce some terminology. A map  : V (f ) ?! V (g) is called a transitive embedding if w " (v) , (9u " v) w = (u): It follows easily by induction that each transitive embedding is mono. Recall from [15] that W (f ) is contravariant, in the sense that any commutative triangle -B (21) C g@@ R ? ?f A induces a map  : W (f ) ?! W (g). This map is mono whenever is epi. Moreover, W (f ) is covariant in the sense that any pullback square D ~ - B

g

f

? ? C - A

(22)

induces a map : W (g) ?! W (f ). This map is epi whenever is. !

Proposition 5.3 (i) If in (21) is epi, then  : W (f ) ?! W (g) induces a transitive embedding (again denoted)

such that g   =   f .

 : V (f )  V (g)

(ii) For any pullback square (22), the map : W (g) ?! W (f ) induces a transitive embedding : V (g)  V (f ) such that f  =  g . If is epi, then : V (g) ?! V (f ) is an isomorphism. !

!

!

!

!

(iii) The map : V (g) ?! V (f ) does not depend on the maps and ~ making up the pullback square (22). !

Proof. (i): Recall that  : W (f ) ?! W (g) is de ned \inductively" by (supat) = supa(   t  a ); (23) where a 2 A, t : Ba ?! W (f ) and a : Ca ?! Ba is the restriction of . If is epi then so is a for each a, and one shows easily by induction on x; y 2 W (f ) that x  y () (x)  (y) 15

where  is the equivalence relation E on W (f ) (respectively on W (g)). Then by using (23) and that a is epi, again, one shows

M (w; (supat)) , 9u (M (u; supa t) ^ w  (u)): Thus  factors by a transitive embedding which makes the square  W (g)- - W (f ) g ?  ?f V (g)- - V (f ) commute. (ii): Recall that : W (g) ?! W (f ) is de ned, again inductively, by !

(supc(t)) = sup c (  t  ~c? );

(24)

1

!

!

( )

 where c 2 C , t : Dc ?! W (g) and ~c : Dc ?! B c is the restriction of ~. Again, it is easy to show by induction that for any x; y 2 W (f ), ( )

x  y () (x)  (y): Using (24), and that each ~c? is iso, one shows that factors by a transitive embedding : V (g)  V (f ), analogous to the case of  in part (i). If is epi then sois : W (g) ?! W (f ), and hence : V (g) ?! V (f ) must be epi as well. Then : V (g) ?! V (f ) is an isomorphism. (iii): Suppose both squares in ~ -B D ~ g f ? - ? -A C are pullbacks. Then for any c 2 C , we have an isomorphism 

c = ~c  ~c? : B c ?! B c : Now, if t : g? (c) ?! W (g) is any map such that f   t = f   t : g? (c) ?! W (g)  W (f ) ?! V (f ); i.e. 8d 2 g? (c) E ( t(d); t(d)), then, using the inductive de nition of E and the isomorphism c, one sees that E ( (supct); (supct)), i.e. f (supc(t)) = f (supc(t)): !

!

1

!

!

!

!

!

1

( )

1

1

!

1

!

!

!

!

!

!

!

16

( )

By induction, it follows that

f  = f  : W (g) ?! V (f ); !

!

and hence = as maps V (g) ?! V (f ). Now consider the \universal small map"  : E ?! U , and write V = V (). (In fact, we will see that V only depends on S and not on the representing map .) !

!

Corollary 5.4 (i) For any small map f there is a canonical transitive embedding if : V (f )  V (by which we can identify V (f ) with a subobject of V ).

(ii) The maps  : V (f )  V (g) and : V (g)  V (f ), in the preceeding proposition respect this embedding, i.e. !

ig   = if ;

if  = ig : !

Proof. We give an explicit description of if , proving (i), and then leave the veri cation

of (ii) to the reader. For the given small map f , there exists a double pullback Y  Y 0 c~ - E

(25)



f

? p ? ? X  X 0 c - U and hence by Proposition 5.3 (ii) a transitive embedding if = c  (p )? : V (f ) ?! V: 1

!

!

We claim that this embedding does not depend on the choice of the double pullback (25). Indeed, it does not depend on c and p by 5.3 (iii). And if there is another double pullback with Y 00 ?! X 00 in the middle, one can construct a \common re nement" Y 0 Y Y 00 ?! X 0 X X 00 , and use 5.3 (iii) again to show that if does not depend on Y 0 ?! X 0 either.

Corollary 5.5 (i) When the maps f and g t into a quasi-pullback of the form  --  g

f

? ?  -- 

then V (f )  V (g).

17

(ii) In particular, if (AMC) holds then, internally in E , it holds that for any (small) map f between small objects there is a collection map g between small objects such that V (f )  V (g).

Proof. (i) Decomposing the quasi-pullback as a pullback and a triangle  --  -- 

@g f @@R f 0 ? -- ?  

we obtain a mono V (f )  = V (f 0)  V (g) by Proposition 5.3 (i), (ii). By Corollary 5.4, V (f )  V (g) as subobjects of V . Part (ii) follows by using Proposition 4.6.

6 Mostowski Collapse for Collection Maps We will brie y discuss some properties of objects of the form V (f ) for the special case where f is a (small) collection map. To begin with, observe that any small map f : B ?! A de nes a functor Pf : E ?! E by Pf (X ) = fS  X j 9a 2 A 9t : Ba ?! X : S = Im(t)g: In other words, Pf (X ) is the family of those subsets of X which can be enumerated by some ber of f . This object can be constructed in any pretopos with dependent products, as a quotient of a2A X B . If X is separated, then by 3.7 Pf (X ) is a subobject of Ps(X ), the object of small subsets of X . In particular, for the universal small map  : E ?! U we have P (X ) = Ps(X ) whenever X is separated. This construction is clearly a covariant functor of X . We denote the e ect of a map ' : X ?! Y in E by ' : Pf (X ) ?! Pf (Y ): It is useful to observe the following property of collection maps, an immediate consequence of the de nition. a

!

Lemma 6.1 For any collection map f : B ?! A, the map ' : Pf (X ) ?! Pf (Y ) is epi whenever ' : X ?! Y is. The functor Pf is closely related to the polynomial functor Pf of (1). Indeed, by taking images of functions Ba ?! X , one obtains an epimorphism Im : Pf (X ) ?! Pf (X ); (26) !

natural in X . 18

As to any endofunctor, there is a category of Pf -algebras associated to Pf . Its objects are pairs (X; : Pf (X ) ?! X ), and its arrows ' : (X; ) ?! (Y; ) are maps ' : X ?! Y in E such that  ' = '  . Before discussing the next two propositions, we observe that the map Ext of Lemma 5.2 factors through Pf , i.e. de nes a map !

Ext : V (f ) ?! Pf (V (f )):

(27)

Proposition 6.2 If f is a small collection map, then V (f ) has the structure of a Pf algebra, denoted Int : Pf (V (f )) ?! V (f ). This structure map ts into a commutative square

Pf (W (f )) -- Pf (V (f )) sup Int ? f -- ? W (f ) V (f ) (28) where the map on top is the composite (f )  Im : Pf (W (f )) ?! Pf (W (f )) ?! Pf (V (f )). !

Proof. Let S 2 Pf (V (f )), and choose  : Ba ?! V (f ) such that S is the image of . Consider the pullback - W (f ) X f ?  ? - V (f ) Ba Since f : B ?! A is a collection map, there exists an a0 2 A and a surjection p : Ba ?! Ba which factors through X . Thus p factors through W (f ), and we nd a map  : Ba ?! W (f ) such that f   =   p: Let x = supa ( ) 2 W (f ), and y = f (x) 2 V (f ). We claim that y only depends on S , and not on a; , etc. Indeed, the small subset Ext(y)  V (f ) is the image of f   =   p, hence since p is epi, Ext(y) = Im() = S . So by the extensionality lemma 5.2, y only depends on S , and we can de ne Int(S ) to be this y. In this way, we obtain a map Int : Pf (V (f )) ?! V (f ), which by construction makes the diagram commute. We remark that in this proof, we construct Int(S ) as the y for which Ext(y) = S . So Ext  Int = Id. Since Ext is mono (5.2), also Int  Ext = Id. Thus Int and Ext are mutually inverse, as stated in the following proposition. 0

0

0

Proposition 6.3 Let f be a small collection map. Then (V (f ); Int) is the initial Pf algebra. In particular, Int is an isomorphism, inverse to Ext. 19

Proof. Let X be any Pf -algebra, say with structure map  : Pf (X ) ?! X . By precomposing with Im : Pf (X ) ?! Pf (X ), we can de ne a Pf -algebra structure on X . Since W (f ) is the free Pf -algebra, there is a unique map  making the diagram

Pf (W (f )) Pf (-) Pf (X ) Im ? sup Pf (X )  ? ?  -X W (f )

(29)

commute. In other words,

(supa (t)) = (f(tb) : b 2 f ? (a)g): 1

From this last expression, one readily shows by induction on elements of W (f ) that  respects the equivalence relation E , hence factors as a map  : V (f ) ?! X with

  f = :

(30)

Then  is a homomorphism of Pf -algebras. Indeed,

  Int  (f )  Im = = = = = !

  f  sup ( cf. (28))   sup   Im  Pf () (cf. (29))     Im (naturality of Im)     (f )  Im: (by (30)) !

!

!

Since (f )  Im in (28) is epi, cf. Lemma 6.1, we conclude that   Int =    , as required. The uniqueness of  follows readily from that of , and we omit the details. !

!

Corollary 6.4 For any small collection map f , one has (in the internal logic of E ): v " Int(S ) i v 2 S for any v 2 V and S 2 Pf (V (f )). Proof. For any two v; w 2 V (f ), we have v 2 Ext(w) i v " w by de nition of Ext. Applying this to w = Int(S ) gives the stated equivalence. 20

Corollary 6.5 For any collection map f , the object V (f ) only depends (up to isomorphism) on the representable class S (f ) of maps. In particular, for the universal small map , the object V = V () only depends on the class S of small maps. Proof. Clearly Pf depends only on S (f ), so this follows from Proposition 6.3. Remark 6.6 For a transitive embedding  : V (f ) ?! V (g) the square V (f ) Ext- Ps (V (f ))  Im() ? Ext- ? V (g) Ps(V (g)): commutes (as is immediate from the de nition). If f and g are collection maps, then we observed that Ext factors through Pf (V (f )) and is inverse to the algebra structure Int : Pf (V (f )) ?! V (f ), and similarly for V (g). It follows that the transitive embeddings given by Proposition 5.3 are compatible with the algebra structure of Proposition 6.3.

Remark 6.7 We can immediately relate Proposition 6.3 to the theory of ZF-algebras developed in [10]. Indeed, the functor P is part of a monad (P ; [; fg), with union and singleton as multiplication and unit. By Theorem A5, p. 106 in [10], it follows from Proposition 6.3 that V = V () is the free successor algebra for this monad, with as algebra structure P (V ) ?! V the union map S 7! Intfw : 9v 2 S w " vg, and as successor map V ?! V the singleton map v 7! Int(fvg). (Thus V is the free ZF-algebra, if we de ne ZF-algebras here using P rather than Ps. Note that, unlike the treatment in [10], we do not assume here that the quotient of a small object is again small. So Ps is not a covariant functor and we have to use P instead.)

7 Categorical models of CZF In this section we consider Aczel's constructive set theory, CZF. The main references for models of CZF are Aczel [1, 2] and the exposition in Troelstra and van Dalen [22]. Our main result will be that if E is a pretopos with dependent products and W-types, and S is a class of small maps satisfying (AMC), then V = V () is a model of CZF. (In fact, it is also a model of the regular extension axiom [2], cf. Theorem 7.1 below.) This result is analogous to the result for IZF in [10]. In relation to Section 9, it is relevant to observe here that we do not need all W-types to exist in E for this result to hold, but only the W-types W (f ) for small maps f . We begin by listing Aczel's axioms. The formulae ' in 1 { 10 below are arbitrary unless otherwise stated. 1. Extensionality: v = w $ 8x (x  v $ x  w) 21

Pairing: 8v; w 9x 8y (y  x $ (y = v _ y = w)) Union: 8v 9x 8y (y  x $ 9w (y  w  x)) Set induction: 8x (8y  x '(y) ?! '(x)) ?! 8x '(x)  -separation: 9v 8x (x  v $ '(x) ^ x  w) for bounded formulas ', not containing v as a free variable 6. In nity: 9z 8x [x  z $ x = ; _ (9y  z) x = y [ fyg]. (In view of the extensionality axiom the equalities and the constant ; can be eliminated from the In nity axiom.) 7. Exponentials: 8x; y 9a 8v (v  a $ v is a function from x to y) 8. Strong collection: 8xv 9y '(x; y) ?! 9w [(8xv 9yw '(x; y)) ^ (8yw 9xv '(x; y))]

2. 3. 4. 5.

0

h

9. Subset collection: 8a; b 9c 8u 8xa 9yb '(x; y; u) ?! 9dc [(8xa 9yd '(x; y; u)) ^ i (8x  d 9y  a '(x; y; u))] . 10. Regular extension axiom (REA): 8x 9r (x  r ^ r regular) The last axiom uses the notion of a regular set. A relation R  b  A is called a multi-valued function if 8x  b 9y  A hx; yi  R. We recall from [2] that a nonvoid set A is regular if it is transitive and if for every b  A and every multi-valued function R  b  A, there is a bounding set d 2 A so that 8x  b 9y  d hx; yi  R and 8y  d 9x  b hx; yi  R: Aczel's original theory CZF is axiomatized by 1-6,8,9. In [1, Prop. 2.1, 2.2] and [3, Prop. 4.5] it is shown that in the presence of the axioms 1-6: REA and Strong Collection ) Subset Collection ) exponentials. So CZF+REA can be axiomatized by 1-6,8,10. We denote by CZF? the theory axiomatized by 1-8, which is similar to Myhill's original set theory. By CZF we denote the theory given by 1-6,8,10. Thus CZF?  CZF  CZF . Theorem 7.1 Let E be a pretopos with dependent products and W-types W (f ), for all (small) maps f , and let S be the class of small maps in E . (i) If S satis es (CA) then V = V () is a model of CZF?. (ii) If S satis es (AMC) then V is a model of CZF . Proof. Write V = V (), and recall the mutually inverse isomorphisms Int : Ps(V ) ?! V; Ext : V ?! Ps(V ): (Note that Ps(V ) = P (V ) since V is separated, cf. Lemma 5.1.(i).) For a small subset A  V and an element v 2 V we have +

+

+

22

x 2 A i x  Int(A) and x 2 Ext(v) i x  v. (So we could also write Ext(v) = fw 2 V : w  vg, Int(A) = fa 2 V : a 2 Ag; however, these are di erent kinds of braces: the rst ones are braces of E coming with any Ps(X ); the second ones are internal to the structure (V;  ). To avoid confusion, we will only use f g in the rst sense.) We now check the axioms 1-8. 1. (Extensionality) Since = on Ps(V ) is extensional in 2, the = on V is extensional for  (as already observed in Lemma 5.2). 2. (Pairing) Take v; w 2 V . Since 1 + 1 is small we have fv; wg 2 Ps(V ) (this uses Remark 3.6 and the fact that V is separated). Then x = Int(fv; wg) is the required pair. 3. (Union) Take v 2 V , with A = Ext(v), and let B = fhu; wi : u  w 2 Ag. Then by Lemma 5.1.(ii),  : B ?! A is small (the ber is Ext(w)). So B is small since A is. Thus the union [v can be constructed as Int(Im( : B ?! V )). 4. (Set induction) This is just the initiality of V (Proposition 6.3) in disguise. Indeed, if ' satis es 8x (8y  x '(y) ?! '(x)), then A = fx 2 V : '(x)g has the property that for any small S  A, also Int(S ) 2 A. Thus (A; Int) is a sub-Ps-algebra of V . Since V is initial, A = V . 5. ( -separation) First observe that any bounded formula of CZF corresponds to an S -bounded formula in the language of E (cf. 3.7), which speaks about the object V and its subobject   V  V (the image of M  W  W ). For example, a bounded quanti er of the form 8y  x (y) corresponds to quanti cation along the small map  : B ?! V where B = f(y; x) : y  x ^ (y)g  V  V . For any such bounded formula ' of CZF, we now need to construct a set w 2 V with 8x 2 V (x  w $ '(x) ^ x  v). By bounded comprehension for Ps(V ) (3.7), there is a small subset A  V such that 8x 2 V (x 2 A i '(x) and x 2 Ext(w)). Thus we can take w = Int(A): 6. (In nity) E has a small natural numbers object N = W (1 ,! 1 + 1). De ne f : N ?! Ps(V ) by induction, by f (0) = ;, and f (n + 1) = ff (n)g [ f (n). Then Int(Im(Int  f )) is the standard set ! 2 V of natural numbers. 7. (Exponentials) Take x; y 2 V , and consider the small subsets X = Ext(x) and Y = Ext(y) of V . Their exponential Y X is a small object in E . De ne g : Y X ?! Ps(V ) by g(f ) = fhx; f (x)i : x 2 X g, and let a = Int(Im(Int  g)). 8. (Strong collection) Suppose 8xv 9y '(x; y). Take v 2 V and write A = Ext(v)  V . Let B = fhx; yi : '(x; y) ^ x 2 Ag. Then  : B ?! A is epi by assumption. Since A is small, the collection axiom (CA) for S gives the existence of a small object S and a map  : S  A factoring through B , say  =   for  : S ?! B . Let C be the image of   . Then C is a small subset of V (since V is separated), and w = Int(C ) veri es the conclusion of the collection axiom. This completes the proof of part (i) of the theorem, and it remains to discuss the validity of REA. We note that, by the usual construction of the transitive closure, any set x 2 V 2

1

0

2

1

1

2

23

belongs to some transitive x0 2 V , so that we may restrict our attention to transitive x. Validity of REA in the presence of (AMC) thus follows from the following two lemmas. Before stating the rst lemma, we introduce some notation. For any (small) map f : B ?! A between small objects, the subobject V (f )  V is small, and we write v(f ) = Int(V (f )): Lemma 7.2 (AMC) For every x 2 V there exists a collection map g between small objects such that x  v(g). Proof. It suces to prove that if x is transitive then there exists such a small collection map g with x  v(g), i.e. Ext(x)  V (g). Consider the small map (x) : M (x) ?! Ext(x) whose ber over y  x is Ext(y). Let g : B ?! A be a small collection map for which there is a quasi-pullback of the form -

g





? 

- ?

(x)

Such a g exists (internally), by (AMC). We now show that 8y  x : y 2 V (g) by induction on the elements y of the transitive set x. Suppose y  x and 8z  y : z 2 V (g). Then Ext(y)  V (g). Since Ext(y) is a ber of (x), clearly Ext(y) 2 Pg (V (g)), so by the algebra structure Int on V (g), y = Int(Ext(y)) 2 V (g): Lemma 7.3 If g : D ?! A is a collection map between small objects then v(g) 2 V is regular. Proof. It is easy to see that any set of the form v(g) is transitive. To see that V (g) is regular, take any b 2 V (g) and suppose that B = Ext(b) has the property that 8x 2 B 9y 2 V (g) '(x; y): We need to nd a c 2 V (g) such that C = Ext(c) has the property 8x 2 B 9y 2 C '(x; y): Since B 2 Pg (V (g)), there is a map t : Da ?! V (g) from a ber Da of g with B as image. Thus 8d 2 Da 9y 2 V (g) '(t(d); y): Since g is a collection map, there is a another ber Da , a surjection p : Da  Da, and a map s : Da ?! V (g) such that 8d 2 Da '(t(d); s(d)): Thus, we can take C = Im(s) to obtain c = Int(C ) with the required property. 0

0

24

0

8 Sheaves on Collection Sites

For the moment, let E be a pretopos with dependent products and W-types, and let S be a class of small maps. We work inside E . Before we turn to small maps between sheaves in the next section, we need to explain how the Axiom of Multiple Choice enables us to derive some standard properties of internal sheaves. First, let us establish some conventions concerning (internal) sites. We take a site C to be given by a category with nite limits, and for each C 2 C a family Cov(C ) of covers of C . So each S 2 Cov(C ) is a family of arrows with codomain C . These are supposed to satisfy the usual conditions: trivial covers, and stability under pullback and under composition. Write Cov(C ) = f(S; f ) : f 2 S 2 Cov(C )g. Then there is a commutative square

-C

Cov

1

cod

?

- C ?: (31) A site C is said to have small covers if Cov ?! Cov is a small map. A collection site is one in which Cov ?! Cov is a small collection map over C . A small site is one in which Cov ?! Cov ?! C are small maps and C ; C are small objects. Thus, for a small site, all Cov

0

0

0

0

maps in the square (31) will be small.

1

Lemma 8.1 For a collection site C , the inclusion of presheaves into sheaves has a left adjoint, the associated sheaf functor

a : PshE (C ) ?! ShE (C ): Proof. The usual construction of a by the \double plus" construction applies, but some care is needed when working in a pretopos with dependent products, and one has to use repeatedly that C is a collection site. By way of illustration we discuss a few aspects. Let X be a presheaf and let S be a cover of C , say S = f i : Ci ?! C j i 2 I g. A compatible family of elements of x over S is an assignment i 7! xi 2 X (Ci) such that xi   = xj   for any i; j 2 I and the corresponding pullback C  C - C 1

2

i C j



1

?

Ci

2

j

j

?

i - C: 25

If R = f k : Dk ?! C gk is another cover, we say that R re nes S if 8k9i(9 : Dk ?! Ci) ( i = k ). If R re nes S then x induces a compatible family xjR over R, by (xjR)k = xi  (for given k this does not depend on the index i and the arrow , by the compatibility of x). If x is a compatible family over S and y one over T , call them equivalent, (S; x)  (T; y), if there exists a common re nement R of S and T such that xjR = yjR. Denote by X (C ) the \set" of equivalence classes (this construction can be done in internally in E ). If x is a compatible family over S and : D ?! C then one obtains a compatible family (x) over the pullback (S ) in the obvious way: +

D C Ci i- Ci i

?

D

i



- C;?

(x)i := x  i:

This gives X the structure of a presheaf. One now shows, as usual, that X is separated, and that X is a sheaf whenever X itself is separated. We only discuss the rst property: +

+

+

X is separated: Suppose (S; x) and (T; y) represent elements of X (C ) which agree on a cover U = f i : Ci ?! C j i 2 I g of C . Thus for each i there exists R 2 Cov(Ci) such that R re nes i(S ) and i(T ) and i(x)jR = i(y)jR. Since C is a collection site, there is a reindexing of the cover U , say V = f j : Cj ?! C gj2J , such that R is given by a function Rj of j 2 J . Now by composition, one obtains a cover from these Rj = f k : Dj;k ?! Cj gk2K , namely f j  k : Dj;k ?! Cj ?! C gj2J;k2K ; which re nes S and T , and x and y agree on this cover. So (S; x)  (T; y). +

+

j

j

Proposition 8.2 For a collection site C , the category ShE (C ) internal sheaves is a pretopos with dependent products and W-types of small maps.

Proof. The nite limits and dependent products are those of PshE (C ). The sums and

quotients are constructed from those of PshE (C ) using the associated sheaf functor, from the previous lemma. Proposition 5.7 of [15] shows that Sh(C ) is closed under the formation of W-types. An examination of its proof reveals that W-types W (f ) exists in ShE (C ) for any small map f . Using (AMC), we can replace each site with small covers by a collection site, and deduce that the sheaves again form a pretopos: 26

Lemma 8.3 (AMC) For every site C with small covers there is an equivalent collection

site. It is obtained from C by taking the same underlying category and by reindexing the covers by a small collection map.

Proof. Take a quasi-pullback

B -- Cov

?

?

A -- Cov where B ?! A is a small collection map over Cov, and hence a fortiori over C . Then A \reindexes" the covers of each object C 2 C , and for each a 2 A, Ba reindexes the elements of the particular cover with new index a, so (C ; B ?! A; B ?! C ; A ?! C ) is really the same site with all families reindexed, and will hence de ne the same category of sheaves. 0

1

0

Corollary 8.4 Let E be a pretopos with dependent products and W-types, equipped with a class of small maps S . If S satis es (AMC), then for any internal site C in E with small covers, the category of internal sheaves on W-types of small maps.

C

is a pretopos with dependent products and

We do not know whether the condition that S satis es (AMC) can be dropped here.

9 Small Maps Between Sheaves

We will now turn to the construction of a class S of small maps between sheaves, from the given class S of small maps in E , and then show that S inherits the basic properties of S . We x a small collection site C , internal to E . Furthermore, we assume C is subcanonical and write C for the representable presheaf C (?; C ). (The assumption that C is subcanonical is not essential though, and one can replace everywhere the occurrence of C by the associated sheaves C (?; C ) of representable presheaves.) Throughout this section we work with internal presheaves and sheaves over C . ++

De nition 9.1 Let Y and X be sheaves. A map f : Y ?! X is a small map of sheaves i for each C 2 C , the map fC : Y (C ) ?! X (C ) is small. This de nes the class of small maps S . Remark 9.2 (i) The de nition of course makes sense for presheaves as well. (ii) If f : Y ?! X is a small map between sheaves, then f( ; y) j : D ?! C , y 2 Y (D) and f (y) = x  g is small for all C and x 2 X (C ), since a small sum of small sets is small. (iii) Y ?! 1 is small i Y (C ) is small for each C . 27

Our aim is to prove that S inherits properties from S . Certain properties are immediately veri ed by considering the sheaves and their maps \pointwise" or rather \objectwise", i.e. considering properties of Y (C ) ?! X (C ) for each object C . For the rest we need a couple of lemmas and de nitions. If S is a cover of C , write

jS j =

X dom( ); 2S

with an associated canonical map of sheaves S : jS j ?! C . Thus an arrow x : jS j ?! A between sheaves is the same as an indexed family fx 2 A(dom( ))g 2S .

Lemma 9.3 Let C 2 C and suppose A is a sheaf. If f : A ?! C is epi, then there exists a cover S 2 Cov(C ) and a map x making the diagram jS j x - A @ S@

@R ?f C

commute.

Proof. Since f is epi, there exists a cover T 2 Cov(C ) such that for each 2 S there exists an x 2 A(dom( )) with f (x) = . Since Cov ?! Cov is a collection map over C , there is 0

another cover S of C for which there exists a choice function for the quanti er combination \for each there exists an x" above, i.e. a function x on S with x 2 A(dom( )) and f (x ) = for all 2 S . This is exactly a map x : jS j ?! A as required. Next we need to verify that shea cation preserves smallness in the following sense.

Lemma 9.4 If P ?! X is a small map from a presheaf into a sheaf, then P ?! X is again small, and hence so is the map a(P ) = P ?! X from the associated sheaf. Proof. The result follows easily from the explicit description of P given in Lemma 8.1. +

++

+

The following result is often useful for checking that a particular map is small.

Lemma 9.5 Let f : Y ?! X be a map of sheaves. Suppose that x 2 X (C ) and that S = fCi ?! C gi is a cover. If for all i and all : D ?! Ci, the set fD? (x  i ) is small, i

1

then fC? (x) is small. 1

Proof. The assumption implies that the set B=

Y f ? (x  ) 1

i2I

Ci

28

i

is small. By the sheaf property, fC? (x) is isomorphic to fg 2 B : g compatibleg. Now \g compatible" is expressed by the formula (8i; j 2 I )(8D 2 C )(8 : D ?! Ci)(8 : D ?! Cj ) g(i)  = g(j )  ; which is S -bounded since the site is small and each fD? (x  i ) is small. Hence fC? (x) is small. The main theorem now reads as follows. We emphasize that it does not assert the existence of the W-type W (f ) in ShE (C ) for arbitrary maps f , only for small maps. Theorem 9.6 Let C be a small collection site. Let S be the class of small maps between sheaves in ShE (C ) obtained from a given class S of small maps in E (cf. De nition 9.1). Then: (i) S is a stable class of small maps in ShE (C ). (ii) If S is representable, then so is S . (iii) If S satis es (AMC), then so does S . Proof. (i): We check the conditions (S1-4), (F1-5) for small maps are satis ed by S whenever they are satis ed by S . (S1), (S4) and (F1) can easily be checked by \pointwise" reasoning. To check (S2) consider a pullback square Y0 - Y g f 1

0

1

?

?

1

X 0 p-- X with g small and p epi. Let C 2 C and x 2 X (C ). Since p is epi there is a cover fCi ?! C gi2I , and xi 2 X (Ci) so that p(xi ) = x  i for all i 2 I . For : D ?! Ci we have p(xi  ) = p(xi )  = x  i . Now since gC? (xi  )  = fC? (p(xi  )); and gC? (xi  ) is small, fC? (x  i ) is small. Thus fC? (x) is small by Lemma 9.5. Condition (S3) is checked by a similar use of Lemma 9.5. Conditions (F2) and (F3) are veri ed by rst making the constructions in presheaves, and then applying Lemma 9.4. By inspecting the arguments in [15] one easily sees that (F4) and (F5) holds for S . (ii): We continue to work with a small site, and discuss the representability axiom for small maps. In fact, one can deduce the representability of the class S in ShE (C ) from that of S in E , exactly as in [10, p. 91]. To see this, suppose S = S () where  : E ?! U is in E . De ne a sheaf (a sum of representables) XXXC (32) U= i

1

1

1

1

1

C

f

29

R

as follows: C ranges over all objects of C . For a given C , f in (32) ranges over all small families f = ffi : Di ?! C gi2I of arrows into C (not necessarily covers). Write

jf j =

XD i2I

i

for such a family. Next, given C and f , R in (32) ranges over small families of arrows

n

R = Ek ?! jf j C jf j =

P

XD  D o ; i;j

i C

j

k

with jRj = Ek as before, such that the image of jRj de nes an equivalence relation on jf j (contained in jf j C jf j  jf j  jf j). Thus, for each such C; R; f we have a coequalizer, mapping into C :

- jf j - jf j=jRj =: jf; Rj f;R- C; jRj PPP and we can de ne a sheaf E over U by letting E = C f R jf; Rj and  : E ?! U be

the map given by f;R as above on each summand indexed by C; f; R. Since each jf; Rj is a small sheaf,  is a small map of sheaves. We claim it is universal. To see this, take a small map g : Y ?! X of sheaves, and consider the \canonical" quasipullback PC Px P ;y D - Y g ? PC;x?C -- X P where C; x range over all C 2 C and x 2 X (C ), and for given C; x, the sum ;y ranges over the small set

gC;x = f( : D ?! C; y) j y 2 Y (D); g(y) = x  g: For a given C and x 2 X (C ), also consider R given by ;

fE ?! D C D0 j (D ?! C; y) and (D0 ?! C; y0) belong to gC;x and y  = y0  g: Then with the notation j  j for the sum, we get a coequalizer - jgC;xj -- Yx jRj -- jgC;xj Y jgC;xj where Yx = C X Y . This now gives a double pullback (

0

)

x

30

E

-Y

Yx

? U

? ? C x -X where C ?! U is the inclusion of the summand given by gC;x and R as above. Taking the sum over all C and x gives a double pullback as required for the representability axiom. This proves that the class S is representable if S is. (iii): This will be proved in the next section.

10 The Axiom of Multiple Choice for Sheaves This section is devoted to the proof of Theorem 9.6.(iii). First, we make some preparatory remarks. Throughout this section we assume C is a small collection site. Remark 10.1 Suppose that T ?! R is a map between sheaves. Then this map is a collection map (internally in E ) i for any D 2 C and : D ?! R, and for any epi p : X  T = T R D, there exists a cover f k : Dk ?! Dgk of D, and for each index k a map k : Dk ?! R and a factorisation

X - X ?? ? ? p.b. ? T ? --T - T : k

k

k

Since C is a collection site this property can equivalently be phrased as: there exists a cover R of D and maps : jRj ?! R and x : jT j ?! X , for which T  T x - X p-- T - T p.b.

q.p.b.

p.b.

? ? ? - ? D R  jRj R R commutes, and p  x : T ?! T ts into a quasi-pullback, as indicated.

(33)

We will now prove the main result of this section, thus verifying (AMC). Proposition 10.2 For any small map B ?! A between sheaves, there exists a quasipullback -

T

B

? ? R -- A0 -- A where T ?! R is a small collection map over A0 , and R ?! A0 is small as well. 31

(34)

Proof. Consider the canonical epi A0  A where A is the sum of representables C (?; C ) indexed by all pairs (a; C ) where a 2 A(C ) and C 2 C . By pulling back B ?! A along A0  A, and by using Remark 4.2.(iv), we nd that it is enough to prove the proposition in the case where A is a representable sheaf C . Next, by replacing the small site C by C =C , we nd that it is in fact enough to assume that A = 1, and to construct a quasi-pullback of the form T -B 0

? ? R -- 1

where T ?! R is a collection map between small sheaves. To this end, take any small sheaf B in the ambient category E , and use (AMC) in E to obtain a quasi-pullback of small sets P M - C (B=C ) 0

P

?

?

L -- C 1 = C (35) where M ?! L is a small collection map over C . Here we have written (B=C ) = f( ; b)j : D ?! C; b 2 B(D)g. For a given ` 2 L, de ne Cov(`) to be the collection of M`-indexed families b F = f(Si; Ei ?! C; jSij ?! B ) : i 2 M` g (36) where C = (`), i : Ei ?! C is an arrow in C , Si is a cover of Ei, and the canonical map X (37) jF j := jSij ?! C  B 0

0

0

i

i

i2M`

is epi. We emphasize that Cov(`) is a small set. This can be seen by writing out the condition that this last map (37) is epi, explicitly in terms of the site: it will only involve quanti ers over small sets because the site C and the sheaf B are assumed to be small. Now de ne X X (l); R =

T =

`2L F 2 ` X X jF j; Cov( )

`2L F 2

`

Cov( )

and notice that these sheaves are small. Lemma 10.3 There is a quasi-pullback of small sheaves

-B

T

? ? R -- 1 32

(38)

with R  1 epi.

The map T ?! R is the canonical map, obtained as the sum of the maps jF j = PProof. j S ! C , for F = f(Si; Ei ?! C; bi)gi as in (36). The square (38) is the \sum" of i2M i j ? squares `

-B

jF j

?

?

C -- 1 ranging over all ` and F 2 Cov(`), where C = (`). Each of these squares is a quasipullback (simply by the assumption that (37) is epi), hence so is the sum (38). It remains to show that R ?! 1 is epi. In fact, we will show that for each C 2 C , there exists an ` 2 L and an F 2 Cov(`) so that (`) = C . Now surely there is an ` 2 L with (`) = C because L ?! C is epi (cf. (35)). The diagram (35) also provides for this ` a surjection ` : M` ?! (B=C ) : Write `(i) = (Ei ?! C; bi); for each i 2 M` , and let F 2 Cov(`) be the family which assigns to each i the trivial cover of this Ei, F = f(f1E g; Ei ?! C; bi)gi2M : Then F indeed belongs to Cov(`), in fact jF j ?! C  B is already an epi of presheaves. This proves the lemma. 0

0

i

i

i

`

Lemma 10.4 The map T ?! R is a collection map of sheaves. Proof. We use the description of the collection maps of sheaves given in Remark 10.1. Take any map : D ?! T and an epi p : X  T = T R D: By moving to a cover of D, we may assume that maps into a summand C of R indexed by ` and F . Write this F as

b F = f(Si; Ei ?! C; jSij ?! B)gi2M as before. Thus C = (`), and i

i

T = jF j = so that p : X ?! T is a sum of epis pi : Xi  jSij 33

X jS j;

i2M`

i

(i 2 M` ):

`

Since C is a collection site by assumption, we nd for each ( : D ?! Ei) 2 Si a cover R of D and a factorization jRj x- X R

?

?

D- - jSij S - Ei Since C is a collection site (again), there is a reindexing T of the cover Si so that R and x are given as a function of 2 T , say R ; x . Now R = f   j 2 T;  2 Rg is also a cover of Ei (by composition of covers), and it is a re nement of Si; in fact there are epis i

jRj  jT j  jSij  jEij:

Also, the fx : 2 T g paste together to a map x as in jRj x- Xi

? ? jT j jSij

(39)

So we have proved: (*) For each i 2 M` there exists a cover R of Ei, re ning Si by an epi jRj ?! jSij, for which there is a commutative square (39). Since M ?! L is a collection map over C , we can nd another `0 2 L, with (C 0) = C also, and an epi  : M`  M`, so that R and x in (*) are given by functions Ri and xi depending on i0 2 M` . So for each i0 there is a cover Ri of E i , and xi ts into a square jR j xi - X 0

0

0

0

0

i

0

(

0

)

0

0

i

( 0)

0

? ? jT j jS i j

(40)

( 0)

Now de ne

F 0 = f(Ri ; E i ; b i )gi 2M : Then F 0 belongs to Cov(`0), so (`; F 0) is the index of a summand C of R. Thus : D ?! C (the map we started out with) de nes a map 0 : D ?! R also and we obtain a diagram 0

T

p.b.

? R

T

0

?

D

( 0)

( 0)

0

`0

~

-- T

1

-- D? - R?

34

-T

p.b.

(41)

on top of which is the following triangle

x~

Pi 2MjRi j 0

`0

*

Pi2M Xi `

-- Pi 2M?jRij ~

0

0

`

here ~ : T ?! T sends jRi j to jS i j and x~ sends jRi0 j into X i as in (40). Since  is surjective and each jRi j ?! jS i j is epi, so is the map ~. Thus the middle square in (41) is a quasi-pullback, and the proof is complete. By these lemmas we have proved Proposition 10.2, and hence completed the proof of Theorem 9.6. 0

0

0

( 0)

(

0

( 0)

)

11 Strati cations In this section we introduce the notion of strati ed pseudotopos, which is a predicative analogue of elementary topos, in that it enjoys closure under the internal sheaves (Theorem 11.2). Strati ed pseudotoposes also arise naturally from Martin-Lof type theory (Section 12). Let E be a pretopos with dependent products and W-types. A ltration of E is a sequence of subcategories

S  S  S   of E with the property that E = [n Sn. We will consider such ltrations where each Sn is a class of small maps, satisfying (AMC) as described in previous sections. If S  S 0 are two classes of small maps, we say that S is properly contained in S 0 (notation: S  S 0 ) if there exists a representing map  : E ?! U for S (i.e. S = S ()) for which U ?! 1 belongs to S 0 , i.e. U is an S 0 -small object. De nition 11.1 A (representable) strati cation of E is a ltration of E by (representable) classes of small maps (Sn ) such that S  S  S   and E = [nSn : A pseudotopos is a pretopos E with dependent products and W-types for which such a strati cation exists. A pair (E ; (Sn)n) consisting of a pseudotopos and an explicitly given 0

1

2

0

0

1

2

strati cation will be referred to as a strati ed pseudotopos. Note that this notion of a strati ed pseudotopos is stable under slicing, for if (Sn) is a strati cation of E then (Sn=X ) is one of E =X .

Theorem 11.2 If E is a strati ed pseudotopos, and C is a collection site in E , then ShE (C ) is a strati ed pseudotopos.

35

Proof. Let (Sn) be a strati cation of E . By reindexing this strati cation, if necessary, we may assume that C is a S -small collection site. Let S n be the class of Sn -small sheaf maps. According to Theorem 9.6, each Sn is a stable representable class of small maps in ShE (C ), which satis es AMC. By the construction of S from S it is clear that Sn  Sn implies S n  S n . To see that the inclusion is proper, we need only to inspect the construction of the representing map  : E ?! U for Sn . The sheaf U is constructed in (32) by twice taking sums over the collection all Sn-small families of arrows, and then shea fying. Thus by using Lemma 9.4 one sees that U (D) is in Sn . Hence U ?! 1 2 Sn , proving that the inclusion is proper. Also [n S n = ShE (C ), since each sheaf is given by a map in E and [nSn = E . Remark 11.3 Suppose S  S 0 and 0 : E 0 ?! U 0 is a universal S 0 -small map, so that S 0 = S (). Then there exists a double pullback 0

+1

+1

+1

U

V

? 1 

?

+1

- E0

?

- U0 T In many examples, related to type theory, 1 is projective, so the epi T obtain a pullback of the form U - E0 ? - ?0 U

1

(42)

 1 splits and we (43)

12 Relation to Type Theory In this section we give a predicative, constructive example of a strati ed pseudotopos by building such a category inside one of Martin-Lof's type theories (cf. Theorem 12.7). This pseudotopos, Sets, plays a similar fundamental role as the ordinary category of sets. We recall some background from our previous paper [15]. In Martin-Lof type theory [13] the category of sets, denoted Sets, is naturally de ned to be the category of types (or presets) with equivalence relations and functions preserving these equivalences. The basic type theory of Martin-Lof consists of rules for - and -types, disjoint sum-type (+), natural numbers N , the canonical nite sets N k = f0; : : : ; k ? 1g, and the (intensional) identity type. (See Troelstra [21] for a discussion about the relation between these basic axioms.) We will consider an extension ML
code a 2 Un . That the sequence is cumulative means that for each type A there is some external index n and some a 2 Un such that A = Tn (a). Moreover we have an embedding function tn : Un ?! Un and a constant un 2 Un satisfying the equations +1

+1

Tn+1 (tn (a))

= Tn (a);

Tn+1 (un )

= Un :

In the rst universe U ; T there are codes for the basic types N and N k , k = 0; 1; 2; : : :, i.e. there are constants n; nk 2 U with T (n) = N and T (nk ) = N k . Moreover, in each universe Un ; Tn there are codes for type constructions , , W and Id, that is for a 2 Un and b(x) 2 Un (x 2 Tn (a)), we have 0

0

0

^ (a; b) 2 Un ;

0

0

^ (a; b)) Tn (

= (x 2 Tn (a)) Tn (b(x));

and similarly for  and W . For identity types we have for each a 2 Un and b; c 2 Tn (a) a ^ a; b; c) 2 Un and its decoding as identity type code Id( ^ a; b; c)) = Id(Tn (a); b; c): Tn (Id( We shall frequently use the propositions-as-types principle of type theory. It states that a type A can be regarded as a proposition, in which case we say that A is true if there is some element a 2 A. Conversely, each proposition is also a type (of its proof objects). We introduce some useful notation. An object A of Sets is written (A; =A) where the type is A and =A is the equivalence relation on A. If P (x) is a property of A that is preserved under the equality =A, we use fx 2 A jj P (x)g to denote the set ((x 2 A)P (x); ) with the equivalence  given by (x; p)  (x0 ; p0) i x =A x0 . For a map f : B ?! A in Sets, let f ? (a) denote the set fx 2 B jj f (x) =A ag, the ber of f over a. We de ne the discrete category A corresponding to the set A = (A; =A) by letting the collection of objects be A and the set of morphisms from a to b be the type a =A b together with an equality which identi es all morphisms. The proof objects for re exivity, symmetry and transitivity then becomes the identity arrow, the inverse operation and the composition, respectively. The discrete category is thus a groupoid. We extend f ? to a functor A ?! Sets by letting, for p : (a =A a0), f ? (p) : f ? (a) ?! f ? (a0) be the unique map (x; p0) 7! (x; p00). In [15] we proved the following result. 1

#

1

#

1

1

1

Theorem 12.1 In the type theory ML
dent products and W-types.

The purpose of the remainder of the section is to strengthen this theorem by showing that the category Sets is a strati ed pseudotopos within the same type theory; see Theorem 12.7 below. For each n < !, let Setsn be the full subcategory of Sets where the objects 37

are sets A = (A; =A) and where A = Tn (a), for some a 2 Un , and x =A y is of the form Tn (e(x; y )) for some e 2 (Tn (a  a) ? ! Un ). Clearly

Sets  Sets  Sets     0

1

2

and since the hierarchy Un ; Tn is cumulative, every set belongs to some Setsn. Let Sn be the class of maps f : B ?! A in Sets such that for every a 2 A there is some set S in Setsn and an isomorphism ' : f ? (a) ?! S . Below we rst show that Sets has enough (internal) projectives (Lemma 12.3) and then that Sn is representable by a universal map  n : En ?! Un (Lemma 12.4). Next, in Lemma 12.5 we show that Sn is closed under composition and is locally full. Finally, Lemma 12.6 veri es the ber axioms (F1{5). To construct the universal map for Sn we use the universe Un , Tn and the identity type. We rst take a closer look at the latter construction. 1

(

)

Identity types and projective objects. For any type A and any elements a; b 2 A we

can in type theory form the (intensional) identity type IdA(a; b) (also written Id(A; a; b)). Its intended interpretation is as the type of proofs (if any) that a and b are identical. The introduction rule is a2A (Id ? intro:) ; r(a) 2 IdA (a; a) and the elimination rule is (x 2 A) ... c 2 IdA(a; b) d(x) 2 C (x; x; r(x)) (Id ? elim:) J(c; d) 2 C (a; b; c) where C (x; y; z) is a family of types with x; y 2 A, z 2 IdA(x; y), which we call the eliminating family. The computation rule connecting the two is J(r(a); d)

= d(a):

M. Hofmann and T. Streicher [8] discovered that the identity type induces a groupoid structure on each type. (We refer to Streicher [20] for a thorough investigation of identity types.) We de ne for each type A an associated groupoid A. Let A be the objects of A and for any a; b 2 A, let IdA(a; b) be the type of morphisms from a to b. Two such morphisms p and q are considered equal if Id(IdA(a; b); p; q) is true. The identity arrow for a 2 A, is 1a = r(a) 2 IdA(a; a). For p 2 IdA(a; b) and q 2 IdA(b; c) we de ne the composition by

q  p = Ap(J(p; t); q) 2 IdA(a; c) 38

where t(x) = u:u 2 (IdA(x; c) ?! IdA(x; c)) and where C (x; y; z)  IdA(y; c) ?! IdA(x; c) is the eliminating family. The computation rule gives immediately q  1b = q. The other axioms for a category are veri ed using Id-elimination. The inverse p? of p 2 IdA(a; b) is given by p? = J(p; r) where the eliminating family is C (x; y; z)  IdA(y; x). We have directly 1?a = 1a . That p? is the inverse of p is checked using Id-elimination. We summarize this as a lemma. 1

1

1

1

Lemma 12.2 (Hofmann, Streicher) For each type A, the structure A is a groupoid. The category Presets is the full subcategory of Sets determined by the objects of the form (A; IdA(; )). We often just write A for such an object. The full subcategory given by the objects of this form in Setsn is denoted Presetsn. To any family of types B (x) (x 2 A) there is a functor associated

F = FA;B : A ?! Presets

(44)

de ned as follows. Let F (a) = B (a) and for p 2 IdA(a; b), put F (p) = J(p; t) where t(x) = u:u 2 (B (x) ?! B (x)) and the eliminating family C (x; y; z) is B (x) ?! B (y). It is immediate that F (1a) = 1B a . To prove functoriality one uses (Id-elim) for the family C (a; b; q) given by def

def

( )

(8p 2 IdA(b; c)) (8x 2 B (a)) IdB c (F (p)(F (q)(x)); F (p  q)(x)): ( )

We may view the family B (x) (x 2 A) as bers of a map in the following way. Form the type S = (x 2 A)B (x). Let  : (S; IdS (; )) ?! (A; Id(; )) be the rst projection. Then for each u 2 A there is an isomorphism 1

'u : ? (u) ?! (B (u); IdB u (; )) 1

(

1

)

given by 'u((x; y); p) = F (p)(y), where p 2 IdA(x; u). Let Pn be the class of maps f : B ?! A in Presets such that for each x 2 A there exists S in Presetsn and an isomorphism g : f ? (x) ?! S . 1

Lemma 12.3 (i) For every f : B ?! A in Sn there exists a quasi-pullback Q k-B h

f

? ? P m-- A

(45)

where h belongs to Pn and m is epi. Moreover if A is a terminal, then P can be chosen to be terminal.

39

(ii) Each h : Q ?! P in Pn is internally projective in Sets=P .

Proof. (i) Suppose that f : B ?! A is in Sn . By the usual choice principle for pure types we nd Sx 2 Setsn and gx : Sx ?! f ? (x) so that gx is an isomorphism for each x 2 A. Let P = (A; IdA(; )). Put Q = (x 2 A)S x, Q = (Q; IdQ(; )) and h =  . By the paragraph preceeding this lemma we have h? (x)  = (S x; IdS ), so h is in Pn. De ne k : Q ?! B by k(x; y) =  (gx(y)), and m : P ?! A by m = x:x. These functions are 1

1

1

x

1

trivially well-de ned since both P and Q have identity as equality. The map m is also trivially epi. We check that the square (45) is a quasi-pullback. Let (p; b) be an element of the canonical pullback P A B . Then p 2 P , b 2 B and m(p) = p =A f (b). Thus b0 = (b; q) 2 f ? (p) for some q. The canonical map from Q to P A B is (h; k) and we have (h; k)(p; gp? (b0)) = (p;  (gp(gp? (b0)))) = (p;  (b0 )) = (p; b). The map (h; k) is thus epi, since (p; b) was arbitrarily chosen. If A is a terminal, then it is isomorphic to the canonical one element set (N ; IdN (; )), which can be taken to be P . (ii) Let h : Q ?! P be an arrow in Pn. Suppose that t : T ?! P , r : X ?! P and s : Y ?! P are objects of Sets=P and that f : T P Q ?! X and k : Y ?! X are arrows of the same slice, i.e. rf = t and rk = s. Moreover, suppose that k is epi in Sets=P . Thus (8x 2 X ) (9y 2 Y ) k(y) =X x. By the choice principle for types, let m : X ?! Y be a function so that k(m(x)) =X x for all x 2 X . Let T 0 = (T; IdT (; )), and put t0 = t and e = x:x. Thus e is epi and an arrow in Sets=P . De ne g : T 0 P Q ?! Y by 1

1

1

1

1

1

1

1

g(u; p) = m(f (e(u); p)): Since equality in T 0 P Q amounts to identity in each of the components, g becomes automatically well-de ned. One easily checks, using the above equations, that g is an arrow in Sets=P . Also k(g(u; p)) =X k(m(f (e(u); p))) =X f (e(u); p), proving that h is internally projective.

Construction of universal small maps. Now we construct the universal small map  n : En ?! Un for Sn. Let (U; T) = (Un ; Tn ) be the nth universe. By (44) above we have a functor Fn = FU;T from U to Presets. Let U be the set (U; =U ) where U is the type (a 2 U) (e 2 T(a  a) ?! U) P (a; e) and P (a; e) is a proposition stating that T(e(; )) is an equivalence relation on T(a). For an element u = (a; e; q) 2 U we write (u) = a and Su = (Su; = u ), where Su = T(a) (

)

1

(

)

and x = u y is T(e(x; y)). The equality =U of U is given by: u =U v i for some p 2 IdU((u) ; (v) ) we have (

)

1

1

(8x; y 2 Su) [x = u y () Fn(p)(x) = v Fn(p)(y)]: (

)

( )

(46)

A proof object for this equality is thus a pair (p; m). Since Fn is a functor from a groupoid, the property (46) means, indeed, that Fn(p) is an isomorphism from Su to Sv , with inverse Fn(p? ). Using the functoriality of Fn it is then straightforward to check that =U is an 1

40

equivalence relation, where the re exivity property follows by letting p = r(a). Next de ne E = (E; =E ) by putting E = (u 2 U )T((u) ) and where the equality =E is given by: (u; x) =E (v; y) i Fn(p)(x) = v y for some p 2 IdU ((u) ; (v) ) such that (46) holds. Again using functoriality this is seen to be an equivalence relation. The projection  : E ?! U given by (u; x) = u is clearly a wellde ned map in Setsn . Finally, let  n = , En = E and Un = U and the construction is complete. Lemma 12.4 For each n,  n : En ?! Un represents Sn, and moreover there is a pullback diagram E "n - E 1

( )

1

1

+1

(

(

)

)

n

n (

)

n

+1

n

?

?

(

+1)

Un n - Un

+1

and Un ?! 1 2 Sn . Proof. Let u = (a; e; q) 2 Un so that Su = (Tn (a); T(e(; ))). By de nition every set in Setsn is of this form. For the rst statement, it is sucient to establish an isomorphism ' as below, by the characterization of representability (see Section 3). De ne ' : Su ?! ?n (u) = f(v; y) 2 En jj v =U ug +1

1

(

n

)

by '(x) = ((u; x); qx) where qx = (px; mx) is a proof of u = u u with px = r((u) ). Then '(x) = '(x0) i x = u x0 . To prove that ' is onto, let (v; y) 2 En satisfy v =U u. Hence for some p 2 IdU ((v) ; (u) ) the equivalence (46) holds. Let x = Fn(p)(y). Then (u; x) =E (v; y), so ' is also onto, and consequently an isomorphism. To obtain the pullback square we de ne n (a; e; q) = (tn (a); tn  e; q) and "n(u; x) = (n(u); x). These functions are checked to be well-de ned using Id-elimination. Trivially,  n  "n = n   n , so the square commutes. Suppose now that f : C ?! Un and g : C ?! En satisfy n  f =U  n  g. Write g(u) = ((g u; g u; g u); g u) and f (u) = (f u; f u; f u), so by the de nition of =U there is some pu 2 IdU (g u; tn(f u)) with Tn ((g u)(x; y )) () Tn ((f u)(Fn (pu )(x); Fn (pu )(y ))) for all x; y 2 Tn (g u). Note that k(u) = Fn (pu)(g u) 2 Fn (tn(f u)) = Tn (f u). De ne h : C ?! En by h(u) = (f (u); k(u)). It is straightforward, but somewhat tedious, to check that h is the unique map with  n  h = f and "n  h = g. Finally, it is clear that Un ?! 1 2 Sn , since the construction of Un is carried out within the universe Un . (

(

)

1

n

)

n

1

1

n

(

(

+1)

)

n+1

+1

1

2

3

n+1

4

1

+1

+1

1

2

(

+1)

n+1

3

1

2

2

1

+1

+1

(

)

+1

+1

41

+1

4

+1

1

1

f g Lemma 12.5 For maps X ?! Y ?! Z in Sets with g 2 Sn, f 2 Sn () gf 2 Sn : Proof. For each z 2 Z there is Bz in Setsn and an isomorphism z : Bz ?! g? (z). There are canonical injections y : f ? (y) ?! X , z : (gf )? (z) ?! X and z : g? (z) ?! Y . ()) Suppose f 2 Sn . Thus for each y 2 Y there is Ay 2 Setsn and an isomorphism 'y : Ay ?! f ? (y). To show gf 2 Sn it suces to prove that (gf )? (z) is isomorphic to some C 2 Setsn. Let D = Bz ,  = z  z and de ne a functor E : D ?! Setsn by E (u) = A u and for p : (u =D u0) let E (p) = '? u  f ? (tu;u (p))  ' u where tu;u : (u =D u0 ?! (u) =Y (u0)): Note that E (p) does not depend on p, since f ? : Y ?! Sets is a functor. Let now C = (u 2 D)E (u) and de ne the equality by (u; v) =C (u0; v0) i E (p)(v) =E u v0 for 1

1

1

1

1

1

#

1

(

)

(

1

0

)

0

(

)

0

1

#

(

0

)

some p : (u =D u0). By the functor property =C is indeed an equivalence relation. Thus C 2 Setsn. De ne a map  : C ?! (gf )? (z) by (u; v) = (x; q) where x =  u (' u (v)) and q is a proof object for g(f (x)) =Z z. It is readily checked that  is an isomorphism. (() Suppose gf 2 Sn. Thus for each z 2 Z there is Cz 2 Setsn and an isomorphism z : Cz ?! (gf )? (z). Let y 2 Y be arbitrary and let D = Cg y . Let (y; p) 2 g? (g(y)) and put A = fu 2 D jj g?y (hy (g y (u))) =B g?y (y; p)g; where hy is the canonical injection (gf )? (g(y)) ?! g? (g(y)). By the form of A is clear that it belongs to Setsn. It is straightforward to check that : A ?! g? (y), given by (u; p) = (g y (g y (u)); p0), for some p0 depending on (u; p), de nes an isomorphism. Lemma 12.6 The class Sn satis es the axioms (F1-5) for slicing. Proof. This is straightforward by examining the constructions berwise, and by using the fact that Setsn is closed under the pretopos operations, - and W -constructions. Now Lemma 12.3 { 12.6 yield the desired theorem. Theorem 12.7 In the type theory ML