Vol.11, No.4, November1982 0097-5397/82/1104-0011$01.00/0
THE CATEGORY-THEORETIC SOLUTION OF RECURSIVE DOMAIN
EQUATIONS*
M. B. SMYTHt AND G. D. PLOTKIN"
Abstract. Recursivespecifications of domainsplaysacrucialrole in denotational semantics asdevel- oped by Scott and Stracheyand their followers. Thepurposeofthe present paper isto setup a categorical frameworkin which the knowntechniquesfor solving these equations find a naturalplace.The idea is to follow the well-knownanalogybetweenpartialordersand categories,generalizing from leastfixed-points of continuous functions over cpos to initial ones of continuous functors overo-categories.Toapplythese generalideas we introduceWand’s O-categorieswhere the morphism-sets have a partial order structure andwhich include almost all the categories occurring in semantics. The idea is to find solutions inaderived category ofembeddingsandwegive order-theoretic conditions which are easytoverify and which imply theneededcategorical ones. The main tool is a verygeneralform of the limit-colimit coincidence remarked byScott. Intheconcludingsection we outlinehowcompatibilityconsiderationsare tobe included in the framework.Afuture paperwillshow howScott’suniversal domainmethodcanbe included too.
Keywords. Domains,semantics, data-types,category,partial-order, fixed-point,computability
1. Introduction. Recursivespecificationsof domainsplaya crucial role in denota- tional semantics asdeveloped byScottandStracheyand theirfollowers(Gordon
[13],
Milne and Strachey
[26], Stoy [39], Tennent [40], [41]).
Forexample, the equation(1)
D-At+(D-D)
is justwhat isneeded forthesemantics of an untypedA-calculus for computingover adomain,
At,
of atoms. Again, thesimultaneousequations(2)
T-AtxF,
(3) FI+(TxF)
specifyadomain,
T,
of allfinitarily branchingtrees andanother,F,
offorestsofsuch trees. And recursively specified data types are also very useful[10], [19], [20].
The firsttoolsforsolving such equationswereprovided byScottusinghis inverse limit constructions
[33].
Later he showed how the inverse limits could be entirely avoided by using auniversal domain and the ordinary leastfixed point construction[34]. A
systematic expositionof the inverse limitmethodwasgivenby Reynolds[301,
and the categorical aspects (already mentioned by Scott) were emphasized by Wand
[43].
All of these treatments stuck to one category, such as, for example,CL,
the category of countably based continuous lattices and continuous functions, although thedetails did notchange muchinother categories. Then Wand[44],
gaveanabstract treatmentbasedonO-categories where the morphismsetsareprovidedwith a suitable order-theoretic structure.The relationbetween the category-theoretictreatmentand the universal domainmethod has,untilnow,remainedratherobscure.The purpose of the present paperis toset up acategorical framework in which all knowntechniques for solvingdomainequations find a naturalplace. The idea as setoutin 2istofollow the well-knownanalogybetweenpartial orders and categories, and generalize from least fixed points to initial fixed points. These are constructed
*Receivedby the editorsJanuary2, 1979, and in revised formFebruary 17, 1982. This work was partially supportedbyagrant fromtheScienceandEngineeringResearch Council.
r
DepartmentofComputerScience,UniversityofEdinburgh, Edinburgh,ScotlandEH9 3JZ.761
762 M.B. SMYTH AND G. D. PLOTKIN
using the "basic lemma" which plays an organiz.ational role" Most of the solution methods considered appearaswaysofensuring that thehypothesesofthe lemma are fulfilled. Just as continuous functions overcomplete partial orders always have least fixedpoints,so continuous functorsovero)-categories (asdefinedbelow) always have initial fixedpoints, whichcanbe constructed by usingthe basiclemma; thisseems to formalize some hintsofLawverementioned byScottin
[33].
The sameideaappears in[1], [2].
All this is very general, and we introduce O-categoriesin 3 in order to apply the basic lemma to the construction of the domainsneededin denotational semantics.
Hereweareclearly greatlyindebted toWand
[44], [45]
who introduced O-categories, and indeed our work arosepartly as anattempttosimplify and clarifyhistreatment.The idea is to apply the basic lemma not to a given
O-category, K,
but rather to a derived category, KE,
of embeddings (equivalently, projections). We then look for easily verified conditions on K (whether categorical ororder-theoretic) which imply theneededconditions on KE.
Our main tool is Theorem 2, which establishes a very general form of the limit-colimit coincidence remarked by Scott
[33]
and also gives an order-theoretic characterization of the relevant categorical limits. This improves Wand’s work by removing the needfor histroublesome "ConditionA"
(appearingin[44]
ratherthan[45]
whichincorporates some of the ideas ofthe presentpaper); more positively we alsointroduceausefulnotionofdualityfor O-categories.With the aid of Theorem 2 (and the easy Theorem 1), one sees that simple conditions on an
O-category, K,
(mainly that ithas allP-limits)
ensure that KE is an o-category. Again with the aid of(Lemma
4 and) Theorem 3, one sees how to take any mixedcontravariant-covariantfunctor overK (likethe function-spaceone)
which satisfies an order-continuity property (usually evident), and turn it into a covariant-continuous one over
K E.
Section4 presents several examples ofuseful categories which may be handled by the methodsof 2 and 3.
The method of universal domains, in relation to the ideas presented here, is treated in the sequel to this paper.
An
indication of our approach may be found in Plotkin and Smyth[28]
(which may also be of help in getting ageneral overviewof ourresults).There is, however, one aspect of Scott’s presentation of the universal domain approach
[34]
which must receive some mentionhere:the question ofcomputability.The results presentedin thispaper wouldlose muchof theirpointif we were forced to invoke a universal domain to handle computability. In the concluding 5, we indicatebriefly how thistopic caninfactbe handledatthe level of generality ofthis paper; foramore detailed treatment werefertoSmyth
[38].
Weassumethe readerpossesses a basicknowledge of categorytheory; anygaps can be filled by consulting Arbib and Manes
[4],
Herrlich and Strecker[16],
or MacLane [21].
2. Initial fixedpoints. Inthecategoricalapproachto recursive domainspecifica- tions wetrytoregardallequations suchas(1)or
(2)
and(3)
aboveas beingoftheform(4) X F(X),
whereXrangesovertheobjectsof acategory
K,
say, andF:K
Kis anendofunctor of thatcategory. For example, in the case of(1)
we could take X torange over the objects ofK,
At to be a fixed object ofK,
and+
and to be covariant sum andfunction-space functorsover
K;
thenF"
K Kis definedby"At+ (X X).
(5) F(X)def
Let us spell the meaning of
(5)
out in detail. Recall that if Fi:KKi
(i-1,r/) are functors then their tuplingF (El,Fn): K- K1 "
x K, is defined by puttingforeach object,
X,
ofK:
F(X)
(FI(X),Fn (X))
andfor eachmorphism
f: X
YofK:F(f (F,(f
), F,(f )).
Then the functorFdefinedby(5)is just
F + (KAt, --
o(idm idI))where
KAt
:K-Kis the constantly-At functor andidI
:K-.Kis the identity functor.Simultaneous equations are handled usingproduct categories. For example,
(2)
and(3)
canberegardedas having the form:(6)
X Fo(X,Y),(7)
YF
(X, Y),where
X,
Y rangeover acategoryK (suchasCL)
andF0
andF
are bifunctors over Kbeing definedbyX
o<KAt
7rl>,F
defF1 +o<K,,
Xo<’rro, 7’/’1>>
def
where
At,
1 are objects ofK,
and the 7ri"K xK-K
(i=0,1)
are the projection functors. Then(2)
and(3)
are put into the form(4)
by using the product categoryK
xKand takingF
tobe(Fo,F).
Clearlythisideaworksfor n simultaneousequationsXi
=Fi(X1, ,X,)(i 1,n)whereXirangesoverKi (i 1, n)andFi:K
x...xK,K;
weLetjust takeus now decide what a solution toK
tobeKx " K,
andF(4)
tomightbe(Fx,
be and’,F,).whichparticular ones we want. In the case where K is a partial order, F is then just a monotonic function, solutions are just fixed points ofF (that is, elementsA of K such thatA
=F(A)), and we can look forleastsolutions. Further,we candefineprefixedpoints as elementsA
such that F(A)A, and it turns out that the least prefixed point, if it exists, is always the least fixed point as well. In the categorical case we need to know the isomorphism as well asthe object:DEFINITION 1. Let
K
be a category andF:
K- K be an endofunctor. Then afixed
point of F is a pair (A,c)
whereA
is an object of K anda’FA
-A is anisomorphism of
K;
aprefixedpoint is a pair (A,a)
where A is an object of K anda:FA A
is amorphismofK.We also call prefixed points of
F,
F-algebras (same as F-dynamic of Arbib andManes [4]).
The F-algebrasarethe objectsof acategory:DEFINITION 2. Let (A, a) and
(A’, a’)
be F-algebras.A
morphismf:
(A,a)-
(A’, ’)
(F-homomorphism) isjustamorphismf’A -A’
inKsuch that the following commutes:764 M.B. SMYTH AND G. D. PLOTKIN
FA A
FA’ A’
It is easily verified that thisgives a category: the identity and composition are both inherited from
K.
Following on the above remarks on partial orders, we look for initialF-algebras rather than justinitial fixed points ofF and this isjustified by the following lemma(whichalsoappearsin Arbib[5],
andinBarr[8],
whereit is credited toLambek).LEMMA 1. The initialF-algebra,
if
it exists, isalso theinitialfixed
point.Proof.
Let (A, a) be the initial F-algebra. We only have to prove that a is an isomorphism. Now as (A,a)
is an F-algebra so is (FA,Fa)
and so there is an F-is anhomomorphismF-homomorphism andf:
(A,a so(FA, Fa );aof:
(A,onea)also(A, a)easilyis alsosees thatoneaand it must be(FA, Fa-
(A,idA,a)
the identity onA
as (A,a)
is initial. Then asf:
(A,a)-(FA, Fa)
we also have foa=(Fa)o(Ff)=F(aof)=F(idA)=idFA, which shows that a is an isomorphism with two-sided inversefi
Notethat we have to do morethan specifyanobject
A
such thatA -F(A)
when lookingfortheinitial fixedpoint. First wehave tospecifyanisomorphisma"FA -A,
and secondly we must establishthe initiality property. Both are vital in applications.When giving the semantics of programming languages using recursively specified domainsthe isomorphism is needed justto be able tomake thedefinitions. Initiality is closely connnected to structural induction principles and both can be used for makingproofs about elementsofthe
specited
domains.When the equationsareused tospecifydata-typedefinitions within alanguage followingtheapproachinLehmann and Smyth[19], [20],
the isomorphism carries the basic operations, and initiality is again essential forproofs. (The paper[20]
also contains more information on simul- taneousequationsand onequationswithparameters; inmany ways,itis acompanion to the presentpaper.)WhenKis apartialorder,theleastfixedpointcan,asiswellknown, be constructed as
IIKFn(_L),
the 1.u.b. of the increasing sequence(F"(_k)),,o
where _L is the least element ofK. Thisworksiftheleast elementexists, the1.u.b. exists andFpreserves the1.u.b.that is,F(IIK
F(+/-)) IlK F(F
(+/-)).Our
basiclemmamerelygeneralizes these remarks tothecase of acategory.First we give some notation and terminology which are not quite standard.
By
anto-chainin acategoryKweunderstandadiagramof theformA
Do o Da .
(thatis, afunctorfrom toto K); for m
=<
n, we writef,,,
:D,, D, forthe morphism f,_ao.., of,,. Dually an toP-chain in a category K is a diagram of the form A=Do ro D r
(thatis,afunctor fromtooo
toK);form->n
wehave theevident f,,, :D,, D,. By the mediating morphism between alimiting (colimiting)/x over a diagram A and any othercone u overA,
we mustunderstand the unique morphism given by universalityfrom(to)
thevertex of u to (from) thevertexofNotation. The initialobjectof acategory
K
is writtenas_t_iandthe uniquearrow from it to an objectA is written as _LA. If ADo o D1 ""
is an to-chain in Kand/x:
A- A
is acone overA,
then A- is the to-chainD1 ’ D2
_f2...and-:
A-A
is the cone
(/X,+l)n,o;
if, further,F:K-L
is a functor, then FA is the to-chainFDo -Fr FD1 _rr,
andFtx FA-FA
isthe coneNowgiven afunctorF"
K--> K
we candefine the to-chainA (F"
(+/-i),F"
(+/-F_l_)) (if +/-iexists)and trytojustify the calculationanalogoustothat for partial orders"Flim A lim
FA
lim A- limA.
Thebasic lemma gives conditionsfor this towork and characterizes lim_.
A
(with an appropriate morphism)as theinitialF-algebra.LEMMA2(basiclemma). LetKbea categorywith initial
obfect
+/-andletF"K-->K
bea
functor. Define
the to-chain A tobe(F"
(1),F" (+/-F+/-)). Suppose
thatboth Ix"A-->A
andFix" FA--> FA
are colimitingcones. Then the initialF-algebraexists andis (A,a)
wherea"FA
-->A
is the mediating morphismfrom Fix
toix-.
Proof.
Leta"FA’-->A’
be any F-algebra. We show there is a unique F- homomorphismf:
(A,a)-->(A’,a’).
First supposef
is such ahomomorphism. Define aconeu’A->A’
by puttingvo=+/-A, +/-A’
and v,+l=a’oF(v,). Tosee v is acone weprove byinduction on n thatthefollowing diagramcommutes.Fn(+/-.+/-)
F"(+/-) Fn+l(+/-)
vn+1
oF"+l(+/-+/-)
This is clear for n 0. For n
+
1 we have: v,+2=a’oF(v,+loF"(+/-l.))=a’oF(v,)
(by induction assumption) v,+l Now the uniqueness off
willfollow when we show it isthe mediating morphism fromix tov;here we use induction on n to show v,
f
Ix,. This is clear for n 0. For n+
1 wehave’foix,+l=fOaoF(ix,) (by the definition of
a)=a’oF(f)oF(ix,) (f
isahomomorphism)
a’ F (f
ix,)a’
v, (byinductionassumption)Secondly, toshowthat
f
exists, letitbe the mediating morphismfromix tov(so
that v,
fo
ix, forall integers,n)where v isdefinedas above.Wewillshow thatf
oaand
a’o Ff
are both mediating arrows fromFix
tov-,
thus demonstrating that they areequal and thatf
is anF-homomorphismasrequired.In
the first case, (foa)oFix,=fOixn+
(by definition of a)’--/n+X (by definition off).
In the second case,(a’oFf)oFix,=a’oF(foix,)=a’oFv,
(by definition off)
v,+ (bydefinitionofv).
Thisconcludestheproof.Inthe case ofpartialorders,ourmethodofconstructing least fixed-points always works if K is an w-complete partial order and
F" K--> K
is o-continuous. Here an w-completepointed partial order(cpo)isapartial orderwhichhas1.u.b.s ofallincreasing w-sequencesand whichhasaleastelement;itistermedan"w-complete partial order"orevenjusta"complete partial order" elsewhere. AlsoafunctionF’ K-->Lofpartial ordersis w-continuous ifandonlyif it is monotonicand preserves 1.u.b.sofincreasing to-sequences,that is,ifwhenever
(x,),,o
is anincreasing w-sequence such that exists, thenF(I It:
x,)IIc
F(x,). Wemakeanalogousdefinitions forcategories"DEFINITION 3.
A
category,K,
is ano-completepointedcategory (shortenedbelow toto-category) ifandonlyif ithasan initialelement,and everyco-chainhas acolimit.DEFINITION 4. Let
F"
K--> L be a functor. It is w-continuous if and only if it preserves o-colimits; that is, wheneverA
is anto-chain and g"A- A
is a colimiting766 M.B. SMYTH AND G. D. PLOTKIN
cone, then
Fix :FA FA
is also a colimiting cone. (The reader is warned that this definition is dual to the notion of continuity of functors usual in category theory (MacLane[21]);
thisisdoneinorderto maintaintheanalogywithpartialorders.)
Clearly, when K is an to-category and
F"
K K is to-continuous,the conditions of the basic lemma are satisfied. In 3 we will give the conditions for this to be the case. Inthesequelto thispaper(see
alsoPlotkinandSmyth[28]),
wewill showthat, inthe presenceof a universalobject, theconditions ofthebasiclemmamay besatisfied withoutrequiringthat Kbe anto-category and thatF be to-continuous. Usually, we can completely avoid direct verification of the conditions of the basic lemma, or of whether somethingis an to-category or is to-continuous. Of coursesometimes, as in thecase ofSet,
it isalreadyknown that wehaveanto-category andthatsuch functors as+
and are to-continuous(seeLehmann andSmyth[20]).
Onecase in whichthere is, so far, no alternative to direct verification is with Lehmann’s category, Dora of smallto-categories andto-continuousfunctors[18]
(inthiscaseDora-categories might provideagood general setting).Note thatit is only necessarytocheck that thebasic categoriesare to-categories and the basic functors are to-continuous; one easily proves that any denumerable product of to-categories is an to-category, that all constant and projection functors are to-continuous, and that composition and tupling preserve to-continuity. Thus to solve
(1)
one only needsto checkthat+
and are to-continuous; for(2)
and (3)one looksat+
and.
The originalwork onmodelsofthe pureA-calculus
(Scott [34],
Wadsworth[42])
did notsolve
(4)
as lim_.(F"(_I_), Fn(IF+/-)),
but rather as lim_,(F’(D), F"(’n’))
for an objectD and a morphism"n"D
F(D). Itturns out that this solution is, essentially, the initial fixedpointof a functorF=,
derived fromF,
overthe commacategory(D SK)
of "objectsoverD"
(see
MacLane[21]).
The analogousidea inpartial ordersis that of aleastfixedpoint greaterthan some fixedelement, d.The commacategory
(D,K)
has as objects pairs (A, d) whereA
is an objectofK
andd:DA;
the morphismsf:(A,d)(A’, d’)
are the morphismsf:A A’
ofK
such that the following diagramcommutes.
D
d )AA’
Now the endofunctor
F,:(D$N)-(D,I,K)
can be obtained by putting F(A,d)=(FA, (Fd)or) for objects and
F,(/) =F(/)
for morphisms. Then one can see that an F,-algebra is a pair ((A, d),)
whereA
is an object ofK,
and d’DA
and:FA A
and the following diagramcommutes.D
, F(D). , F(A)
A
homomorphism’:
((A, d),)-
((A’, d’),’)
is amorphism’: A A’
suchthat thefollowingtwo diagramscommute.
F(A)
A D
aA
F(A’) A’ A’
Let us assume, for simplicity, that K is an to-category and F is to-continuous.
Then
(DSK)
is also anto-category. Its initialobjectis (D, idD). For colimitssuppose A=((An,d),f,)
is an t-chain inDSK.
Then it is straightforward to check that/z
(A, f)-
A is a (colimiting) cone in Kifandonlyif/z:A(A,/xo
do) isin(D K)
(and they have the same mediating morphisms). This makes it easy to show thatF
isto-continuous.
Now,
applying the basic lemma to(D K)
andF,
we have to find a colimiting cone Ix"(F
(+/-),F (+/-F=(I)))->
(A, d). One sees,by induction on n, thatF (+/-(DI))
is(F"(D),d,)
whered =F-l(Tr) .o’:DF(D)
and thatF(LF(+/-))=Fn(’a’).
So from the above remarks one can take to be a colimiting cone,
/x:(F"(D), F" (zr)) A,
alsodefiningA,
and put d=/x0od0.
Then, by the basic lemma, theinitial F-algebra is ((A, d), a) where a is the mediating morphism fromF/x to/x-
(which can be taken in K). Thus we see thatA
=lim_.(F"(D), F"(r)),
together with its colimiting cone, determines the initial F-algebra. Thus we have characterized the originalinverse limit construction inuniversal terms.3. O-categories. In most of the categories used for the denotational semantics ofprogramminglanguages, thehom-sets have anatural partialorder structure. When solvingrecursive domainequationsonlythe projectionsareconsidered, and they are easily defined in terms of the partial order.
Wand [44]
introduced O-categories to study such categories at asuitably abstract level.We nowpresentaview of hiswork as providing theorems and definitions which facilitate the application of the basic lemma, asoutlined intheintroduction.DEFINITION 5.
A
category,K,
is anO-category
if and onlyif (i) every hom-set is apartial orderin whicheveryascendingto-sequencehasa1.u.b. and(ii)composition ofmorphismsis an to-continuousoperation with respecttothis partial order.Note that if Kis an
O-category,
so is K,
and ifL is another so isK L.
Herethe orders are inherited, and inthe case ofKpwe have
fop___ gop
if andonly iff
g,foranymorphisms
f
and gofK (ingeneralwewill omitthe superscript when writing morphismsinopposite categories).As
ithappens O-categoriesare aparticularcaseofageneraltheoryofV-categories whereVis anyclosedcategory (MacLane[21]);
hereOisthe category whose objects arethose partial orderswith1.u.b.s of all increasingto-sequencesand whose morphisms are the to-continuous functions between the partial orders.We
will not use any of the general theory but just take over the idea of endowing the morphismsets with extra structuremin this case thatofbeinganobjectinO.
DEFINITION 6. LetK beanO-category andlet
A rB
gA be arrowssuch that gof idA
andfog___idB. Then we saythat(f,
g) is aprojectionpairfrom A
toB, thatg is a projection and that
f
is anembedding.LEMMA 3. Let
(f,
g) and(f’,
g’) both be profection pairsfrom A
toB,
in anO-category
K. Thenf _ f’ if
andonlyif
g_ g’.
Proof.
Iff_f’
then g_gof’og’_gofog’=g’. Conversely, ifg_g’
thenf=
fog’of’_fogof’_f’. V!
768 M. B. SMYTH AND G. D. PLOTKIN
So,
inparticular,itfollowsthat onehalf ofaprojection pairdetermines theother;if
f
is an embeddingwewritefR
for the corresponding projection which we call the rightadfoint
of;
if g is a projection wewritegL
for the corresponding embedding which wecalltheleft
ad]oint of g. (Ouruse of theterm "adjoint" isonly a matterof convenience; whentheK-objectsareposets andthemorphisms aremonotonicmaps, itagreeswith astandardusage.)Givenany
O-category K
wecan now formthe subcategory,KE,
of the embeddings.For the identity morphism
idA’A-->A
is an embedding withida=idA,
and ifA fB-)f’c
are embeddings, so is(f’ of)
with(f’of)
R"--fRf ’R.
Equally, we canform K
P,
the subcategoryof theprojections. Wedo nottry totakeeither ofthese as O-categories under theinducedordering;indeedthey are, in general,notO-categories.3.1. Duality for O-categories. Ourdiscussion ofadjointsshowsthatwehave the dualityKE
(KP)
p (andso tooKp(KE)P).
There is anotherkind ofduality arising from the fact that an embedding inK
p is just a projection inK.
Thus(KP)
E KP (andso(KO)
PKZ).
Thusan to-chain in(KP)
zcanbeconsideredasantoP-chainin KP,
and acolimitingcone in(KP)
E canbe identified with a limiting cone inK e.
Wetherefore have thefollowing dualities (foran
O-category K):
embedding/projection, to-chain inKZ/0oP-chain
inK P,
colimiting coneinKZ/limiting
cone inK P. A
further example, O-colimit/O-limit,isprovidedbyDefinition7.Theseobservations will beusedin theproofofTheorem2.
Ourfirst theorem is trivialbut does illustrate theidea of transferring properties from Kto
K E.
THEOREM 1. Let K be an
O-category
which has a terminal obfect,z,
and in which every hom(A, B) has a least element, +/-A,U. Suppose too that composition isleft-strict
in the sense thatfor
any[:A-
B we have+/-.cof
+/-A.O Then +/- is the initial objectProof.
First,of
K.
iff,f"
+/-A
areboth embeddings,then they have acommonright adjoint,as +/-is terminal inK,
and so, byLemma3,theyareequal.Second, -t-.+/-.A’+/-A
is an embedding with right adjoint +/-A.+/-. For .J_A,+/-_L+/-,A’_[_"-)_L must be id+/- the uniquemapfrom _1_to+/- and +/-_.A +/-A.+/- [A,A (by left-strictness)_idA.
To make the connection with the basic lemma, we need to be able to relate O-notions (expressed in terms ofthe ordering of
hom-sets)
to to-notions (expressed in terms oftoP-limits/to-colimits).
Thisis the main purpose of Theorem 2. Another way to view this result, exemplified further in the ensuing discussion, is that it is concernedwiththecorrespondence betweenlocal properties(thatis, propertieslocal to particular hom-sets) and global properties of the category. Yet another way to regard Theorem 2is to notethatit containsthemostcomplete and generalformulation of the limit-colimit coincidence, remarked in Scott[33],
that we have been able to develop.DEFINITION 7. Let
K
be anO-category and/x"
AA
acone inK ,
where A istheto-chain
(A,, f, ).
Then isanO-colimitof Aprovided that(/x,
o/x,R),
is increasing with respect to the ordering of hom(A,A)
and I1,,/x,o/x,idA.
Dually an O-limit of an toP-chainF
inKP is acone u’B- F
in Ksuchthat ou,), isincreasing and II,u
u,idB.
Obviously,/x is anO-colimit of
A
if R is anO-limitofA R,
wherewe defineA
R R
to be
(A,, f,n) and/x
tobe(tz,
THEOREM2. Let Kbean
O-category
and A bean to-chain in K.
Considerthesix properties
(a) A
hasacolimitinK,
(b) ARhasalimitin
K,
(c) Ahasan O-colimit, (d) ARhasan O-limit, (e)A
hasacolimitin KE,
(f)
A
RhasalimitinK P.
We have" properties (a)-(d) are equivalent (to each other);
(a)
implies (e); and(e)
is equivalentto (f). Indeed,acone" A->A (a
conev’A
-->A R)
iscolimiting (limiting)inK
if
andonlyif
I(v)
is an O-colimit (O-limit);anycolimiting (limiting)coneof A(A R)
inKisalsoacolimiting (limiting)cone
of A(A R)
inK
z(KP);
andA A
iscolimitingR K
P"
in K
if
andonlyif
islimitinginProof.
We establishPropositionsA-E
whicharejointly equivalenttothe result.We always suppose that
A
has the form(A,, f,).
Note that(’,
o,),R
is increasing for any cones’AA
and"AA’
inK,
as we have’ ,o,RPROPOSiTiON
A. If "
hA
is an O-colimit, then iscolimiting in both K andE.
Proof of
Proposition(A).
Choose acone"
hA
inK,
and suppose" A A’
is a morphismfrom to
’
(i.e.,for all n,R o,’).,
R Then isRdeterminedby:0 OoUp,.o. Lj(0 op,.)o,
’o/R
since the aboveThisproves uniqueness; for existence we can define 0 as II/, remark shows that
(’
/,R isincreasing, andcalculate:So is colimiting in
K.
For KE it onlyremains to show that if’
is actually acone in
K
then0 as defined aboveis anembedding.By
the remark above,(/z,
o/z’),,o
is increasing; toshow that 0 is an embedding, we prove thatit has the right adjoint OR L_ll. lztR
Onthe onehandwehave"
vR R vR R R
(I I/.o. )o(I I/no/z.
)=1I/.o(/z. o/.t.)o/. =U/zno/z.
=idA, onthe other handwehave"R vR R vR vR
U
]J,tn
l )o([[ia, .t )---[_]]. .t in i ].I pl, idA’. I-!Dually,wehave PropositionB:
PROPOSITIONB.
If v:A
->AR
isan O-limit, then vis limitingin bothK
and KP.
PROPOSITION C.
If
v"A->
ARis limitingin K, then each v, is aprojection and visan O-limit
of A R.
Proof of
Proposition (C). ForeachA,
we candefine a conev(’):Am
-->AR
inK
by:.,)={f..
(m<-n)," (A) ’
(m>
n).(m) R
To see that v
"
is a cone, we first check that if r_->max(m,n)
thenv
For if m<-n, thenf .R f f .R (f f
V(m);if m>
n thenf nRr f
770 M.B. SMYTH AND G. D. PLOTKIN
(fmrfnm)
Rfmr--fnRm
ln(m) Nowwesee that v(")is acone, asfollows:Vn+l
(f(n+l)rfmr)
(bytheabove with r max(m,n+ 1)) (f(n+X)rOfn)
Rfmr =fnRrfmr
v.(m) (bytheabove).
Now as v"
A -
AR is alimitingconethere is, foreach m, amediating morphism(m) (m)
O,.
"A,. A
fromv tov. Sowehavefor all rn andn"v. O.. v..
Puttingn equal to m we find thatv.
o0,.ida..,
which ishalf the proof that v,. is a projection withL
Next we connect up the O,.’s by showing that
O..
O,./of. which holds since 0,.+1of,. mediatesbetweenv")and v as canbe seenfrom:(re+l) +1)
v.o(O.,+lof.)
v, of,., (Om+lmediatesbetweenv"
and v)(withr max
(m + 1. n)) f nRr fmr
Vn(m)This, in turn, enables us to show that
(O,.ov.,),,o
is increasing: O.,ovm=O.,+lof.,ofov,.+l=_O+loV,.+l.
Consequently, as K is anO-category,
we may define 0"A A
by" 0 =1 I.o,O,.ov. To finish the proof, we show that 0 ida (as then wealso have 0,. v.,_0 idA, completingthe proof that v,.L 0.,). This follows fromthefact that 0 mediates between v anditselfas isshownby"’rnn m_-->n mn
By
duality"PROPOSITION D.
If/:A--> A
is colimiting inK,
then each I, is an embedding, andIz is an O-colimit.PROPOSITIONE. A-->
A
iscolimitinginK if
andonlyif
iR:A - A
Rislimitingin K
P.
Proof of
Proposition E. Obvious.Thiscompletes the proofofTheorem2.
Ourfirst main use ofTheorem2willbe to establishthe evidentcorollarythat if K is an
O-category
which has alloP-limits,
then K has all 0o-colimits. The second main use concerns functors, but first a definition and another corollary prove con- venient.DEFINITION 8.
An O-category
Kis said to have locally determinedto-colimitsof
embeddings provided that, whenever
A
is an to-chain in Kand/:A- A
is a cone in K,/x
is colimitinginK ifand onlyif/
isan O-colimit.(Note
that, by Theorem 2, only halfofthe implicationcan everbe indoubt.)COROLLARY (toTheorem
2). Suppose
that theO-category
K has all toP-limits (i.e., every toP-chain in K has a limit). Then K has locallydetermined o-colimitsof
embeddings.
Proof.
Supposethat/"
AA
is colimiting inK.
Letv" A’
AR be a limit with respecttoKfor AR.
ByTheorem2,v’
isan O-limitfor AR.
Thus,v’
is anO-colimit forandA,
must itselfsothatbybeTheoremanO-colimit2, v(the’
ispropertycolimitingofinbeingK.
an O-colimit isHence/z
is isomorphictriviallyinvariantwithv’
under isomorphismofcones).
Byduality, the conclusion ofthe corollaryalsofollowsfromthe assumption that K has all t-colimits, but thatis not so useful. At present welack an example of an O-categorywhichdoesnothavelocally determined t-colimits of embeddings.
As
mentioned inthe Introduction, a major reason for introducingK
istoenable us toconsider contravariant functors on K as covariant ones onK "
the remainderof this section develops the idea.
We
consider throughout (thatis, to the endof the section) three O-categoriesK, L, M
and a covariant functorT: KP
LM.
Purely covariant functors are included by suppressingK
(i.e., taking it to be the trivial one-objectcategory), contravariantonesbysuppressingL,
and mixed onesby taking K andLtobeproduct categories as required.DEFINITION9. The functor
T
is locally monotonic ifand onlyif it is monotonic on the horn-sets; that is, forf,f"A
-B in Kp,
g,g"CD
inL,
iff_f’
andg_g’,
then
T (f,
g)_ T (f’,
g’).LEMMA 4.
If
Tis locally monotonic, a covariantfunctor
TK
L- M
canbe
defined
by putting,for
objectsA, B’TZ(A,B)=T(A,B)
andfor
morphismsf,g"
T
E(f,
g)=T((fR) r’,
g).Proof.
First iff:A -
B inKE andg"C- D
inLE,
thenT(f R,
g)is an embeddingwith right adjoint
T(f, gR)
as"T(f, g)Ro T(fR,
g)=T(fR of, gRog)
T(iaA,iac)idT.c)
and also:T(fR,
g)oT(f,gR)=T(fofR, gogR)_T(idmidD)
(by local monotonicity) idrCn.o).Secondly, TE(idA, idc)=
T(id,
idc)=T(idA, idc)=idrg.c).Thirdlyif
A -rA’-’ A’
inK
EandB -gB’g’B"
inLE thenTE(f ’,
g’)TE (f,
g)=T(f ’,
g’)oT(fn,
g)=T(fRof ’R, g’
og)T((f’of) R, g’
og)=T(f of, g’og).
Undersomeassumptionson
K
andL,
we cantransferalocal continuity property ofT
tothe to-continuity ofT E.
DEFINITION10. The functor
T
islocallycontinuous(equivalently,is anO-functor) ifandonlyif it is to-continuousonthe hom-setsthatis, iff,"A -
B is anincreasingto-sequenceNote that the constantin
K
pandg"C-
and projection functorsDis one inL,
thenT
(,aref,, II,locally continuous, and thatg,II,
,oT(f,,
g,).the locally continuous functors are closed under composition, tupling and taking opposite functors.
THEOREM 3. Suppose T is locally continuous and both
K
and L have locally determined to-colimitsof
embeddings. ThenT isto-continuous.Proof.
LetA ((A.,
B.),(f.,
g.)) be an to-chain inK
Ex LE andlet/x" A - (A, B)
be colimiting, where tz (try,
-.)..
Then(r.)" (A., f.)- A
is colimiting in K and(z.)" (B.,
g.)-B is colimiting in Lz.
It follows by the assumptions on K andL thatR R
withthe right-hand sides increasing.
idA
IItr.oct, andid
II-.
We
havetoshow thatT
E(/z)" T
E(A) T
E(A,B)
is acolimitingcone inM E,
which wedoby showingthat it is an O-limit (andthen applying Theorem2).
First(TE(la.,,)oTE(lx,,)R),,., (T(o-. R,
-,,)o T(tr.R, (T(o’R,
r,,) T(o’,,,"r,,R)),,
R R
(T(cr.
oct.,r.o.r.
772 M.B. SMYTH AND G. D. PLOTKIN R
R and
(z. oz.
).,o are andas T islocallymonotonic.which isincreasing as
(r. or.
)..,Next,
R R
T
z(tz.)o
Tz(l..)
R II T(o’.oo..,"r.o7..T O’nO’n, [[ Tn’l
(bytheabove)
(bylocalcontinuity) T(idA, ida) (bytheabove)
idT(A,a). 1-1
4. Examples. In this section we present several useful O-categories where our general theory can be applied. In generalwe only sketch proofs andeven omitthem Whentheyareeitherevidentor notdirectly relevanttothemain line ofthe argument (butforExample2, see
[22]).
The firstexample iselementary, beinglittle morethan an illustrationofthe ideas. The secondexampleis the categoryofcposwhere all the needed domains for denotational semantics can be constructed. This is an approach where as few axioms as possible are imposed. That makes the axioms very easy to understand but admits domains of little computational interest. The third example illustrates various completeness conditions that are weaker than Scott’s original requirement of complete lattices, which rules out some natural and useful domains.Thefourthexampleconsiders axioms ofalgebraicity and continuitywhichattempt to forcethedomains tobecomputationally realistic.Oneuse ofthecompletenessaxioms (cf. Example 3) is that when combined with algebraicity (or continuity), function spaces exist although they need not otherwise do so. Example 5 turnsin a different direction, suggestinga certaincategoryof continuousalgebrasasanappropriateplace for the semantics of programming languages with nondeterministic constructs.
Example 6considers acategory ofrelationsovercpos whereitispossibletoconstruct awidevarietyofrecursively specified relations; these are usefulwhenrelatingdifferent semantics.
Example 1. Partial
functions. We
considerthe categoryPin of setsand the partial functionsbetween them. The partial order relation between partial functionsis just setinclusionand canalsobe definedfor anyf,g:A
B byf=_g---Va
A.f(a), f(a)=
g(a)(where
f(a)$
means thatf(a)
is defined). Clearly limits of increasing to-sequences(f,),
existbeing just theset-unionUf,
so that (1f)(a)=
bundefined
(:in f,
(a
b),(qn.
f (a)
isundefined).Itiseasyto see that
f: A -
B is anembeddingifand onlyif it is totaland one-to-one;in that case
fR =f-1.
Thus to within isomorphism, embeddings are just inclusions.Notethatthe totally undefined function
:A
B is theleast elementof hom(A,B) and that composition is left strict in the sense of Theorem 1. The empty set is the terminalobject, the unique mapping being A andsotheconditionsof Theorem 1 apply, and we see that is the initial objectin Pfnz (and of course thatis trivial anyway).Turningtoto-colimits inPfn
,
it isobviousthatthey exist, asto-chains A(A., f.)
are,towithinisomorphism, just increasing sequencesAo _ A _. ,
and soA t_JA.
is the colimiting objectwith the colimiting cone of inclusions/z,,
"A,
GA.
This also follows from Theorem 2, since Pfn has toP-limits. These are constructed as inSet:
let A
(A,, fn)
be antoP-chain; putA {a
1-IA,ltn.a,, =/n (a,+l)}
anddefine v,:A A,
tobethe "nthprojection"aan.
ThenA
isthelimitofA
and v isthe colimiting cone.Turningtofunctors,wedefine theCartesian productonmorphisms
f:A A’
andg:B
B’
by:(f
xg)(a, b)=(fa,
gb (iff(a)
andg(b),),
undefined (otherwise).
This makes the Cartesian product locally continuous and so, by Theorem 3, to- continuous. Amusingly, thecategorical product exists but is different from Cartesian product and is not even locally monotonic. On the other hand, the categorical sum exists and islocallycontinuous. Onobjects it is disjoint union"
A +
B({0}
xA)CI ({
1}
xB) and formorphismsf:A -A’
andg:B B’,
(O, f(a)) (f +
g)(c(1,
g(b))
undefined
(]a
A.c (0, a)
andf(a)),
(]b B.c =(1, b) andg(b)+),
(otherwise).Finally, there is a naturalfunction-spaceconstruction definedby A B=hom(A,B),
and for
f: A’ A
andg:BB’
(f
-->g)(h go.hof.
This is not even locally monotonic, and so Theorem 3 does not apply. This is as expected, as the recursive domain equation
(1)
cannot have solutions in Pin (for nontrivial At) by evident cardinality considerations. For another example of an elementaryO-category,
the readercan consider thecategory Rei ofbinary relations betweensets,withthe subsetorderingon relations.Example 2. Completepartial orders. Weconsider the category CPO (essentially introduced in 2) of complete partial orders and to-continuous functions. It is an
O-category
when we define the order between morphismsf,g:A
B in the natural pointwisefashionfg
----ta
A.f(a)_g(a).Limits ofincreasingto-sequencesofmorphismsare definedpointwise. Theconditions ofTheorem 1 aresatisfied,asthetrivialone-point partialorder is the terminalobject and any given hom(A,B)has least element a
-
+/-B andcompositionisleft-strict.Turning to to-limits (to apply Theorem 3), let A
=(A, f,)
be an to-chain and construct u"A A as in the case of Pintakingthepartial orderonA
componentwise sothat foranya,a’
inA.a=_a’=-
tn
a,=_a’n.
This makes A a cpo with least upper bounds of increasing to-sequences, taken componentwise
la(n=(a. )
774 M.B. SMYTH AND G. D. PLOTKIN
andwith leastelement
(I
I,=>,,fn,,(_t_a. )).
Further v is acone of continuous functions and itis limiting, as ifv" A’-> A
is any other, then if 0 is a mediating morphismwe have, for all n, thatO(a’),, v’,, (a’),
determining0 as a continuousfunction. Thuswe have sketched the proofthatCPOhasalloP-limits.Turning to functors, we have categorical product and function space functors.
Theproductof two cpos
A
andB is their Cartesianproductwiththe componentwise ordering; it is easily verified to be the categorical product. Its action on morphismsf: A
-->A’
andg:B-->B’
isalsodefined asusual:(f
x g)(a,b(fa,
gb).
Clearly, productislocallycontinuous.The function-space functorhasthesame(formal) definition as in Pfn; however, this time it iseasilyseen to be locallymonotonic and, indeed, continuous. The function-space functor is the categorical one and CPO is Cartesianclosed.
Unfortunately, CPO does not have categorical sums. It is therefore better to consider the category CPO_ of cpos and strict continuous functions (where for any cpos A and B a function
f:A
B is strict iff(+/-A)=
+/-B). Thishas acategorical sum which isdefined oncposA
andB by puttingA
+B[{0}
x(A\{_I_})] U [{1}
x(B\{+/-})] LI {+/-},
with thepartial orderdefinedby
c=_c’
=-[a, a’
ea.a=_a’^
c(0, a) ^ c’= (0, a’)]
v[=lb,
b’B.bGb’^c=(1,
b)^c’=(1, b’)]
VC=/
In otherwords,
A +
B is thecoalesced sum,that is, it is the disjoint union ofA
andB,
but with least elements identified. The action of sum on morphisms turns out to begiven by puttingforf:A A’
and g:BB’
/ (0, f(a))
(:iaA .f(a)
#_1_^
c(0,
a)),
(f +g)(c)=i(l’ (otherwise),(ZlbB’g(b)+/-^c=(l’b))’
and this shows that the sum is a locally continuous functor. Now we know that
+
and, for example
E
are covariant t-continuous bifunctors onCPO
andCPO
Erespectively. Luckilyhoweverthese latter categoriesarethesame,asboth embeddings and projections inCPOare strict.
(To
see thisletf:A
B be anembeddinginCPO.
Then
f(L)Gf(fR(L))G+/-
andsof(+/-)=
2; alsofR(+/-)=fn(f(+/-))=
_k.).In the same vein we can considerthe smashproduct
A
(R)B in CPO+/- defined as{(a,
b)A
xB[a
#+/-=-
b#+/-}
with the componentwise ordering inherited from the productA
xB (which happens also to be the categorical product in CPO+/-). On morphismsf:A
(f(R)g)(a,- A’
andb)=f:B - (f(a), B’
theg(b))functoracts asfollows:(_t_, _t_)
(if
f(a)
+/- andg(b) +/-), (otherwise).Thisdefinitionshows thatthe smashproductislocallycontinuous.Itcanbe character- izedcategorically. Say thata function
f" A
x B C ofcpos is bistrict ifandonlyif for any b in B, we havef(+/-,
b)=+/- (left-strictness) and also for any a inA
we have f(a, +/-) +/-(right-strictness). Then theevident bistrict function (R):A
B A(R)B isthe universal bistrict continuous functionfromA
B inCPO_.Thestrictfunction-space functor is defined as before (formally) butthis time in CPO+/- and we denote itby-.. It also is easily seen to be locally continuous.
From
a categorical point of view (see
[21]),
smash product makes CPO+/- a symmetric monoidal category. Further,as wehaveanatural bijectionhom(A(R)B, C)horn(A, B
-.
C),CPO.
is even a closed category. This to some extent repairs the fact that it is not Cartesianclosed and explainstheappearanceofthe smashproduct.Finallywe note auseful functor
(.).:
CPOCPO.
calledlifting. For anycpoD, (D) _ ({0}
D)13_t_,with thepartial order definedforanyd, d’ in(D)by:
dd’=(::lc,
c’ D.cTc’
^d=(O,c) ^d’=(O,c’))vd=_l_.Onmorphisms
f:D -
E(f)_(d)
wehaveforJ (0, f(c))
any d in(D).
(if d (0, c)),_1_ (ifd=_1_).
From a categorical point of view, lifting is the left adjoint to the forgetful functor from CPO+/- to
CPO.
We now have a wide variety ofcovariant continuous functors over CPOz= CPO;
Lehmann and Smyth discuss many of their uses in[20].
What ismore,allofthemarisenaturally fromacategorical pointof view.It
doesnotappeartobeusefultouseOitself(a
variant ofReynolds’predomains[32])
asOz has no initialobject. (Toseethis, supposetothe contrarythatD
isinitial.Thenthereis anembedding
f:
D- ,
andwemusttherefore haveD ;
butclearly is not initial, as there is no embedding g:.- X
for any nonemptyX.)
On the other hand, one often sees an alternative definition of cpo where it is assumed that alldirected setshave 1.u.b.s rather than just increasingto-sequences.(A
subsetX
of a partial order P is directed if it is nonempty and any two elements ofX
have an upper bound inX.)
Let us call these partial orders dcpos (directed complete partial orders). Oneeasily adaptsthe above discussion to this case. Which definition totake is not a choice ofgreat significance. Onthe onehand, the restriction toto-sequences gives alarger category and is alsocomputationally natural, as theyarisewhen taking leastfixedpoints;ontheotherhand thedirectedsetsarenatural mathematically. The followingfact showsthedifference is essentiallyone ofcardinality.FACT 1.a.
A
partial order with a least element is a cpoif
and onlyif
it has alll.u.b.s
of
countable directedsets.b.
A function f: A
Bbetween cpos isto-continuousif
andonlyif
itpreservesall l.u.b.s
of
countabledirectedsets.Proof.
First note that for any countable directed setX
there is an increasing sequence(x,),,o
of elementsofX such thatanyelement ofXis less than somex,.Then we have
IIX
IIx,, and part a easily follows. For part b, supposef:A-B
isto-continuousand letX
_ A bedirected. With(x,),,,
asabove, wecalculate
xX
andthis finishes theproof,as the other direction is immediate. [3
Another way to look at these matters was discussed by Markowsky
[22],
who noted that a partial order is a dcpo if and only if it has 1.u.b.s of all(well-ordered)
776 M.B. SMYTH AND G. D. PLOTKIN
chains, and a functionbetweendcpos preserves all1.u.b.s ofdirectedsets ifand only if itpreserves all1.u.b.sof(well-ordered) chains.
Example 3. Completeness. Weconsidersome full subcategoriesof CPOdefined by imposingvariouscompletenessconditions.
DEFINITION 11. Let D be a partial order. A subset,
X,
ofD is K-consistent if and onlyifwhenever Y_
X andY[I < ,
Y hasanupper boundinD.Any
subset,X,
of a nonempty partial order is 0-, 1- and 2-consistent; it is 3-consistent if and only if it is pairwise consistent in the sense that any pair of its elements has anupper bound inD;
it is to-consistent if and only ifany finitesubset of its elements has an upper bound inD. Clearly if <_-’ then every’-
consistentsubset is also to-consistent; clearly too, anydirectedsubsetis to-consistent.
DEFINITION 12.
A
partial order,D,
is -complete if and onlyif it is nonempty and every-consistentsubsethasaleastupper bound.It follows from the above remarksthat if <-_
’,
then every -complete partial order is’-complete; also everyto-complete partial orderis acpo (andeven adcpo).Clearly for0_-<n
<
3 the n-complete partial orders arethe complete lattices and the 3-complete partial orders are the coherent cpos, in the sense of[24], [29]
and, essentially,[11].
We now see that a partial order is to-complete if and only if it is consistentlycompleteinthesense of[29], [36]
and, essentially,[11], [24].
FACT 2. LetDbe apartial order. Itisto-complete
if
andonlyif
it is a dcpo withl.u.b.s
of
all subsets withupper boundsinD.Proof.
LetD beto-complete. Wehave already noted thatitjs adcpo. Also any subsetwithanupper boundinD is to-consistentandsohas aleast upper bound.Withthe conversehypotheses,letXbeanto-consistentsubset. Then everyfinite subset has an upper bound inX and so has a least upper bound. The set of such 1.u.b.sisthen directedandso must itselfhavea1.u.b. which is alsothe 1.u.b.ofX.
Turning to the properties of the full subcategory of -complete partial orders, we see that Theorem 1 may be applied, as the one-point cpo is a complete lattice.
To see that toP-limits exist, let A
(A,, f,)
be an to-chain and definev:A-.
A as before.As
this defines a limiting cone inCPO,
it only remains to show thatA
is -complete. The proof employsan idea ofScott,
forthecase of completelattices(we
have already employedittoshowthat
A
has a leastelement).FACT 3.
A
isK-complete.Proof.
Suppose XA
is K-consistent. Thenfor every m, so is{x,lx X},
and then the leastupper boundofXis(I
l,,__> f,n(I {X,,IX X}))n,o.
So the category of embeddings is a full subcategory of CPOE with the same colimitingcones of o-chains. It follows that any to-continuousfunctors over
CPO
Ewhichpreserveto-completenesscutdownto to-continuousfunctorsonthesubcategory.
Thisremark appliestoallthe functorsdiscussed inExample 2 except thesumfunctor, which only preserves K-completeness for K
=>
3. Sums of lattices can be defined by adding a new top element or by equating top elements as in[34], [30],
and can be dealtwith bylocal continuity. General completeness concepts have been considered in[3];
itwould beinterestingto see howtheyfit intothe presentconsiderations. One approach to handling nondeterminism and concurrency is to use one of several available powerdomain functors. These are available over CPO(see [15]),
and the Smyth powerdomain[37]
is available overtheto-complete cpos.However,
thePlotkin powerdomain[27]
doesnotpreserveto-completeness;avery weaknotion ofcomplete- ness wasneeded,leadingtothe so-calledSFPobjects (brieflyconsidered in 5).Example 4. Continuity and algebraicity. Nowweconsider theto-continuous and the to-algebraic cpos. Our main definitions
(13
and15)
are formulated entirely in"countable" terms, but we pause to show that one could just as well start from definitions(14and 16)formulatedwithoutany countabilityrestrictions.
DEFINITION 13. LetD be acpo. The countable way-below (=relativecompact- ness) relation is definedby: x <<y if and onlyif forevery countable directedsubset ZofD,
ifym_llZthenxm_zforsomezinZ.
Acountable subset, B, ofD is an to-basis ofD ifand onlyif forevery element x ofD theset
Bo,(x)=aCf{b Blb<<,ox}
is directed with1.u.b.x.ThecpoD is to-continuous ifand onlyif ithasanto-basis.
Thisdefinition is notquite theverysimilar one considered inthecase ofcomplete latticesby Scottin
[33]
andmore generallyfordcposin[36], [23]
and several papers in[7].
DEFINITION 14. LetDbeadcpo. Theway-below(=relativecompactness)relation is defined by: x<<y if and only iffor every directed subset Z of
D,
if y_llZ theny_
z for somez inZ.A
subsetB ofD is a basis of D ifand onlyif forevery element x ofD
the set B(x)=aef{b Blb
<<x}
is directed with1.u.b.x.ThedcpoD is continuous ifand onlyif it has abasis.
To relate these two notions, we first note afew useful and easily proved facts.
In a cpo we have that x<<,oy implies
x_y
and x<<,oy---z implies x<<,oz; analogous facts with << replacing<<o
hold in a dcpo; for any elements x, y of a dcpo, if x<<y then x<< o,y.FACT. 4. Apartial order is an w-continuouscpo if and onlyif it is a continuous dcpowith acountablebasis.
Proof.
LetD be anw-continuous cpo with o-basisB. First, wesee it is adcpo.For ifX is any directedset then A
xxB(x)
is countable and directed (by the above facts), and so its 1.u.b. exists and is the 1.u.b. of X. Next we show for any elements x and y ofD
that x<<y if andon13
if x<<,oy. Suppose x<<,oy and y_lIZ whereZ is directed.Then y=_llA as before,and so for somez inZ
and a inB,o(z) we have x=_a<<z, and so x=_z. This establishes x<<y. We have already noted the converse, that x<<y implies x<<
y. ThereforeB
(x)= B(x)
for any x, and so B is a countable basis. The converse assertionthat any continuousdcpowith acountable basis is o-continuousisproved along thesame lines. !-1The w-algebraic cpos are a subclass of the w-continuous ones and can also be presentedin twoways.
DEFINITION 15. LetD be acpo.
An
elementx is o-finite(=w-compact) ifand onlyifx<<,ox. The cpoisw-algebraicifand onlyifthereis anw-basis of finiteelements.DEFINITION 16. LetD be adcpo.
An
element x isfinite
(=compact) ifand onlyif x << x.The cpoisalgebraic ifand onlyifthere isa basis of finiteelements.
One then sees thatD isano-algebraic cpo ifand only ifitis analgebraic dcpo with acountable basis of finiteelements. Alsoinany
(w-)
algebraicdcpo(cpo),there isonlyone (w-)basis,namelythe set of all(o-)finite elements.Turningtothefull subcategoryofthew-continuouscpos,wenotethatitcontains the one-point cpo, so Theorem 1 applies; however, it does not have all to-limits, and we conjecture it does not have to-colimits. The same remarks apply to the o-algebraic cpos. Fortunately, however, the embedding subcategories inherit colimitsfromCPO+/-.Weneedapreliminarylemma.
LEMMA 5a. Embeddings (in CPO) preserve the countable relative compactness relation.
b. LetEbe a cpo andBbe a countablesubset
of
E.If
x is anelementof
Eandthere is a directedsubsetC