Scholarly article on topic 'Presenting Dcpos and Dcpo Algebras'

Presenting Dcpos and Dcpo Algebras Academic research paper on "Computer and information sciences"

CC BY-NC-ND
0
0
Share paper
Keywords
{"Dcpo algebras" / "dcpo presentations" / d-topology / " μ-topology" / "coverage theorems"}

Abstract of research paper on Computer and information sciences, author of scientific article — Achim Jung, M. Andrew Moshier, Steve Vickers

Abstract Dcpos can be presented by preorders of generators and inequational relations expressed as covers. Algebraic operations on the generators (possibly with their results being ideals of generators) can be extended to the dcpo presented, provided the covers are “stable” for the operations. The resulting dcpo algebra has a natural universal characterization and satisfies all the inequational laws satisfied by the generating algebra. Applications include known “coverage theorems” from locale theory.

Academic research paper on topic "Presenting Dcpos and Dcpo Algebras"

Available online at www.sciencedirect.com

W ScienceDirect

ELSEVIER Electronic Notes in Theoretical Computer Science 218 (2008) 209-229

www.elsevier.com/locate/entcs

Presenting Dcpos and Dcpo Algebras

Achim Junga'1 M. Andrew Moshierb'2 Steve Vickersa'3

a School of Computer Science The University of Birmingham Birmingham, United Kingdom

b Department of Mathematics & Computer Science Chapman University Orange, CA, USA

Abstract

Dcpos can be presented by preorders of generators and inequational relations expressed as covers. Algebraic operations on the generators (possibly with their results being ideals of generators) can be extended to the dcpo presented, provided the covers are "stable" for the operations. The resulting dcpo algebra has a natural universal characterization and satisfies all the inequational laws satisfied by the generating algebra. Applications include known "coverage theorems" from locale theory.

Keywords: Dcpo algebras, dcpo presentations, d-topology, ^-topology, coverage theorems

1 Introduction

The importance of algebraic theories in semantics was first emphasized by Hennessy and Plotkin in [4] and more recently — in the context of "computational effects" — by Plotkin and Power, [9]. Mathematically, it necessitates the ability to construct free algebras over semantic spaces. For continuous domains, a general theory was developed by Abramsky and the first author in [1, Section 6] making use of the concept of an "abstract basis." There it was also stated that free algebras exist for the more general category DCPO; however, the construction was not concrete but reference was made to the Freyd Adjoint Functor Theorem. The results presented in this paper amend this situation and allow us to give a fairly concrete description of free dcpo algebras.

In order to give an overview of the paper we need to fix some terminology and notation. An algebraic theory is given by a set ^ of operation symbols, an arity

1 Email: A.Jung@cs.bham.ac.uk

2 Email: moshier@chapman.edu

3 Email: S.J.Vickers@cs.bham.ac.uk

1571-0661/$ - see front matter © 2008 Elsevier B.V. All rights reserved. doi:10.1016/j.entcs.2008.10.013

function a: Q ^ N, and a set E of equations. An algebra for a theory (Q, a, E) consists of a carrier set A together with maps wa : Aa(w) ^ A for each u G Q. We usually suppress the arity function and use "u" for both the operation symbol and the concrete operation on A. We call an algebra preordered if A carries a preorder E with respect to which the operations are monotone; we call it a dcpo algebra if (A; E) is a directed complete order and the operations are Scott-continuous.

We are concerned with two questions: How to define a notion of presentation for dcpo algebras, and how to compute the dcpo algebra defined by a presentation. We begin by reviewing the classical case of ordinary algebras. A presentation consists of a set G of generators and a set R of relations, expressed as equations between terms built up from generators and function symbols. It is to be understood in the context of an algebraic theory (Q ,E). For example, in the context of groups, G = {a} and R = {a o a o a = e} presents the group Z3.

In the classical case, the construction of the presented algebra is quite simple; one first generates all Q-terms starting from G and then factors this algebra by the smallest congruence containing all relations in R and all instances of equations in E. The technique works equally well for preordered algebras. Instead of factoring by the smallest congruence one equips the set of terms with the smallest preorder containing all inequational relations in R and all instances of inequations from E. In addition, one forces all operations to preserve the preorder. Note that in either case, the presented algebra is constructed from the set of all Q-terms over G.

For dcpo algebras the situation is quite different because for an ordered set to be a dcpo requires the existence of certain elements. Hence we can not hope to be able to make do with finitary terms alone. A reasonable strategy is to construct first the generated preordered algebra and then to complete the resulting preorder to a dcpo, for example by taking the ideal completion. However, at this stage further requirements could be stipulated, for example, one could require that two directed sets have the same supremum. This is indeed what is needed in applications so in addition to R we allow a set C of covers to be specified in a dcpo algebra presentation. Each cover has the form (x, S) with the intended meaning that in the presented dcpo algebra x should be below the directed supremum of S.

It is quite natural to believe that the free dcpo with respect to a set of covers can be constructed as a quotient of the ideal completion. This, however, is the wrong intuition; in the contrary, the more covers have been stipulated, the more elements may need to be added to the given preorder to turn it into an ordered structure that is both a dcpo and satisfies the covers. In general, the completion becomes a transfinite process. Once this is realized, one might then begin to worry about extending the operations to all these extra elements but our results say that (subject to a compatibility condition) the order-theoretic completion is in fact the only hurdle: not only can the operations be lifted to the completion, they will also continue to satisfy the (in)equations of the theory.

The structure of the paper follows logically from these observations. In Section 2 we study in detail the completion of a preorder with respect to a set of covers. The technique we employ is inspired by and very closely related to that of [6], but we

also include three alternative views on the construction, two of a topological nature and one that makes precise the transfinite induction alluded to above. In the next section we then show that finitary operations on the generating preordered algebra lift to the completion so that the dcpo constructed in Section 2 already yields the dcpo algebra with the required universal property. In Section 4 we show that the extended operations continue to satisfy the inequations that hold in the generating algebra. Here the topological explanations of the completion process allow for a very slick argument. In Section 5 we consider the case where the given operations return ideals rather than elements. This generalization is motivated by one of our applications and the reader may wish to skip this part on first reading. In Section 6 we exhibit a number of uses for dcpo algebra presentations, and it could be attractive to read this material before attempting the technical development in sections 2-5. Particular emphasis is placed on applications in locale theory, which is appropriate as we are drawing heavily on the techniques pioneered for this special case.

2 DCPO presentations

We first show that dcpo presentations by generators and relations do indeed present: in other words, there is a dcpo with the universal property specified in the presentation. This was essentially proved in [11, Section 2.1], using the techniques (originally used for preframes) of [6]. Our development here generalizes theirs in two ways. First, we allow the generators to form a preorder rather than a poset. Second, [11] used equational relations of the form, "directed join = directed join." We shall instead use inequational relations, of the form, "element C directed join." This is equivalent to the equational relations in the semilattice contexts of [11], but not more generally.

Definition 2.1 A dcpo presentation consists of

• a set P of generators;

• a preorder E on P;

• a subset C of P x P (P), whose elements are called covers and written a < U, subject to the requirement that U is directed with respect to (Without the directedness requirement, we shall refer to C as a cover set.)

The goal is to show that every dcpo presentation gives rise to a dcpo with the appropriate universal property.

Definition 2.2 An order preserving map f: (P; E,C) ^ D from a dcpo presentation to a dcpo D preserves covers if for all a <i U in C it is true that

f(a) EULu f (x).

Definition 2.3 A dcpo P is freely (generated by the dcpo presentation (P; £,C) if there is a map n: P ^ P that preserves covers, and every map f from P to a dcpo D that preserves covers factors through n via a unique Scott-continuous

Definition 2.4 Let (P; £,C) be a preorder with cover set. A C-ideal I is a subset of P which is downward closed and closed under all covers, to wit, U C I implies a £ I for all a < U in C.

If S is any subset of P then (S) denotes the smallest C-ideal containing S. The set of all C-ideals is denoted by C-Idl(P).

This is the same definition as in [5, Section II-2.11], however, our presenting preorder is not assumed to be a meet semilattice. Trivially, C-Idl(P) is a complete lattice as S m (S) is a closure operator on the powerset of P. Specifically, [JkeK Ik = (UkeK Ik) for any set {Ik | k £ K} of C-ideals.

Now, C-Idl(P) is not the free dcpo generated by a dcpo presentation (because it is always a complete lattice, even if P is just a finite poset and C the empty set) but it plays a crucial role in our construction. Indeed, we shall be particularly interested in C-Idl(P) as a sup-lattice (or complete join semilattice). As objects, sup-lattices and complete lattices are the same, but sup-lattice homomorphisms are only required to preserve all joins.

Proposition 2.5 Let (P, Q be a preorder and C a cover set on it. Then C-Idl(P) is the free sup-lattice generated by (P; £,C).

Proof. (From [2]) If Q is a sup-lattice and f: P m Q a monotone function that preserves covers, then define f: C-Idl(P) m Q by

f(I) = U f (p).

This is clearly monotone and satisfies f o n = f, so only the preservation of suprema needs to be shown. By monotonicity we have

f( U Ik)= U f (p) 3 U U f (p)=: x

keK peJ Ik keKpelk

For the other inequality note that f-1(|x) is downward closed by the monotonicity of f, closed under covers because these are assumed to be preserved by f, and a superset of all Ik. Hence |JkeK Ik = (UkeK Ik) C f-1(|x) and f (UkeK Ik) E x. □

We shall also need the following lemma.

Lemma 2.6 Let D be a dcpo. Then the sup-lattice X(D) of Scott closed subsets of D is the free sup-lattice over D qua dcpo.

': P ^ D: _

P...................- D

Proof. A proof was sketched in [11] but we can also apply the preceding proposition by considering the dcpo presentation (D, C,C) where C contains all covers a < U where a E |_|1U in D. Then the set of C-ideals coincides with the set of Scott-closed subsets, and any monotone function f: D ^ E which preserves covers is in fact Scott-continuous. □

Note that for a constructive treatment we must define "Scott closed" to mean down-closed and closed under directed joins, not the complement of a Scott open.

Note also that n: D ^ C-Idl(D) = £(D) takes each a £ D to the corresponding principal ideal ja, and therefore is an order embedding. In the following we denote it by j, rather than n.

To return to the task of determining the dcpo generated by a given dcpo presentation, we let P be the smallest sub-dcpo of C-Idl(P) containing all (p) for p £ P, and define n: P ^ P as p m- (p). This is order-preserving because C-ideals are lower sets. For the preservation of covers let a < U. Then

U c u x eu(x) c (UxeU(x)) = LI1xeU(x) and this contains a (and hence (a)) because C-ideals are closed under covers.

Theorem 2.7 P together with the map n: P ^ P is

dcpo(P (qua preorder) | a C U whenever a < U).

Proof. Let D be a dcpo and f: P ^ D a monotone function that preserves covers. The composite function j of: P ^ £(D) also preserves covers and hence factors via a sup-lattice homomorphism f': C-Idl(P) ^ £(D). In other words, we have the following commuting diagram

C -Idl(P)

and the idea is to pull back f' along j. For this note that the image of j is a sub-dcpo of X(D) and since f' preserves suprema, Xf := f/-1(j(D)) is a sub-dcpo of C-Idl(P). Because the diagram commutes, n(P) is a subset of Xf and then the same is true for P. If follows that f/ can be restricted to P giving us a Scott-continuous map f// from P to j(D) c E(D). Since j(D) is order-isomorphic to D, f := j-1 o f// is a Scott-continuous map from P to D with f = f o n.

This is unique because if we had two such maps then their equalizer would be a sub-dcpo of P that includes P and hence equal to P. □

It is worthwhile to point out that this result generalizes the usual ideal completion of a preorder, which is obtained by letting the set of covers be empty. Similarly to the ideal completion it is true in the general case that although the empty set is always a C-ideal, it is never a member of P.

We conclude this section with the following result which will turn out to be the crucial ingredient in our study of dcpo algebra presentations.

Proposition 2.8 Let (P^, £,Ci), i = 1,...,n, be a finite family of dcpo presentations. Then ni Pi is the smallest sub-dcpo o^Yli C-Idl(P^) containing i n(Pi).

Proof. Certainly Hi Pi is a sub-dcpo of ni C-Idl(Pi) that includes nin(Pi). Now suppose D is any such sub-dcpo. Suppose for some i (0 < i < n) we have

n(Pi) x ••• x n(Pi) x Pi+i x ••• x P„ C D.

This is certainly true for i = n. Let S = {a £ Pi | n(P1) x ••• x n(Pi-1) x {a} x Pi+i x ••• x Pn C D}. S is a sub-dcpo of Pi that includes n(Pi), and hence is the whole of Pi. We deduce that ) x ••• x n(Pi-1) x Pi x ••• x Pn C D, and it follows by induction on n — i that ni Pi C D. □

Since the transition from P to P (with respect to a set C of covers) is the main operation in this paper, we give three alternative descriptions.

The d-topology

Consider the d-topology on a dcpo having sub-dcpos as its closed sets.4 Then obviously P is just the d-closure of the image n(P) in C-Idl(P). The two noteworthy properties of the d-topology are that it is Hausdorff on any dcpo (as any set of the form jx is open and closed), and that a map between dcpos is Scott-continuous if and only if it is d-continuous and order-preserving.

The ¡-topology

Recall Keye Martin's ¡-topology of a dcpo, generated by the subbasic open sets jx fl O with O a Scott-open subset, [7, Chapter 3]. Alternatively, 1 is the join of the lower Alexandrov and the Scott topologies. 5 Like the d-topology, it is guaranteed to be Hausdorff on any dcpo, and for the same reason: every set of the form jx is open and closed. Scott-continuous functions are also ¡-continuous; for the converse one needs to require monotonicity in addition to ¡-continuity to get Scott-continuity, [7, Prop. 3.2.1].

Proposition 2.9 The smallest sub-dcpo P of a subset P of a dcpo D is contained in the ¡-closure of P. Furthermore, for every element x £ P and Scott-open set O containing x there exists x' £ P with x' £ O and x' E x.

Proof. For the supremum of a directed set A to belong to a subbasic ¡-open set jx If O, all elements of A must be below x. Because O is Scott-open, some element of A must meet it and this element will then be in jxlfO. This shows that D\( jxlfO) is a sub-dcpo of D, and hence that P belongs to the ¡-closure of P. □

4 This appears to have been considered first by Oswald Wyler in [12].

5 Martin's original definition was for continuous domains. In [8] it is defined for arbitrary posets as the topology generated by the Scott-open and the Scott-closed subsets but the result is the same.

The two need not be the same, even when the ambient dcpo D is continuous:

Example 2.10 Let D be the powerset of N. For the elements of P choose the set of A, i £ N where A = N \ {i}. These are pairwise incomparable, so the dcpo closure of P is P itself. On the other hand, every ^-neighbourhood of N, the largest element of PN, contains a subset f F with F a finite set. Clearly, f F contains almost all A, so N is in the ^-closure of P.

Iterated ideal completion

For every preorder P we have the ideal completion Idl(P) consisting of directed lower sets of P. It is the free dcpo over P. Given a dcpo presentation (P; £,C) we have the order-preserving map n: P ^ C-Idl(P) which therefore factors through the ideal completion Idl(P): n = LILet's call the image Pi. It is not necessarily a sub-dcpo of C-Idl(P) but the process can be repeated: the inclusion of P1 into C-Idl(P) extends to a continuous map from Idl(P1) to C-Idl(P). The image of this we call P2. And so on. At a limit ordinal A we set P\ := Ua<A Pa. Eventually this sequence stabilizes at P.

Each of these descriptions is useful in its own way but we must leave open the general problem of finding an intrinsic characterization of those subsets of P that are elements of P.

3 Operations

For (P; £,C) a dcpo presentation, we now show how a monotone operation on P can be lifted to a Scott-continuous operation on the presented dcpo P. As one may suspect, this will require a compatibility condition between the operation and the set of covers.

So let u: Pn ^ P be an n-ary monotone operation on the preorder P. We say that C is stable for u (or simply u-stable) if for every 1 < i < n, ai < U in C, and a1,...,ai-1,ai+1,...,an £ P, the cover u(a1,...,an) < {u(a1,...,ai-1, x, ai+1,...,an) | x £ U} is also in C. All our results require stability and so from now on this is always assumed even if it is not explicitly stated.

The operation can be lifted to subsets in the obvious, pointwise fashion: For A C P (1 < i < n) set

u(A1,...,An) := {u(a1,...,an) | a¿ £ A}.

Lifting it to C-ideals requires the application of the associated closure operator: if Ii £ C-Idl(P) (1 < i < n) set

ü(Í1,...,/n) := ({u(a1 ,...,an) | ai £ Ii}).

Proposition 3.1 For any a1,...,ai-1,ai+1,...,an £ P and T C P the following holds

u(a1 ,...,ai_1, (T),ai+1 ,...,an) C (u(a1 ,...,ai_1,T,ai+1,...,an)).

Proof. Let us write S for the right-hand side above, and let

T' = {x G P | w(ai,...,ai_i,x,ai+i,...,an) G S}.

By definition of S, we have T C T'. We show that T' is a C-ideal. Suppose a < U is a cover in C and U C T'. By stability, w(a1,...,ai-1,a, ai+1,...,an) < w(a1,...,ai-1,U, ai+1 , ...,an), and since the right-hand side belongs to the C -ideal S, so does the left-hand side. It follows that a G T' and therefore (T) C T'. □

Proposition 3.2 As a function from C-Idl(P)n to C-Idl(P), u preserves all joins in each argument.

Proof. Clearly, u is monotone. Fixing some i, we must show

E |J u(11,...,JA ,...,1n).

Let us write K for the right-hand side. Then we must show

u(/1,...,L_|Ja ,...,/n) C K: A

in other words, if, for each j = i, we have aj G Ij, then

u(a1,...,[_| Ja ,...,an) C K. A

Putting T = (Ja Ja in Proposition 3.1, we have

u(a1 ,...,[J Ja ,...,an) C (u(a1,..., ^ JA,...,an))

= ^ u(a1 ,...,JA,...,an)) A

Since K is a C-ideal and trivially for each A,

u(a1,...,JA,...,an) C u(/1,...,JA,...,/n) C K.

we have

^u(a1,...,JA,...,an)) C K A

which completes the argument. □

As a corollary, u preserves all directed joins in each argument, and hence is jointly Scott continuous, and hence Scott continuous.

Lemma 3.3 If A C P (1 < i < n) then

u((A1),..., (An)) = (u(A1,...,An)).

Proof. That the right-hand side is included in the left-hand side is just monotonic-ity. For the other inclusion we apply Proposition 3.1 n times to get the chain of inequalities

u«Ai>, <A2),..., <An» C (u(Ai, <A2),..., (An))) C ... C (u(Ai,...,A)>

Applying the C-ideal closure operator to the leftmost and rightmost term gives the result. □

Corollary 3.4 The map n: P ^ C-Idl(P) is a homomorphism with respect to the operation u, in other words, if a1,...,an G P then

w(n(ai),...,n(a«)) = n(u(ai ,...,an)). Proposition 3.5 u maps P" to P.

Proof. We must show that P" C u-1(P). Since u is Scott continuous, u-1(P) is a sub-dcpo of C-Idl(P)n, and by Corollary 3.4 it includes (n(P))". Hence by Proposition 2.8 it includes P". □

Theorem 3.6 Let D be a dcpo and let ud : Dn ^ D be a continuous operation. Let further f: P ^ D be a monotone and cover preserving homomorphism with respect to u. Then the extension f: P ^ D (defined in the proof of Theorem 2.7) is also a homomorphism.

Proof. Consider the set

{(1l,...,/„) G P" | ud(f(Ii),... (In)) = 7(u(/i,...,/„))}.

This is a sub-dcpo of P" because it is the equalizer of the two Scott-continuous functions ud o 7" and f o u. It includes the image of P" under n" since

uD (7 (n(ai)),...,f (n(a"))) = uD(f (ai ),...,f (a"))

(f is a homomorphism) = f (u(ai,...,a))

= f (n(u(ai ,...,a")))

(Corollary 3.4) = f (u(n(ai),...,n(«")))

Hence it equals P". □

From a topological point of view, we can say the following about the algebra P.

The d-topology

Since a function between dcpos is Scott-continuous if and only if it is monotone and d-continuous, it then follows from Proposition 3.2 that the extended operation u is d-continuous in every argument. Although it is also jointly Scott-continuous, it need not be jointly d-continuous, however, since the d-topology on C-Idl(P)" may be weaker than the product topology. This is nevertheless sufficient for us

because a function f: Xn ^ Y that is only continuous in each argument, still satisfies f (cl(An)) C cl(f (An)) for all A C X. We apply this observation to the subalgebra n(P) of C-Idl(P) and conclude that P, the d-closure of n(P) is also a subalgebra.6

The ¡-topology

As with the d-topology, we get from Proposition 3.2 that the operation u is ¡-continuous in each argument on C-Idl(P)n. Hence the ¡-closure P of n(P) is also a subalgebra. By Proposition 2.9 it contains P.

4 Inequations

We are ready to embark on the main result of this paper, namely, that the free dcpo algebra P satisfies all inequations that are valid in the preordered algebra P. The setting is slightly more general than in the previous section: we assume we are given a dcpo presentation (P; E,C) and a signature Q of operation symbols, each of finite arity. We further assume that P is a preordered Q-algebra, which means that for every u G Q with arity n a monotone map up: Pn ^ P has been specified. (Below we will no longer distinguish between the function symbol u and the concrete operation up.) We also assume that C is stable with respect to all operations up, u G Q.

Definition 4.1 For Q a set of function symbols, an inequation is a first-order formula of the form (Vx)t1 E t2, where t1 and t2 are Q-terms whose variables all appear in the vector x.

The notion of algebra (model) for an inequational theory can be defined in any preorder-enriched category with products. For the purposes of this paper, we are interested in the categories Pre (of preorders) and dcpo.

Proposition 4.2 Let (P;E, Q) be a preordered Q algebra and C a set of covers stable for all u G Q. Let P be the dcpo algebra presented by (P; E,C) with Scott-continuous operations u (u G Q) as defined in the previous section. Then any inequation that is valid in P also holds in P.

Proof. Let (Vx)t1 E ¿2 be an inequation that is valid in P. The terms ¿1 and ¿2 define n-ary monotone operations on P, hence extend to n-ary Scott-continuous operations t1, t2 on P by Proposition 3.5. The set X of tuples a in Pn for which t1 (a) E t2(a) holds, is a sub-dcpo of Pn. It includes (n(P))n because the inequation holds in P and n is a monotone homomorphism by Corollary 3.4. By Proposition 2.8, X is the whole of Pp". □

Note that the analogous statement for the ambient algebra C-Idl(P) is false in general. An example is easily given. Let P be trivially ordered and carry a binary operation that satisfies x*x = x; let the set C of covers be empty. The set of C-ideals

6 We acknowledge the anonymous referee who pointed out a gap in our original argument.

consists of all subsets of P. Clearly, forming the product A * A of a subset A C P with more than one element may contain elements not belonging to A.

Definition 4.3 For Q a set of function symbols, an inequational theory is simply a set E of inequations over Q. A preordered algebra supporting all operations in Q is called a (Q, E)-algebra if it satisfies the inequations in E. We often abbreviate the pair (Q, E) to T.

Theorem 4.4 Let T = (Q, E) be an inequational theory and P a preordered T-algebra. Let C be a set of covers stable for all operations in Q. Then n: P ^ P makes P freely (generated as a dcpo-T-algebra that respects the T-algebra structure of P and preserves the C-covers.

Proof. That P is a dcpo-T-algebra follows from the preceding proposition. Freeness was shown in Theorem 3.6. □

The phenomenon reported in this theorem was first noted by Abramsky and Vickers for a special algebraic theory; it is the essence of their "coverage theorem" in [2]. We believe that it is the "general unifying account" that is asked for in [11, page 301]. We will examine how the various coverage theorems in the literature follow from it in Section 6 below. In the remainder of the present section we indicate how Theorem 4.4 could have been established by other means.

The d-topology

C-Idl(P) is almost a topological algebra with respect to the d-topology, except that in general the operations are only continuous in each argument. This is sufficient, however, to conclude that the inequations that hold in n(P) also hold in cl(n(P)) = P because the d-topology is Hausdorff.

The ^-topology

The ^-topology is also Hausdorff and hence the closure P of n(P) with respect to it yields a subalgebra that also satisfies the inequations holding in P but in general is larger than P. This shows that P can not be characterized as the largest extension of n(P) belonging to the same variety as P.

Iterated ideal completion

Yet another way to establish our main theorem is via the transfinite generation process described at the end of Section 2. One first shows the following result directly (rather than relying on the fact that it is the special case C = 0 in Proposition 4.2):

Proposition 4.5 An inequational law that is valid in P also holds in Idl(P).

Then it is easy to see that inequations are preserved at every stage of the trans-finite process.

220 A. Jung et al. /Electronic Notes in Theoretical Computer Science 218 (2008) 209—229

5 Extensions

The phenomenon we are reporting in this paper is very robust and can be extended in a number of ways. First of all, the restriction to single-sorted algebras was purely for the sake of expository simplicity — the results of sections 3 and 4 hold equally well in the many-sorted case. Of course, one then deals with a dcpo presentation for each sort separately.

More interesting is the case where we are given an operation that takes values in Idl(P) rather than P. This situation arises frequently in domain theory and also in the "flat site" coverage theorem at the end of this paper. We show how this case can be reduced to the standard one, so let u: Pn ^ Idl(P) be a monotone map. By setting

u'(A) := U {u(a) | a G A}

we obtain a monotone operation of the usual kind on the ordered set Idl(P). The idea is now to complete Idl(P), rather than P itself. We lift the given set C of covers to a set C' of covers on Idl(P) through the following two rules:

(a<U) G C A = |JUi in Idl(P)

-: (lift) ¿el ,

(ja < {jU}) G C (A < {Ai|i G I}) G C' (cont)

Proposition 5.1 The dcpo P presented by (Pis isomorphic to Idl(P) presented by (Idl(P); C,C").

Proof. We show that Idl(P) has the required extension property. Consider the following diagram:

i ui/m n

Idl(P) —Idl (P)

where we assume that D is a dcpo and f preserves covers. The function f' is the unique Scott-continuous map for which f = f' o j. We show that it preserves the covers in C'. For covers created by the (lift)-rule, we compute:

f '(ja) = f (a) (f preserves covers in C) E UHf (x) | x G U}

= UT{f (x) | x G jU} = UT{f'(jx) | x G jU} (f' is continuous) = f'(LI^{jx | x G jU}) = f '(jU)

Covers created by the (cont)-rule are preserved because f' is continuous. It follows that the extension f' exists and satisfies

f o (n oj) = f' o j = f

If we had another continuous map g: Idl(P) ^ D with g o (n o j) = f, then g o n would be another continuous map into D extending j and so would have to be equal to f'. (Here we are using that n is Scott-continuous, which is enforced by the covers created through the (cont)-rule.) However, g o n = f' forces g = f' by the universal property of Idl(P). □

In order to apply our theory of Section 3 we need to find a suitable requirement on C that ensures that C is u'-stable. Since u' is Scott-continuous, stability for the covers created by the (cont)-rule is automatic.

Ensuring stability for the covers created by the (lift)-rule would lead to an awkward condition on u, but luckily, the situation becomes much more malleable through the following concept:

Definition 5.2 For C a set of covers on a preorder (P; E) define the saturation sat(C) of C by the following rules:

(a < U) G C a' E a (a < U) G sat(C) jU C jU'

(inc) -(mon)

(a < U) G sat(C) (a' < U') G sat(C)

(a < U) G sat(C) Vb G U.(b < V) G sat(C)

-[trans)

(a < V) G sat(C)

It is clear that a monotone function that preserves the covers in C also preserves those in the saturation, and therefore that (P; E,C) and (P; E, sat(C)) present the same dcpo P.

Definition 5.3 Let u: P" ^ Idl(P) be a monotone operation. A set of covers C is called u-stable if whenever we have p G u(ai,..., a") and a < U belongs to C, then p < U' for some U' C u(ai,...,U,... a").

Proposition 5.4 If C is u-stable for u: P" ^ Idl(P) then sat(C') is u'-stable for u': Idl(P)" ^ Idl(P).

Proof. Let ja < {jU} be a cover in C' created by the (lift)-rule. Given any vector of directed ideals Ai,...,Ai-i,Ai+i,...,A" we need to show that

u'(Ai,..., ja, ...,A") < u'(Ai,..., jU, ...,A")

belongs to sat(C'). This will follow from (cont) and (trans) if we can show

jp < u'(Ai,..., jU, ...,A")

for every p G u'(Ai,..., ja, ...,A") = 1JafceAfc u(ai,...,a, ...,a"). However, by u-stability of C we have p < U' for some directed set U' C u(ai,...,U, ...,a") C

u'(Ai,..., jU,..., An) and the desired cover belongs to sat(C') by rules (mon), (lift), and (cont). □

To complete the translation from P to Idl(P) observe that if an inequation (Vx)t! E ¿2 is valid in P then it also holds in Idl(P). By the extension Theorem 4.4 it will then also hold in the presented dcpo-algebra Idl(P).

6 Applications

6.1 Quotients and colimits in DCPO

Given a dcpo D we may wish to force certain inequalities to hold. The results of Section 2 show how this can be done, namely by collecting the inequations into a set of covers C, but they also show that the process of forming the quotient is non-trivial; this is because the naive (preorder) quotient may contain directed sets that did not exist before.

One application of quotienting is the construction of the coequalizer in DCPO. Coproducts are just disjoint unions, so together we have a fairly concrete description of colimits in DCPO.

6.2 Free dcpo algebras

Let T be an inequational theory. One of our main results, Theorem 4.4, shows that from a T-algebra (P; in Pre, equipped with a dcpo presentation that is stable for the operations in T, the dcpo P presented is a free T-algebra in dcpo over P. In this section we shall use the result to construct, given a dcpo D, a free T-algebra over D in dcpo. In other words, we are constructing a left adjoin to the forgetful functor AlgT(dcpo) ^ dcpo. (For simplicity we are assuming here that T is single-sorted. However, the extension to many-sorted theories is easy. It will give a left adjoint to the forgetful functor AlgT(dcpo) ^ dcpoSort, where Sort is the set of sorts for T.)

Let D be a dcpo. We shall assume D is presented as P for some given dcpo presentation (P; E,C). In a sense this is unnecessary, since D has a canonical presentation in which P = D and C has a cover for every directed subset of D. However, there is some advantage in knowing how the construction can be made in terms of presentations. We proceed in a number of steps.

First, let Pt be the term algebra, the set of all terms made from elements of P and operators in T.

Second, let et be the smallest congruence preorder on Pt that includes E and satisfies the inequational laws in T. By congruence preorder, we mean a preorder with respect to which the operations are monotone. That is to say, if b et c then u(a1,...,b,... ,an) et u(a1,...,c, ...,an) for any operator u and elements a^. (Pt; et) is a T-algebra in Pre.

Third, let Ct be the smallest dcpo presentation on Pt that includes C and is stable for all the operators in T.

Theorem 6.1 Let (Pt, et,Ct) be as above. Then Pt is the free dcpoT-algebra over D.

Proof. Let E be a dcpoT-algebra, and let f : D ^ E be a continuous map. By definition of dcpo presentation, f is equivalent to a monotone, cover-preserving function f : P ^ E. This extends uniquely to a homomorphism f : Pt ^ E. The inverse image of Ee is a congruence preorder on Pt that includes E and satisfies the inequational laws in T, and it follows that 7t is monotone with respect to E^ Similarly, by considering those pairs (a, U) G Pt x PPt , with U directed, such that /r(a) E Llleu 7t(u), we see that f preserves the Ct-covers. Hence by Theorem 4.4 7t extends uniquely to a homomorphism f t : Pt ^ E. □

6.3 Coverage theorems

The content of Theorem 4.4 is that it shows that the same structure (P) can be presented by generators and relations in two different ways: either as a dcpo,

dcpo(P | a E \J U (a <i U))

or as a dcpo-T-algebra,

dcpoT(P (qua T-algebra) | a E V U (a < U)).

Presenting as a dcpo-T algebra would, other things being equal, create a larger structure since all the T-terms have to be generated. But this is compensated for by the "qua T-algebra", in effect extra relations, which constrain the newly generated terms to relate to what already exists in P.

This is the typical pattern of the "coverage theorems" known from locale theory. In fact the underlying question is seen more widely in mathematics. One example from ring theory is the basic property of ideals. If R is a ring and I an ideal, then we have

Ring(R (qua ring) | a = 0 (a G I))

= Ab(R (qua Abelian group) | a = 0 (a G I)).

The ideal property RIR C I may be seen as a "multiplication stability" of the subgroup I.

The original locale-theoretic coverage theorem is that of [5], which describes the construction of the frame of C-ideals on a site, a meet-semilattice equipped with a meet-stable coverage (not necessarily a dcpo presentation). It was also shown that the frame of C-ideals was freely generated over the semilattice, with respect to transforming covers to joins. In fact the constructions there underlie much of the present paper. However, something that was not explicit in [5] was the fact that, even without the meets structure, the set of C-ideals could be presented as a sup-lattice (complete join semilattice). This was stated and exploited in [2]. If

(S, C) is the site, then

Fr (S (qua A -semilattice) | a q\J U (a <1 U))

^ SupLat(S (qua poset) | a n\J U (a < U)),

with both isomorphic to the set of C-ideals. There are two directions in which this can be used. One is that if a frame is presented by generators and relations (in other words, it is the Lindenbaum algebra for a propositional geometric theory), then the presentation can be manipulated into site form and then the result shows how to define sup-lattice homomorphisms from the frame. This was particularly useful in the context of [2], which involved quantales and modules over them, which are sup-lattices but not frames in general. The other direction was that it shows how to generalize the coverage theorem to get presentations for structures other than frames, specifically quantales and their modules.

A specific aspect of the technique is that once the existence of the sup-lattice SupLat(S (qua poset) | a C \/ U (a < U)) is known, one can forget its concrete representation as a set of C-ideals. Its universal property as sup-lattice can be used to define meet on it as a bilinear (with respect to joins) operation, and then show that the operation gives meet with respect to the sup-lattice order. This is similar to the way in which we here extend operations from the preorder to the dcpo.

In [6] those same ideas were developed with sup-lattices replaced by preframes - a preframe is a dcpo with finite meets, binary meet distributing over directed joins. It was shown how frame presentations in a certain form could be reduced to preframe presentations. This time, the set of generators was a join-semilattice. The relations were all of the form A S < Vl A with a certain join-stability property. Again, once the presented preframe was known to exist (this was a substantial result of the paper), its frame structure could be proved from the universal properties.

[11] combines those "sup-lattice" and "preframe" coverage theorems to prove a "double" coverage theorem that relates frame presentations to dcpo presentations. In fact it is a direct corollary of our Theorem 4.4.

[11] summarizes the coverage theorems in a cubical diagram

V-SemiLat ^- DL

SupLat m- Fr

dcpo m- PreFr

Poset m- A-SemiLat

Each arrow here represents a forgetful functor that has a left adjoint, a free algebra functor. Note that some of the arrows are between finitary theories, and there are already non-trivial coverage theorems for those. However, our main Theorem, 4.4, is about dcpos and the coverage theorems for the central square.

6.3.1 Immediate applications

The following two results in [11] are immediate corollaries of Theorem 4.4. Note that [11] deals with equations: each "directed relation" is an equation between two joins of directed families. Our inequational form is normally more general, but in the case of semilattices each inequation can be expressed as an equation.

Proposition 6.2 Let P be a join semilattice and R a join-stable set of directed relations on it. Then

Sup(P (qua V -SemiLat) | R) = dcpo(P (qua poset) | R).

Proof. [11] says, "The standard technique applies." What is meant by this is that once the RHS is known to exist then its universal property can be used to define V. The task then is to show that the operation so obtained turns the RHS into a sup-lattice, and to prove the sup-lattice universal property required by the left-hand side. Our Theorem 4.4 works differently; the operation V on P extends to an operation V for the general reasons explained in Section 3, and it satisfies all inequations that V satisfies. This is enough to show that V is the sup-operation on the ordered set P, or more precisely, that A C B holds if and only if AVB = B for all C-ideals A, B e P.

Assume A C B. Then AvB C BVB = B by monotonicity and idempotence, and B C AVB holds because it holds for V on P.

Conversely, assume AVB = B. Then A C AVB = B, again using that (Vx, y)x < x V y holds in the sup-lattice P. □

Theorem 6.3 (Double Coverage Theorem) If (P, R,...) is a DL-site, then

Fr(P (qua DL) | R) ^ dcpo(P (qua poset) | R)

Proof. "DL-site" means that P is a distributive lattice and each relation in R is in the form of an equation between two joins of directed families in P. Moreover, the equation set is join- and meet-stable. Each equation can be expressed as a pair of inequations, so the whole site can be rephrased as a join- and meet-stable dcpo presentation.

The order on P is linked to the join operation as in the previous proposition, and to meet by equations. Hence the order on P is linked to V as before and also to A because the equations are preserved. □

Proposition 6.4 Let P be a meet semilattice and R a meet-stable set of directed relations on it. Then

PreFr(P (qua A -SemiLat) | R) = dcpo(P (qua poset) | R).

Proof. The proof that the order on P is given by A is analogous to the one given for V above. □

As a corollary of Proposition 6.2, we get the following. It illustrates a typical technique of expanding the generator set with operations that are preserved, and expanding the relation set to ensure stability.

Corollary 6.5 Let P be a preorder and C a coverage on it (not necessarily directed). Then

Sup(P (qua preorder) | a E \J U (a < U))

is isomorphic to

dcpo(FP (qua EL -preorder) |

B U {a} E V {B U U' | U' G FU} (B G FP, a < U)).

Here FP is the finite powerset, and the lower preorder EL is defined by A EL B if for every a G A there is some b G B with a E b.

Proof. One first shows that Sup(P (qua preorder)| a E V U (a < U)) is isomorphic to

SupLat(FP (qua U -semilattice) |

B U {a} E V {B U U' | U' G FU} (B G FP, a < U)).

This uses straightforward calculations with presentations. In one direction a maps to {a}, while in the other A maps to V A. The relations are U-stable, and then Proposition 6.2 can be applied. □

6.3.2 The standard coverage theorems

The original coverage theorem was that if (S, C) is the site, then

Ft(S (qua A -semilattice) | a E \J U (a < U))

^ SupLat(S (qua poset) | a e\J U (a < U)).

Using Corollary 6.5, the RHS can be reduced to a dcpo presentation in which the generators are FP preordered by EL. These already form a distributive lattice, with A A B = {a A b | a G A, b G B}, and this allows us to deduce by the same means that the dcpo presented can be given a frame presentation, which can then be proved isomorphic to the LHS.

[6] proves a preframe coverage theorem.

Theorem 6.6 Let S be a V-semilattice, and let R be a set of preframe relations of the form f\ A E Vle/ A Bi, where the Bis form a directed family with respect to the upper order Eu. (A Eu B if for every b G B there is some a G A with a E b.)

Suppose also that the set of relations is V-stable, in the sense that if f\ A C \J]e/ /\ Bi is in R, and x G S, then the relation

/\{x V y | y G A} E \/ie/ A{x V y | y G Bi}

is also in R. Then

Fr (S (qua V -semilattice) | R) = PreFr(S (qua poset) | R).

Proof. We have PreFr(S (qua poset) | R) = PreFr(FS (qua U = A-semilattice) | R), and FS/ is a distributive lattice. The preframe presented is in turn isomor-phic to

PreFr(FS (qua U = A-semilattice) | C U |J Aj c\J {C U |J Bij | ij G Ij}

j=i j=i

(C gFS,/\A; c\/ie/j/\Bi in R),

and the relations here are both A-stable and V-stable. We can now use Theorem 4.4 to see that

dcpo(FS (qua -preorder) | C U |J Aj C \J {C U |J Bij | ij G Ij}

j=i j=i T

(C gFS,/\A; c\/iejj /\ Bi in R) is isomorphic both to the preframe presented above and to the frame

Fr (FS (preserving U and A) | C U |J Aj C \J {C U |J B^. | ij £ Ij}

j=i j=i t

(C GFS,/\Aj c\/Bi in R) which in turn is isomorphic to Fr (S (qua V-semilattice) | R). □

6.3.3 Flat sites

We discuss here the original sup-lattice coverage theorem in a slightly generalized form.

A flat site is defined in [10] as a triple (P, E,<0) where (P, E) is a preorder and is a subset of P x PP such that if a <0 U and b E a, then b <0 V for some V C b I U. (We write A j B for (j A) n (j B), j A for the down-closure of A.) In fact, this is just re-notation for the inductively generated formal topologies

228 A. Jung et al. /Electronic Notes in Theoretical Computer Science 218 (2008) 209—229

of [3]. Each flat site presents a frame Fr(P, £,<q), defined as

Fr (P (qua preorder) | 1 C \J P

a A b c\J (a I b) a C\J U (a<Q U)).

This generalizes the [5] notion of site, though in a way that is already understood from the way Grothendieck topologies are used in topos theory. If P is a meet-semilattice then the condition on the coverage is equivalent to meet stability, and the first two relations given, together with "qua preorder", are equivalent to preservation of finite meets of P.

Theorem 6.7

Fr(P, E,<0) ^ SupLat(P (qua preorder) | a c\J U (a <i0 U)). Proof. By Corollary 6.5, the RHS in the statement is isomorphic to

dcpo(FP (qua -preorder) |

B U{a} C V {B U U' | U' e FU} (B e FP,a<0 U)).

FP is already a semilattice, with U providing a join with respect to EL. But it also has a meet operation A : FP x FP ^ Idl(FP),

A A B = {S e FP | (Vs e S)(3a e A)(36 e B)s e a I 6} = {S e FP | S A,s B}.

Extending these to operations on Idl(FP), we find they make it a distributive lattice. Notably, AA(B1 VB2) = (AaBx)v(AaB2). For if S EL A and S EL B1UB2 then we can find S = S1U S2 with Si EL Bi, and this suffices to show S e (AA B1) V (A A B2).

The coverage as it stands is obviously V-stable. However, for V-stability we shall need to extend it. By induction on n one sees that the dcpo as presented is isomorphic to

dcpo(FP (qua -preorder) |

B U {a1,...,a„} ^ {B U U' | U' e F^ Ui)}

(B e FP, n > 0,ai <0 Ui for 1 < i < n)).

This is still V-stable. For A-stability, suppose we have B U {a1,...,an} < {B U U' | U' e F(U"=1 Ui)}, deriving from B e FP and a <0 Ui. Suppose S e C A (B U {a1, ...,an}) = (C A B) V (C A {a1,...,an}), so S = S1 U S2 with S1 EL B and S2 {a1,...,an}. If S2 = {61,...,6m} then for each j we have E ai for some

i, so bj Vj Ç bj I U. Then

{B u y | V' e F(U Vj)} ç C a {B u U' | U' e FUi)} j = 1 i=1

as required for A-stability.

We can now apply Theorem 4.4 to see that this dcpo is isomorphic to

Fr(FP (qua -preorder) | V, A ,1 and 0 preserved,

B U{ai ,...,an}E V {B U U' | U' eF^ Ui)}

(B e FP, n > 0,a <o Ui for 1 < i < n)), which in turn is isomorphic to Fr(P, £,<o). □

References

[1] Abramsky, S. and A. Jung, Domain theory, in: S. Abramsky, D. M. Gabbay and T. S. E. Maibaum, editors, Semantic Structures, Handbook of Logic in Computer Science 3, Clarendon Press, 1994 pp. 1-168.

[2] Abramsky, S. and S. Vickers, Quantales, observational logic and process semantics, Mathematical Structures in Computer Science 3 (1993), pp. 161-227.

[3] Coquand, T., G. Sambin, J. Smith and S. Valentini, Inductively generated formal topologies, Annals of Pure and Applied Logic 124 (2003), pp. 71-106.

[4] Hennessy, M. C. B. and G. D. Plotkin, Full abstraction for a simple parallel programming language, in: J. Becvar, editor, Mathematical Foundations of Computer Science, Lecture Notes in Computer Science 74 (1979), pp. 108-120.

[5] Johnstone, P., "Stone Spaces," Number 3 in Cambridge Studies in Advanced Mathematics, Cambridge University Press, 1982.

[6] Johnstone, P. and S. Vickers, Preframe presentations present, in: A. Carboni, M. Pedicchio and G. Rosolini, editors, Category Theory - Proceedings, Como 1990, number 1488 in Lecture Notes in Mathematics (1991), pp. 193-212.

[7] Martin, K., "A Foundation for Computation," Ph.D. thesis, Tulane University (2000).

[8] Martin, K. and P. Panangaden, A technique for verifying measurements, in: A. Bauer and M. Mislove, editors, 24th Conference on Mathematical Foundations of Programming Semantics, Electronic Notes in Theoretical Computer Science (2008).

[9] Plotkin, G. D. and J. Power, Computational effects and operations: an overview, in: M. Escardo and A. Jung, editors, Proceedings of the Workshop on Domains VI, Electronic Notes in Theoretical Computer Science 73 (2004), pp. 149-163.

[10] Vickers, S., Compactness in locales and in formal topology, Annals of Pure and Applied Logic 137 (2006), pp. 413-438.

[11] Vickers, S. and C. Townsend, A universal characterization of the double powerlocale, Theoretical Computer Science 316 (2004), pp. 297-321.

[12] Wyler, O., Dedekind complete posets and Scott topologies, in: B. Banaschewski and R.-E. Hoffmann, editors, Continuous Lattices, Lecture Notes in Computer Science 871 (1981), pp. 384-389.