Arboreal Categories: An Axiomatic Theory of Resources
AARBOREAL CATEGORIES:AN AXIOMATIC THEORY OF RESOURCES
SAMSON ABRAMSKY AND LUCA REGGIO
Abstract.
We introduce arboreal categories , which have an intrinsicprocess structure, allowing dynamic notions such as bisimulation andback-and-forth games, and resource notions such as number of roundsof a game, to be defined. These are related to extensional or “static”structures via arboreal covers , which are resource-indexed comonadicadjunctions. These ideas are developed in a very general, axiomatic set-ting, and applied to relational structures, where the comonadic construc-tions for pebbling, Ehrenfeucht-Fra¨ıss´e and modal bisimulation gamesrecently introduced in [2, 5, 6] are recovered, showing that many of thefundamental notions of finite model theory and descriptive complexityarise from instances of arboreal covers. Introduction
In previous work ([2, 5, 6]), it has been shown how a range of modelcomparison games which play a central role in finite model theory, includingEhrenfeucht-Fra¨ıss´e, pebbling, and bisimulation games, can be captured interms of resource-indexed comonads on the category of relational structuresand homomorphisms. This was done for k -pebble games in [2], and extendedto Ehrenfeucht-Fra¨ıss´e games, and bisimulation games for the modal frag-ment, in [5]. In subsequent work, this has been further extended to games forgeneralized quantifiers [9], and for guarded fragments of first-order logic [4].An important feature of this comonadic analysis is that it leads to novelcharacterisations of important combinatorial parameters such as tree-widthand tree-depth. The coalgebras for each of these comonads correspond tocertain forms of tree decompositions of structures, with the resource indexmatching the corresponding combinatorial parameter.This leads to the question motivating the present paper:Can we capture the significant common elements of these constructions? Research supported by the EPSRC project EP/T00696X/1 “Resources and Co-Resources: a junction between categorical semantics and descriptive complexity” and bythe European Union’s Horizon 2020 research and innovation programme under the MarieSk(cid:32)lodowska-Curie grant agreement No 837724. The authors also acknowledge useful feed-back from Tom´aˇs Jakl and Dan Marsden. a r X i v : . [ c s . L O ] F e b SAMSON ABRAMSKY AND LUCA REGGIO
Our aim is to develop an elegant axiomatic account, based on clear con-ceptual principles, which will yield all these examples and more, and allowa deeper and more general understanding of resources.Conceptually, a key ingredient is the assignment of a process structure—an intensional description—to an extensional object, such as a function, aset, or a relational structure. It is this process structure, unfolding in spaceand time, to which a resource parameter can be applied, which can then betransferred to the extensional object. At the basic level of computability, thishappens when we assign a Turing machine description or a G¨odel number toa recursive function. It is then meaningful to assign a complexity measure tothe function. The same phenomenon arises in semantics: for example, thenotion of sequentiality is applicable to a process computing a higher-orderfunction. Reifying these processes in the form of game semantics led to aresolution of the famous full abstraction problem for PCF [3, 11], and to awealth of subsequent results [20].It is now becoming clear that this phenomenon is at play in the gamecomonads described in [2, 5, 6, 9, 4]. They build tree-structured covers ofa given, purely extensional relational structure. Such a tree cover will ingeneral not have the full properties of the original structure, but be a “bestapproximation” in some resource-restricted setting. More precisely, thismeans that we have an adjunction, yielding the corresponding comonad.The objects of the category where the approximations live have an intrinsictree structure, which can be captured axiomatically. The tree encodes aprocess for generating (parts of) the relational structure, to which resourcenotions can be applied.In this paper, we make this intuition precise. We introduce a notion of ar-boreal category , and show how all the examples of game comonads consideredto date arise from arboreal covers , i.e. adjunctions between extensional cat-egories of relational structures, and arboreal categories. Importantly, theseadjunctions are comonadic, and the categories of coalgebras provide a set-ting for a general notion of bisimulation, which yields a wide range of logicalequivalences in the examples. This notion refines the open maps formula-tion of bisimulation [13, 12] with the condition that the maps are pathwiseembeddings , generalizing the ideas introduced in [6]. This allows a muchwider range of logical equivalences to be captured.After some preliminaries, we shall develop the axiomatization of paths,open pathwise embeddings and bisimulations, and arboreal categories. Thenwe establish the correspondence between bisimulations and back-and-forthequivalences in the setting of arboreal categories. Next, we show how manyof the fundamental notions of finite model theory and descriptive complexityarise from instances of arboreal covers. We shall use the concrete construc-tions in finite model theory as running examples throughout. We concludeby observing that the notion of extendability , a key ingredient for Rossman-type preservation theorems [19], can be defined in this general setting. RBOREAL CATEGORIES: AN AXIOMATIC THEORY OF RESOURCES 3 Preliminaries
We shall assume familiarity with some standard notions in category the-ory. All needed background can be found in [7, 16]. All categories underconsideration are assumed to be locally small and well-powered , i.e. everyobject has a set of subobjects (as opposed to a proper class). Example 2.1.
The extensional categories of primary interest in this paperare categories of relational structures. A relational vocabulary σ is a setof relation symbols R , each with a specified positive integer arity. A σ -structure A is given by a set A , the universe of the structure, and for each R in σ with arity n , a relation R A ⊆ A n . A homomorphism h : A → B is a function h : A → B such that, for each relation symbol R of arity n in σ , for all a , . . . , a n in A , R A ( a , . . . , a n ) ⇒ R B ( h ( a ) , . . . , h ( a n )). Wewrite Struct ( σ ) for the category of σ -structures and homomorphisms. TheGaifman graph of a structure A is a graph with vertices A , such that twodistinct elements are adjacent if they both occur in some tuple (cid:126)a ∈ R A forsome relation symbol R in σ .2.1. Proper factorisation systems.
We recall the notion of weak factor-isation system in a category C . Given arrows e and m in C , we say that e has the left lifting property with respect to m , or that m has the rightlifting property with respect to e if, for every commutative square as on theleft-hand side below • •• • em • •• • edm there exists a (not necessarily unique) diagonal filler , i.e. an arrow d suchthat the right-hand diagram above commutes. If this is the case, we write e (cid:116) m . For any class H of morphisms in C , let (cid:116) H (respectively H (cid:116) ) be theclass of morphisms having the left (respectively right) lifting property withrespect to every morphism in H . Definition 2.2.
A pair of classes of morphisms ( Q , M ) in a category C is a weak factorisation system provided it satisfies the following conditions:(i) every morphism f in C can be written as f = m ◦ e with e ∈ Q and m ∈ M ;(ii) Q = (cid:116) M and M = Q (cid:116) .A proper factorisation system is a weak factorisation system ( Q , M ) such that Q ⊆ { epimorphisms } and M ⊆ { monomorphisms } . A proper factorisationsystem is stable if, for any e ∈ Q and m ∈ M , the pullback of e along m exists and belongs to Q . In the literature, the adjective stable is usually reserved for the stronger propertystating that, for every e ∈ Q , the pullback of e along any morphism exists and is in Q . SAMSON ABRAMSKY AND LUCA REGGIO
Remark 2.3.
It is easy to see that any proper factorisation system is an orthogonal factorisation system, meaning that the diagonal fillers are unique.
Example 2.4. If A is a relational structure, then for any S ⊆ A , thereis an induced substructure with universe S . The inclusion map S (cid:44) → A is an embedding , i.e. an injective homomorphism which reflects as well aspreserves relations. Any embedding m : A → B factors as
A ∼ = Im ( m ) (cid:44) → B .Taking Q to be the surjective homomorphisms and M to be the embeddingsgives a stable proper factorisation system on Struct ( σ ).Next, we state some well known properties of weak factorisation systems( cf. [10] or [18]): Lemma 2.5.
Let ( Q , M ) be a weak factorisation system in C . The followinghold:(a) Q and M are closed under compositions.(b) Q ∩ M = { isomorphisms } .(c) The pullback of an M -morphism along any morphism, if it exists, isagain in M .Moreover, if ( Q , M ) is proper, then the following hold:(e) g ◦ f ∈ Q implies g ∈ Q .(f ) g ◦ f ∈ M implies f ∈ M . Throughout this paper, we will refer to M -morphisms as embeddings anddenote them by (cid:26) . Q -morphisms will be referred to as quotients and de-noted by (cid:16) .Assume C is a category admitting a proper factorisation system ( Q , M ).In the same way as one usually defines the poset of subobjects of a givenobject X ∈ C , we can define the poset of M -subobjects of X . Given embed-dings m : S (cid:26) X and n : T (cid:26) X , let us say that m (cid:22) n provided there is amorphism i : S → T such that m = n ◦ i (note that i is necessarily an embed-ding). This yields a preorder on the class of all embeddings with codomain X . The symmetrization ∼ of (cid:22) can be characterised as follows: m ∼ n if,and only if, there exists an isomorphism i : S → T such that m = n ◦ i . Let S X be the class of ∼ -equivalence classes of embeddings with codomain X ,equipped with the natural partial order ≤ induced by (cid:22) . We shall system-atically represent a ∼ -equivalence class by any of its representatives. As C is well-powered and M ⊆ { monos } , we see that S X is a set.For any morphism f : X → Y and embedding m : S (cid:26) X , we can considerthe ( Q , M )-factorisation S (cid:16) ∃ f S (cid:26) Y of f ◦ m . This yields a monotonemap ∃ f : S X → S Y sending m to the embedding ∃ f S (cid:26) Y . Further, if( Q , M ) is stable and f is a quotient, we let f ∗ : S Y → S X be the monotonemap sending n : T (cid:26) Y to its pullback along f . It is not difficult to see that f ∗ is right adjoint to ∃ f . Lemma 2.6.
Let C be any category admitting a stable proper factorisationsystem, and let f : X → Y be any morphism in C . The following hold: RBOREAL CATEGORIES: AN AXIOMATIC THEORY OF RESOURCES 5 (a) If f is an embedding, then ∃ f : S X → S Y is an order-embedding.(b) If f is a quotient, then f ∗ : S Y → S X is an order-embedding.Proof. For item (a) note that, as f : X → Y is an embedding, ∃ f : S X → S Y sends m to f ◦ m . Let m : S (cid:26) X and m : S (cid:26) X be embeddingssuch that f ◦ m ≤ f ◦ m . Then there exists k : S → S such that f ◦ m = f ◦ m ◦ k . Because f is a monomorphism, it follows that m = m ◦ k , i.e. m ≤ m . Hence, ∃ f is an order-embedding.For item (b), it is enough to prove that ∃ f f ∗ n = n for any n : T (cid:26) Y ,for then f ∗ n ≤ f ∗ n implies n = ∃ f f ∗ n ≤ ∃ f f ∗ n = n . Consider thepullback of f along n , as displayed on the left-hand side below. f ∗ T TX Y f ∗ n (cid:121) nf f ∗ T T ∃ f f ∗ T Y n ∃ f f ∗ n Since the square on the right-hand side above commutes, there exists adiagonal filler T → ∃ f f ∗ T . Note that this diagonal filler must be both aquotient and an embedding, hence an isomorphism. Therefore, ∃ f f ∗ n = n in S Y . (cid:3) Path Categories
Paths.
Throughout this section, we fix a category C admitting a stableproper factorisation system.If ( P, ≤ ) is a poset, then C ⊆ P is a chain if it is linearly ordered. ( P, ≤ )is a forest if, for all x ∈ P , the set ↓ x := { y ∈ P | y ≤ x } is a finite chain.The height of a forest is the supremum of the cardinalities of its chains. The covering relation ≺ associated with a partial order ≤ is defined by u ≺ v ifand only if u < v and there is no w such that u < w < v . It is convenientto allow the empty forest. The roots of a forest are the minimal elements.A tree is a forest with at most one root. Morphisms of forests are mapswhich preserve roots and the covering relation. Equivalently, a monotonemap ϕ : U → V between forests is a forest morphism if, for all u ∈ U ,the restriction of ϕ yields a bijection between ↓ u and ↓ ϕ ( u ). The categoryof forests is denoted by F , and the full subcategory of trees by T . Weequip these categories with the factorisation system (surjective morphisms,injective morphisms). Definition 3.1.
An object X of C is called a path provided the poset S X is a finite chain. Paths will be denoted by P, Q, R, . . . . Example 3.2.
The paths in F and T are the finite chains, i.e. the treesconsisting of a single branch. SAMSON ABRAMSKY AND LUCA REGGIO
Example 3.3.
We define a forest-ordered σ -structure ( A , ≤ ) to be a σ -structure A with a forest order ≤ on A . A morphism of forest-ordered σ -structures f : ( A , ≤ ) → ( B , ≤ (cid:48) ) is a σ -homomorphism f : A → B that is alsoa forest morphism. This determines a category R ( σ ). We equip R ( σ ) withthe factorisation system given by (surjective morphisms, embeddings), wherean embedding is a morphism which is an embedding qua σ -homomorphism.In [6], it is shown that the categories of coalgebras for the various comon-ads studied there are given, up to isomorphism, by subcategories of R ( σ )(or minor variants thereof): • For the Ehrenfeucht-Fra¨ıss´e comonad, this is the full subcategory R E ( σ ) determined by those objects satisfying the condition (E): ad-jacent elements of the Gaifman graph of A are comparable in theforest order. For each k > R Ek ( σ ) is the full subcategory of R E ( σ )of those forest orders of height ≤ k . The objects ( A , ≤ ) of R Ek ( σ )are forest covers of A witnessing that its tree-depth is ≤ k [17]. • For the pebbling comonad, for each k > R Pk whose objects have the form ( A , ≤ , p ), where ( A , ≤ ) is a forest-ordered σ -structure, and p : A → [ k ] is a pebbling function. In addi-tion to condition (E), these structures have to satisfy the condition(P): if a is adjacent to b in the Gaifman graph of A , and a < b inthe forest order, then for all x ∈ ( a, b ], p ( a ) (cid:54) = p ( x ). It is shown in[6] that these structures are equivalent to the more familiar form oftree decomposition used to define tree-width [14]. Morphisms haveto preserve the pebbling function. • For the modal comonad, the category R Mk has as objects the non-empty tree-ordered σ -structures of height ≤ k satisfying the condi-tion (M): for x, y ∈ A , x ≺ y if and only if for some unique binaryrelation R α in σ (“transition relation”), R A α ( x, y ).The paths in each of these categories are those structures in which theorder is a finite chain. These are our key motivating examples for paths.Note that in the (multi-)modal case, ignoring propositional variables, thesecorrespond to synchronization trees consisting of a single branch, i.e. traces.The following fact is an immediate consequence of Lemma 2.6: Lemma 3.4.
Let f : X → Y be any morphism in C . The following hold:(a) If Y is a path and f is an embedding, then X is a path.(b) If X is path and f is a quotient, then Y is a path. A path embedding is an embedding P (cid:26) X whose domain is a path.Given any object X of C , we let P X be the sub-poset of S X consistingof the path embeddings. By Lemma 3.4(b), for any arrow f : X → Y , themonotone map ∃ f : S X → S Y restricts to a monotone map P f : P X → P Y, ( m : P (cid:26) X ) (cid:55)→ ( ∃ f m : ∃ f P (cid:26) Y ) . By the uniqueness of factorisations, this assignment is functorial.
RBOREAL CATEGORIES: AN AXIOMATIC THEORY OF RESOURCES 7
Path categories.Definition 3.5. A path category is a category C satisfying the followingconditions:(i) C has a stable proper factorisation system;(ii) C has all coproducts of small families of paths;(iii) for any paths P, Q, R , if a composite P → Q → R is a quotient, thenso is P → Q . Remark 3.6.
It is not difficult to see that item (iii) above is equivalent tothe following condition: For any paths
P, Q, R and morphisms P f −→ Q g −→ R, if any two of f , g , and g ◦ f are quotients, then so is the third. Thus, weshall refer to (iii) as the . Example 3.7. F and T are path categories. Coproducts of forests are givenby disjoint union. For trees, coproducts are given by smash sum, with thebottom elements identified. Since forest morphisms preserve height, we seethat F and T satisfy the 2-out-of-3 condition. Similarly, it is not difficult tosee that R ( σ ) and its subcategories mentioned in Example 3.3 are all pathcategories.Note that any path category has an initial object , obtained as thecoproduct of the empty family. Example 3.8.
Since we allow empty σ -structures, R ( σ ) has an initial ob-ject. Theorem 3.9.
Let C be a path category. Then the assignment X (cid:55)→ P X induces a functor P : C → T into the category of trees. To prove this theorem, we start by showing that each poset P X is a tree. Lemma 3.10.
Let C be a path category. For any object X of C , P X is anon-empty tree.Proof. Using Lemma 2.6(a), it is not difficult to see that the sub-poset of P X consisting of those elements that are below a given P ∈ P X is isomorphicto P P . In turn, P P ∼ = S P by Lemma 3.4(a). Since S P is a finite chain, wesee that P X is a forest. Now, let (cid:16) (cid:101) (cid:26) m X be the (quotient, embedding)factorisation of the unique morphism → X from the initial object. Weclaim that m : (cid:101) (cid:26) X is the unique root of P X .Note that is a path: just observe that any embedding S (cid:26) admitsthe unique morphism → S as a right inverse, and thus is a retraction. Itfollows that S ∼ = , i.e. , S is the one-element poset. In particular, is apath. Thus, (cid:101) is a path by Lemma 3.4(b). We show that m : (cid:101) (cid:26) X isthe least element of P X . If m (cid:48) : P (cid:26) X is any path embedding, we have a SAMSON ABRAMSKY AND LUCA REGGIO commutative square as follows. (cid:101) P X mm (cid:48) Hence there exists a diagonal filler d : (cid:101) → P , and so m ≤ m (cid:48) in P X . (cid:3) We next show that the functor P sends morphisms in a path category totree morphisms, thus completing the proof of Theorem 3.9. Proposition 3.11.
Let C be a path category. For any arrow f in C , P f isa tree morphism.Proof. It is enough to show that, for any path embedding m : P (cid:26) X , theinduced map P f : ↓ m → ↓ P f ( m ) is a bijection.We start by establishing surjectivity, i.e. ↓ P f ( m ) ⊆ P f ( ↓ m ). Let ( e, j )be the (quotient, embedding) factorisation of f ◦ m . If n : Q (cid:26) Y is apath embedding such that n ≤ P f ( m ) in P Y , there exists an embedding k : Q (cid:26) ∃ f P such that the left-hand diagram below commutes. Considerthe pullback of k along e , as displayed in the right-hand diagram below. P X Y ∃ f P Q me fj nk
R QP ∃ f P (cid:121) ke Then R is a path by Lemmas 2.5(c) and 3.4(a), and the composite i : R (cid:26) P (cid:26) X is a path embedding which is below m in the poset P P . Further,the top horizontal arrow in the pullback square is a quotient and so, by theuniqueness of factorisations, the (quotient, embedding) factorisation of f ◦ i is R (cid:16) Q (cid:26) n Y , i.e. , P f ( i ) = n .For injectivity, let m : P (cid:26) X and m : P (cid:26) X be path embeddingsin ↓ m . Since P is a path, m and m are comparable in the order of P X . Assume without loss of generality that m ≤ m , i.e. , there existsan embedding k : P (cid:26) P such that m = m ◦ k . If P f ( m ) = P f ( m ),there exists an isomorphism k (cid:48) : ∃ f P → ∃ f P making the left-hand diagrambelow commute. P ∃ f P X YP ∃ f P m k k (cid:48) fm P P ∃ f P k RBOREAL CATEGORIES: AN AXIOMATIC THEORY OF RESOURCES 9
In particular, the diagram on the right-hand side above commutes, where thetop horizontal arrow is the composition of P (cid:16) ∃ f P with the isomorphism k (cid:48) : ∃ f P → ∃ f P . By the 2-out-of-3 condition, k is an isomorphism, and so m = m in P X . (cid:3) We conclude with the following useful observation:
Lemma 3.12.
The following statements hold for any object X of a pathcategory C :(a) Any subset U ⊆ P X admits a supremum (cid:87) U in S X .(b) For any path embedding m ∈ P X and non-empty set S ⊆ S X , if m = (cid:87) S then m ∈ S .Proof. For item (a), consider a set of path embeddings U = { m i : P i (cid:26) X | i ∈ I } ⊆ P X. Let S := (cid:96) i ∈ I P i be the coproduct in C of the paths P i and consider the(quotient, embedding) factorisation of the canonical morphism δ : S → X whose component at P i is m i : S T X e δ m
Each path embedding m i ∈ U factors through m , thus m is an upper boundfor U . We claim that m is the least upper bound, i.e. , m = (cid:87) U in S X .Suppose that all path embeddings in U factor through some embedding m (cid:48) : T (cid:48) (cid:26) X . By the universal property of S , we get a morphism ϕ : S → T (cid:48) .Further, using again the universal property of S , it is not difficult to see that m (cid:48) ◦ ϕ coincides with δ , and so the following square commutes. S TT (cid:48) X ϕ e mm (cid:48) Therefore, there exists a diagonal filler T → T (cid:48) . In particular, the commut-ativity of the lower triangle entails that m ≤ m (cid:48) , as was to be proved.For item (b), let m : P (cid:26) X be a path embedding and S ⊆ S X a non-empty set such that m = (cid:87) S . Then n ≤ m for each n ∈ S . Since P is apath, ↓ m is a finite chain in S X and so S must be a finite set whose largestelement coincides with m . In particular, m ∈ S . (cid:3) Pathwise Embeddings, Open Maps, and Bisimulations
Throughout this section, we fix a category C admitting a stable properfactorisation system. Pathwise embeddings and open maps.
Following [6], let us saythat a morphism f : X → Y in C is a pathwise embedding if, for all pathembeddings m : P (cid:26) X , the composite f ◦ m is a path embedding. Hence, P f ( m ) = f ◦ m for all m ∈ P X . Following again [6], we introduce a notion ofopen map—inspired by [13]—that, combined with the concept of pathwiseembedding, will allow us to define an appropriate notion of bisimulation.A morphism f : X → Y in C is said to be open if it satisfies the followingpath-lifting property: Given any commutative square P QX Y f with P, Q paths, there exists a diagonal filler Q → X ( i.e. , an arrow Q → X making the two triangles commute). Note that, if it exists, such a diagonalfiller must be an embedding. Remark 4.1.
The previous definition of open map differs from the onegiven in [13] because we require that, in the square above, the top hori-zontal morphism and the vertical ones be embeddings. However, a pathwiseembedding is open in C (according to the definition above) if, and only if,it is open (in the sense of [13]) in the subcategory C ∗ of C having the sameobjects as C and morphisms the pathwise embeddings.For pathwise embeddings f : X → Y , openness can be characterised interms of the corresponding monotone map P f : P X → P Y : Proposition 4.2.
The following are equivalent for any pathwise embedding f : X → Y :(1) f is open.(2) P f is a p-morphism, i.e. P f ( ↑ m ) = ↑ P f ( m ) for all m ∈ P X .Proof. (1) ⇒ (2). Suppose f is open, and let m : P (cid:26) X be an arbitraryelement of P X . The inclusion P f ( ↑ m ) ⊆ ↑ P f ( m ) follows at once frommonotonicity of P f . For the converse inclusion, assume that n : Q (cid:26) Y isan element of P Y above P f ( m ) = f ◦ m . Then, the composite f ◦ m mustfactor through n , say f ◦ m = n ◦ s for some embedding s : P (cid:26) Q . Hence,we have a commutative square as displayed below. P QX Y sm nm (cid:48) f Since f is open, there exists a diagonal filler m (cid:48) : Q (cid:26) X . The commutativ-ity of the upper triangle entails that m (cid:48) ∈ ↑ m , while the commutativity ofthe lower triangle implies that P f ( m (cid:48) ) = n . Therefore, ↑ P f ( m ) ⊆ P f ( ↑ m ). RBOREAL CATEGORIES: AN AXIOMATIC THEORY OF RESOURCES 11 (2) ⇒ (1). Assume P f is a p-morphism, and consider a commutativesquare as follows, P QX Y sm nf where P and Q are paths. We have P f ( m ) ≤ n in P Y , and thus there existsa path embedding m (cid:48) : P (cid:48) (cid:26) X satisfying m ≤ m (cid:48) and P f ( m (cid:48) ) = n . Theinequality m ≤ m (cid:48) amounts to saying that m = m (cid:48) ◦ l for some embedding l : P (cid:26) P (cid:48) , while the equality P f ( m (cid:48) ) = n means that f ◦ m (cid:48) = n ◦ k forsome isomorphism k : P (cid:48) → Q . We have a commutative diagram as displayedbelow. X YP P (cid:48) Q fml s km (cid:48) n We claim that m (cid:48) ◦ k − : Q → X satisfies m (cid:48) ◦ k − ◦ s = m and f ◦ m (cid:48) ◦ k − = n ,thus showing that f is open. To start with, note that k ◦ l = s . Just observethat n ◦ k ◦ l = f ◦ m (cid:48) ◦ l = f ◦ m = n ◦ s, and so k ◦ l = s because n is a monomorphism. Now, by diagram chasingwe see that m (cid:48) ◦ k − ◦ s = m (cid:48) ◦ k − ◦ k ◦ l = m (cid:48) ◦ l = m and f ◦ m (cid:48) ◦ k − = n ◦ k ◦ k − = n . This concludes the proof. (cid:3) Bisimulations. A bisimulation between objects X, Y of C is a span ofopen pathwise embeddings X ← Z → Y in C . If such a bisimulation exists, we say that X and Y are bisimilar . Example 4.3.
This definition directly generalizes that in [6], and the no-tions of bisimulation given there for the Ehrenfeucht-Fra¨ıss´e, pebbling andmodal comonads are the special cases arising in the categories R Ek ( σ ), R Pk ( σ )and R Mk ( σ ) respectively, as described in Example 3.3. Remark 4.4.
Let C be a path category. If we regard trees as Kripke mod-els where the accessibility relation is the tree order, then it follows fromTheorem 3.9 and Proposition 4.2 that a span of pathwise embeddings X Z Y f g in C is a bisimulation if, and only if, P X P f ←−− P Z P g −−→ P Y is a bisimulationof Kripke models in the usual sense. Given a bisimulation X ← Z → Y , we would like to think of Z asproviding a winning strategy for Duplicator in an appropriate game played“between X and Y ”. To substantiate this idea, in Sections 5 and 6 we intro-duce arboreal categories —a refinement of the concept of path category—andshow that, in these categories, bisimilarity is captured by back-and forth sys-tems which model the dynamic nature of games.5. Arboreal Categories
By Theorem 3.9, any path category C admits a functor P : C → T intothe category of trees. In general, the tree P X may retain little informationabout X . We are interested in the case where X is determined by P X . Thisleads us to the notion of path-generated object.5.1. Path-generated objects.
Let C be a path category. For any object X of C , we have a diagram with vertex X consisting of all path embeddingswith codomain X : XP Q
The morphisms between paths are those which make the obvious trianglescommute. Choosing representatives in an appropriate way, this can be seenas a cocone over the small diagram P X . We say that X is path-generated provided this is a colimit cocone in C .Let C p be the full subcategory of C defined by the paths and recall thata functor J : A → B is dense if every b ∈ B is the colimit of the diagram J ↓ b A B , π J where J ↓ b is the comma category and π is the natural forgetful functor. Wehave the following straightforward observation: Lemma 5.1.
The following are equivalent for any path category C :(1) Every object of C is path-generated.(2) The inclusion C p (cid:44) → C is dense.Proof. The equivalence of items 1 and 2 in the statement follows essentiallyfrom the following observations (the details are left to the reader): In a pathcategory C , any arrow P → X whose domain is a path factors through apath embedding P (cid:48) (cid:26) X (just take the (quotient, embedding) factorisationof P → X and use Lemma 3.4(b)). Further, given any commutative triangleas on the left-hand side below, with P, Q paths, there is a commutativediagram as displayed on the right-hand side.
RBOREAL CATEGORIES: AN AXIOMATIC THEORY OF RESOURCES 13
XP Q XP (cid:48) Q (cid:48) P Q
To deduce the existence of the embedding P (cid:48) (cid:26) Q (cid:48) , consider the commut-ative square P P (cid:48) Q (cid:48) X where the left vertical morphism is given by the composition P → Q (cid:16) Q (cid:48) .Then there exists a diagonal filler P (cid:48) (cid:26) Q (cid:48) . (cid:3) Arboreal categories.
We now state the axioms for an arboreal cat-egory. To this end, recall that an object a of a category A is said to be connected if the functor hom A ( a, − ) : A → Set preserves all coproducts ex-isting in A (in particular, any arrow from a into a coproduct of objects mustfactor through some coproduct injection). Further, a is rigid if the onlyisomorphism a → a is the identity. Definition 5.2. An arboreal category is a path category C satisfying thefollowing conditions:(i) every object of C is path-generated;(ii) every path in C is connected and rigid. Example 5.3.
The category T of trees is arboreal; this is essentially theobservation that (i) every tree is the colimit of the diagram given by itsbranches and the embeddings between them, and (ii) finite chains are con-nected and rigid in T . Similarly, F is arboreal. Our key examples of thecategories R Ek ( σ ), R Pk ( σ ) and R Mk ( σ ) from Example 3.3 are also arboreal.Note that, in view of Theorem 3.9, any arboreal category C admits afunctor P : C → T into the category of trees. This crucial fact is what willallow us, given an arboreal cover ( cf. Section 7), to regard process structuresas tree-like objects.We collect some useful consequences of the axioms above.
Lemma 5.4.
Let C be an arboreal category. The following statements hold:(a) Between any two paths there is at most one embedding.(b) For any object X of C and any m ∈ S X , m = (cid:87) { p ∈ P X | p ≤ m } .(c) If f is a quotient in C , then P f is a surjection.Proof. For item (a), let f, g : P ⇒ Q be embeddings between paths. Becausethere is at most one morphism of forests between any two chains, it must be P f = P g . Thus, f = P f (id P ) = P g (id P ) = g in P Q . That is, there is anisomorphism j : P → P such that f = g ◦ j . Since P is rigid, we get f = g .For item (b), let m : S (cid:26) X be an arbitrary embedding. Clearly, wehave (cid:87) { p ∈ P X | p ≤ m } ≤ m . For the converse direction, assume that n : T (cid:26) X is an upper bound for { p ∈ P X | p ≤ m } . This means that eachpath embedding P (cid:26) X that factors through m must factor through n . Wethen have a commutative diagram as displayed below. TSP i P jγ Because S is path-generated, the cocone with vertex S is a colimit cocone.Therefore, there exists a unique mediating arrow γ : S → T making thediagram commute. Using the universal property of S , it is not difficult tosee that the composite S γ −→ T (cid:26) n X coincides with m , and so m ≤ n .For item (c), suppose that f : X (cid:16) P is a quotient in C . In order to settlethe statement, it suffices to prove that id P ∈ P f ( P X ), where id P : P → P is the identity. We have f ∗ id P = (cid:95) { p ∈ P X | p ≤ f ∗ id P } by item (b)= (cid:95) { p ∈ P X | ∃ f p ≤ id P } since ∃ f (cid:97) f ∗ = (cid:95) P X, and so (using the fact that left adjoints preserve suprema)id P = ∃ f f ∗ id P = (cid:95) P f ( P X ) , where the first step follows from the fact that ∃ f ◦ f ∗ is the identity of S P ( cf. the proof of Lemma 2.6(b)). It follows by Lemma 3.12(b) thatid P ∈ P f ( P X ). (cid:3) Let X be an object of an arboreal category. If U is any subset of P X ,and n : (cid:87) U (cid:26) X is its supremum in S X , then the downward closure of U is contained in P ( (cid:87) U ) (where we identify P ( (cid:87) U ) with its image under theorder-embedding P n : P ( (cid:87) U ) → P X ). The next proposition shows that,in fact, P ( (cid:87) U ) is equal to the downward closure of U . This will allow usto construct an object from a prescribed set of path embeddings, withoutadding any new paths in the process. Proposition 5.5.
Let C be an arboreal category, X an object of C , and U ⊆ P X . A path embedding m ∈ P X is below (cid:87) U if, and only if, it isbelow some element of U . RBOREAL CATEGORIES: AN AXIOMATIC THEORY OF RESOURCES 15
Proof.
Fix an arbitrary object X of C and a set of path embeddings U = { m i : P i (cid:26) X | i ∈ I } . Let m : P (cid:26) X be an arbitrary path embedding.If m is below some element of U , then clearly m ≤ (cid:87) U . For the conversedirection, suppose that m ≤ (cid:87) U . Recall from the proof of Lemma 3.12(a)that the supremum of U is obtained by taking the (quotient, embedding)factorisation (cid:96) i ∈ I P i e −→→ S (cid:26) n X of the canonical morphism (cid:96) i ∈ I P i → X .With this notation, (cid:87) U = n . Since m ≤ (cid:87) U , there exists an embedding m (cid:48) : P (cid:26) S such that m = n ◦ m (cid:48) . Consider the pullback of m (cid:48) along e : T P (cid:96) i ∈ I P i S j r (cid:121) m (cid:48) e Applying Lemma 5.4(c) to the quotient r , we see that there exists a pathembedding k : Q (cid:26) T such that r ◦ k is a quotient. Because Q is connected, j ◦ k : Q (cid:26) (cid:96) i ∈ I P i must factor through some coproduct injection ϕ i : P i → (cid:96) i ∈ I P i , i.e. , j ◦ k = ϕ i ◦ p for some path embedding p : Q (cid:26) P . We thenhave a commutative diagram as follows. Q PP i S X r ◦ kp m (cid:48) me ◦ ϕ i m i n As m ◦ r ◦ k = m i ◦ p and the right-hand side of the equation is an embedding, r ◦ k is an isomorphism. So m ≤ m i ∈ U , thus concluding the proof. (cid:3) Back-and-Forth Systems and Games
Throughout this section, we work in a fixed arboreal category C . First,we introduce back-and-forth systems in C and show that they capture pre-cisely the bisimilarity relation defined in Section 4 in terms of spans of openpathwise embeddings. Then, we show that back-and-forth systems can beequivalently seen as appropriate back-and-forth games.6.1. Back-and-forth systems.
Given objects X and Y of C , we considerspans of (equivalence classes of) path embeddings of the form X (cid:27) m P (cid:26) n Y .Such a span can be thought of as a partial isomorphism “of shape P ” between X and Y . A back-and-forth system between X and Y is a collection of suchspans containing an “initial element” and satisfying an appropriate extensionproperty.Let X, Y be any two objects of C . Given m ∈ P X and n ∈ P Y , wewrite (cid:74) m, n (cid:75) to denote that dom( m ) ∼ = dom( n ). Observe that (i) any twoembeddings in the same ∼ -equivalence class have isomorphic domains, and(ii) given (cid:74) m, n (cid:75) , there exist path embeddings m (cid:48) ∼ m and n (cid:48) ∼ n such that dom( m (cid:48) ) = dom( n (cid:48) ). Hence, the pairs of the form (cid:74) m, n (cid:75) capture the partialisomorphisms X (cid:27) m P (cid:26) n Y “of shape P ”. Definition 6.1. A back-and-forth system between objects X, Y of C is aset B = { (cid:74) m i , n i (cid:75) | m i ∈ P X, n i ∈ P Y, i ∈ I } satisfying the followingconditions:(i) (cid:74) ⊥ X , ⊥ Y (cid:75) ∈ B , where ⊥ X and ⊥ Y are the least elements of P X and P Y , respectively;(ii) if (cid:74) m, n (cid:75) ∈ B and m (cid:48) ∈ P X are such that m ≺ m (cid:48) , there exists n (cid:48) ∈ P Y satisfying n ≺ n (cid:48) and (cid:74) m (cid:48) , n (cid:48) (cid:75) ∈ B ;(iii) if (cid:74) m, n (cid:75) ∈ B and n (cid:48) ∈ P Y are such that n ≺ n (cid:48) , there exists m (cid:48) ∈ P X satisfying m ≺ m (cid:48) and (cid:74) m (cid:48) , n (cid:48) (cid:75) ∈ B .A back-and-forth system is strong if, for all (cid:74) m, n (cid:75) ∈ B and all m (cid:48) ∈ P X , n (cid:48) ∈ P Y , if m (cid:48) ≺ m and n (cid:48) ≺ n then (cid:74) m (cid:48) , n (cid:48) (cid:75) ∈ B .Two objects X and Y of C are said to be (strong) back-and-forth equivalent if there exists a (strong) back-and-forth system between them. Remark 6.2.
The definition of (strong) back-and-forth system given aboveis a variant of the notion of (strong) path bisimulation from [12]. The no-menclature adopted here is motivated by the analogy with back-and-forthsystems of partial isomorphisms from model theory [15].The aim of this section is to prove the following result:
Theorem 6.3.
In any arboreal category, any two objects are bisimilar if,and only if, they are strong back-and-forth equivalent.
We start by establishing the easy direction of the previous theorem.
Proposition 6.4.
Any two bisimilar objects of an arboreal category arestrong back-and-forth equivalent.Proof.
Suppose that X f ←− Z g −→ Y is a span of open pathwise embeddingsin an arboreal category C . We claim that B := { (cid:74) P f ( m ) , P g ( m ) (cid:75) | m ∈ P Z } is a strong back-and-forth system between X and Y . We show that items (i),(ii), and (iii) in Definition 6.1 are satisfied.For item (i), let ⊥ Z be the least element of P Z . Then P f ( ⊥ Z ) = ⊥ X and P g ( ⊥ Z ) = ⊥ Y because tree morphisms preserve roots, and so (cid:74) ⊥ X , ⊥ Y (cid:75) ∈ B .For item (ii), let (cid:74) P f ( m ) , P g ( m ) (cid:75) ∈ B and m (cid:48) ∈ P X be such that P f ( m ) ≺ m (cid:48) . Let us denote P := dom( m ) and P (cid:48) := dom( m (cid:48) ). As f ◦ m ≤ m (cid:48) in P X ,there exists k : P (cid:26) P (cid:48) such that f ◦ m = m (cid:48) ◦ k in C . Therefore, we have acommutative square as follows. P P (cid:48)
Z X km m (cid:48) f RBOREAL CATEGORIES: AN AXIOMATIC THEORY OF RESOURCES 17
Since f is open, there exists a diagonal filler n : P (cid:48) (cid:26) Z . Thus, m (cid:48) = P f ( n )and (cid:74) m (cid:48) , P g ( n ) (cid:75) ∈ B . It remains to show that P g ( m ) ≺ P g ( n ). Note that m ≤ n and P f ( m ) ≺ P f ( n ) entail m ≺ n , and so P g ( m ) ≺ P g ( n ) because P g preserves the covering relation.The proof of item (iii) is the same, mutatis mutandis, as for (ii). Finally,observe that the back-and-forth system B is strong. To see this, suppose that (cid:74) P f ( m ) , P g ( m ) (cid:75) ∈ B , and let p ∈ P X and p ∈ P Y satisfy p ≺ P f ( m )and p ≺ P g ( m ). As P f is a tree morphism, there exists m (cid:48) ∈ P Z such that m (cid:48) ≺ m and P f ( m (cid:48) ) = p . But then P g ( m (cid:48) ) ≺ P g ( m ) implies P g ( m (cid:48) ) = p ,and therefore (cid:74) p , p (cid:75) ∈ B . (cid:3) Remark 6.5.
Suppose for a moment that we define a back-and-forth systembetween X and Y to consist of spans of path embeddings X (cid:27) P (cid:26) Y ,rather than equivalence classes of such path embeddings. Then Proposi-tion 6.4 fails to hold. The reason is that, for a bisimulation X Z Y, f g the obvious candidate { X P Y f ◦ m g ◦ m | m : P (cid:26) Z is a path embedding } need not be a set, in general. Even the notion of strong back-and-forth sys-tem would be problematic, as there may be a proper class of path embed-dings with codomain P . Of course, in the usual applications the subcategoryof paths has a small skeleton, which allows to circumvent this problem.To establish the other direction of Theorem 6.3, we start by considering astrong back-and-forth system B = { (cid:74) m i , n i (cid:75) | i ∈ I } between X and Y , andattempt to construct an object Z and a span of open pathwise embeddings X ← Z → Y . Intuitively, Z is obtained by gluing together the paths P i := dom( m i ), for i ∈ I , by taking a colimit in C . This colimit can beequivalently described as the supremum of a set of path embeddings as wenow explain.Consider an arbitrary (cid:74) m i , n i (cid:75) ∈ B and assume without loss of generalitythat dom( m i ) = P i = dom( n i ) for some path P i . Then the product arrow (cid:104) m i , n i (cid:105) : P i → X × Y is an embedding. In fact, it suffices that m i be anembedding (or, symmetrically, that n i be an embedding), for then m i = π X ◦ (cid:104) m i , n i (cid:105) entails that (cid:104) m i , n i (cid:105) is an embedding, where π X : X × Y → X is the projection. Therefore, we can identify each (cid:74) m i , n i (cid:75) ∈ B with a pathembedding (cid:104) m i , n i (cid:105) ∈ P ( X × Y ) and compute the supremum m : Z (cid:26) X × Y in S ( X × Y ) of all these path embeddings. (It is not difficult to see that theassignment (cid:74) m i , n i (cid:75) (cid:55)→ (cid:104) m i , n i (cid:105) ∈ P ( X × Y ) does not depend on the choiceof the representatives in the equivalence classes of m i and n i .) We note inpassing the following immediate fact: Lemma 6.6.
Let B = { (cid:74) m i , n i (cid:75) | i ∈ I } be a back-and-forth system between X and Y . If B is strong, then {(cid:104) m i , n i (cid:105) ∈ P ( X × Y ) | i ∈ I } is downwardsclosed in S ( X × Y ) . To show that the span X π X ◦ m ←−−−− Z π Y ◦ m −−−−→ Y is a bisimulation, we exploitthe fact that Z does not admit more path embeddings than those prescribed( cf. Proposition 5.5). The following proposition then completes the proof ofTheorem 6.3:
Proposition 6.7.
If two objects of an arboreal category are strong back-and-forth equivalent, then they are bisimilar.Proof.
Let C be an arboreal category, and let X, Y be any two objects of C .Assume that there is a strong back-and-forth system B = { (cid:74) m i , n i (cid:75) | i ∈ I } between X and Y , and consider the set U := {(cid:104) m i , n i (cid:105) ∈ P ( X × Y ) | i ∈ I } . Let m : Z (cid:26) X × Y be the supremum of U in S ( X × Y ). We claim that X Z Y π Y ◦ mπ X ◦ m is a bisimulation between X and Y .To see that this is a span of pathwise embeddings, consider an arbitrarypath embedding n : P (cid:26) Z . In view of Proposition 5.5 and Lemma 6.6, m ◦ n ∈ U . That is, m ◦ n = (cid:104) m i , n i (cid:105) in P ( X × Y ) for some (cid:74) m i , n i (cid:75) ∈ B .It follows that m ◦ n = (cid:104) m i , n i (cid:105) ◦ ϕ in C for some isomorphism ϕ , and so π X ◦ m ◦ n and π Y ◦ m ◦ n are embeddings because π X ◦ m ◦ n = m i ◦ ϕ and π Y ◦ m ◦ n = n i ◦ ϕ .It remains to show that π X ◦ m and π Y ◦ m are open. We prove that π X ◦ m is open; the proof for π Y ◦ m follows by symmetry. Consider a commutativesquare in C as displayed below, where P and Q are paths. P QZ X kn m j π X ◦ m Reasoning as above, we see that m ◦ n = (cid:104) m i , n i (cid:105) in P ( X × Y ) for some (cid:74) m i , n i (cid:75) ∈ B . Therefore, in P X , we have m i = π X ◦ m ◦ n ≤ m j . Applyingitem (ii) in Definition 6.1 (possibly finitely many times), it follows thatthere exists n j ∈ P Y such that n i ≤ n j and (cid:74) m j , n j (cid:75) ∈ B . Suppose withoutloss of generality that dom( m j ) = dom( n j ). Then, (cid:104) m j , n j (cid:105) ∈ U and so (cid:104) m j , n j (cid:105) : Q (cid:26) X × Y factors through the supremum m : Z (cid:26) X × Y of U .That is, (cid:104) m j , n j (cid:105) = m ◦ h in C for some morphism h : Q → Z . We claim thatthe following diagram commutes, thus establishing that π X ◦ m is open. P QZ X kn m j hπ X ◦ m RBOREAL CATEGORIES: AN AXIOMATIC THEORY OF RESOURCES 19
For the commutativity of the lower triangle, just observe that π X ◦ m ◦ h = π X ◦ (cid:104) m j , n j (cid:105) = m j . Now, assume without loss of generality that dom( m i ) = R = dom( n i ) forsome path R . As already observed above, m ◦ n = (cid:104) m i , n i (cid:105) in P ( X × Y )implies that m ◦ n = (cid:104) m i , n i (cid:105) ◦ ϕ in C for some isomorphism ϕ : P → R .Thus, for the upper triangle, we have n = h ◦ k ⇔ m ◦ n = m ◦ h ◦ k ⇔ (cid:104) m i , n i (cid:105) ◦ ϕ = (cid:104) m j , n j (cid:105) ◦ k ⇔ (cid:40) m i ◦ ϕ = m j ◦ kn i ◦ ϕ = n j ◦ k where in the first step we used the fact that m is a monomorphism. In turn,the inequalities m i ≤ m j and n i ≤ n j entail the existence of embeddings k , k : R ⇒ Q such that m i = m j ◦ k and n i = n j ◦ k . By Lemma 5.4(a) wehave k ◦ ϕ = k = k ◦ ϕ . It follows that m i ◦ ϕ = m j ◦ k and n i ◦ ϕ = n j ◦ k ,and so n = h ◦ k . (cid:3) Back-and-forth games.
Let C be an arboreal category and let X, Y be any two objects of C . We define a back-and-forth game G ( X, Y ) playedby Spoiler and Duplicator on X and Y as follows. Positions in the game arepairs of (equivalence classes of) path embeddings ( m, n ) ∈ P X × P Y . Thewinning relation W ( X, Y ) ⊆ P X × P Y consists of the pairs ( m, n ) such thatdom( m ) ∼ = dom( n ).Let ⊥ X : P (cid:26) X and ⊥ Y : Q (cid:26) Y be the roots of P X and P Y , respect-ively. If P (cid:54)∼ = Q , then Duplicator loses the game. Otherwise, the initialposition is ( ⊥ X , ⊥ Y ). At the start of each round, the position is specified bya pair ( m, n ) ∈ P X × P Y , and the round proceeds as follows: Either Spoilerchooses some m (cid:48) (cid:31) m and Duplicator must respond with some n (cid:48) (cid:31) n , orSpoiler chooses some n (cid:48)(cid:48) (cid:31) n and Duplicator must respond with m (cid:48)(cid:48) (cid:31) m .Duplicator wins the round if they are able to respond and the new positionis in W ( X, Y ). Duplicator wins the game if they win the k -round game forevery k ≥ Lemma 6.8.
Two objects
X, Y of an arboreal category C are strong back-and-forth equivalent if, and only if, Duplicator has a winning strategy in thegame G ( X, Y ) .Proof of Lemma 6.8. Clearly, if B = { (cid:74) m i , n i (cid:75) | i ∈ I } is a strong back-and-forth system between X and Y , then the plays in the set { ( m i , n i ) | i ∈ I } ⊆ P X × P Y yield a winning strategy for Duplicator in the game G ( X, Y ). Conversely, a winning strategy for Duplicator in the game G ( X, Y ) de-termines a back-and-forth system B := { (cid:74) m, n (cid:75) | ( m, n ) ∈ W ( X, Y ) } defined by the plays following this strategy. It is not difficult to see that B is strong. (cid:3) The previous lemma, combined with Theorem 6.3, yields at once thefollowing result:
Theorem 6.9.
Let C be an arboreal category and X, Y any two objects of C .Then X, Y are bisimilar if, and only if, Duplicator has a winning strategyin the game G ( X, Y ) . Arboreal Covers
We now return to the underlying motivation for the axiomatic develop-ment in this paper. Arboreal categories have a rich intrinsic process struc-ture, which allows “dynamic” notions such as bisimulation and back-and-forth games, and resource notions such as the height of a tree, to be defined.A key idea is to relate these process notions to extensional, or “static” struc-tures. In particular, much of finite model theory and descriptive complexitycan be seen in this way.In the general setting, we have an arboreal category C , and another cat-egory E , which we think of as the extensional category. Definition 7.1. An arboreal cover of E by C is given by a comonadic ad-junction C E . LR ⊥ As for any adjunction, this induces a comonad on E . The comonad is( G, ε, δ ), where G := LR , ε is the counit of the adjunction, and δ a : LRa → LRLRa is given by δ a := L ( η Ra ), with η the unit of the adjunction. The co-monadicity condition states that the Eilenberg-Moore category of coalgebrasfor this comonad is isomorphic to C . The idea is then that we can use thearboreal category C , with its rich process structure and all the associatednotions, to study the extensional category E via the adjunction. Both theco-Kleisli category of the comonad, and the full Eilenberg-Moore category,are useful in this regard.We now bring resources into the picture. Definition 7.2.
Let C be an arboreal category, with full subcategory ofpaths C p . We say that C is resource-indexed by a resource parameter k iffor all k ≥
0, there is a full subcategory C kp of C p closed under embeddings with C p (cid:44) → C p (cid:44) → C p (cid:44) → · · · That is, for any embedding P (cid:26) Q in C with P, Q paths, if Q ∈ C kp then also P ∈ C kp . RBOREAL CATEGORIES: AN AXIOMATIC THEORY OF RESOURCES 21
This induces a corresponding tower of full subcategories C k of C , with theobjects of C k those whose cocone of path embeddings with domain in C kp isa colimit cocone in C . Example 7.3.
One resource parameter which is always available is to take C kp to be given by those paths in C whose chain of subobjects is of length ≤ k .In the case of F and T , the corresponding categories F k and T k are the forestsand trees of height at most k . We can think of this as a temporal parameter,restricting the number of sequential steps, or the number of rounds in agame. For the Ehrenfeucht-Fra¨ıss´e and modal comonads, we recover R Ek and R Mk as described in Example 3.3, corresponding to k -round versionsof the Ehrenfeucht-Fra¨ıss´e and modal bisimulation games respectively [6].However, note that for the pebbling comonad, the relevant resource index isthe number of pebbles, which is a memory restriction along a computationor play of a game. This leads to R Pk as described in Example 3.3.In Proposition 7.5 below we shall see that, given a resource-indexed ar-boreal category { C k } , each category C k is arboreal. This allows us to exploitthe ideas developed in this paper for any choice of the resource parameter k . We start by proving the following fact: Lemma 7.4.
Let { C k } be a resource-indexed arboreal category and supposethat X (cid:26) Y is an embedding in C . For any k , if Y ∈ C k then also X ∈ C k .Proof. We start by showing that, for any path embedding P (cid:26) Y in C , if Y ∈ C k then P ∈ C kp . Consider the set U := { p ∈ P Y | dom( p ) ∈ C kp } . (Note that U is well-defined because any two representatives in the equival-ence class of p have isomorphic domains, and C kp is closed under isomorph-isms.) As Y is the colimit in C of the subdiagram of P Y consisting of thosepath embeddings whose domain is in C kp , it follows that (cid:87) U = id Y in S Y . Ifthere exists a path embedding m : P (cid:26) Y , then m ≤ (cid:87) U in P Y and so, byProposition 5.5, m factors through some p ∈ U . In particular, there existsan embedding P (cid:26) dom( p ). Because dom( p ) ∈ C kp , we see that P ∈ C kp .Now, suppose that j : X (cid:26) Y is an embedding in C and Y ∈ C k . Since X is path-generated, it is the colimit in C of the small diagram P X . Weshow that, for any path embedding P (cid:26) X , the path P must belong to C kp .It then follows immediately that X ∈ C k . Let m : P (cid:26) X be an arbitrarypath embedding. The composite j ◦ m : P (cid:26) Y is also a path embedding,and so P ∈ C kp by the argument above. (cid:3) Proposition 7.5.
Let { C k } be a resource-indexed arboreal category. Then C k is an arboreal category for each k .Proof. If C is equipped with the stable proper factorisation system ( Q , M ),consider the classes of morphisms Q (cid:48) := Q ∩ C k and M (cid:48) := M ∩ C k . It is not difficult to see that ( Q (cid:48) , M (cid:48) ) is a proper factorisation system in C k . Justobserve that, whenever W → Z is a morphism in C k and W (cid:16) X (cid:26) Y is its (quotient, embedding) factorisation in C , then X ∈ C k by Lemma 7.4.Using again Lemma 7.4, along with the fact that embeddings are stable un-der pullbacks, it follows at once that ( Q (cid:48) , M (cid:48) ) is stable (and, in fact, pullbacksof Q (cid:48) -morphisms along M (cid:48) -morphisms are computed in C ). With respect tothis factorisation system, it is not difficult to see that the paths in C k areprecisely the objects of C kp .Moreover, C k has all coproducts of small families of paths, and they arecomputed in C . To see this, consider a set of paths { P i ∈ C kp | i ∈ I } and let (cid:96) i ∈ I P i be the coproduct in C . If m : P (cid:26) (cid:96) i ∈ I P i is any path embeddingin C then, because P is connected, m must factor through some coproductinjection. In particular, there exist i ∈ I and an embedding P (cid:26) P i . Since P i ∈ C kp , we get P ∈ C kp . As (cid:96) i ∈ I P i is path-generated in C , it follows atonce that (cid:96) i ∈ I P i ∈ C k . Hence, (cid:96) i ∈ I P i coincides with the coproduct of thefamily { P i ∈ C kp | i ∈ I } in C k .We conclude that C k is a path category. Further, every object of C k ispath-generated by definition, and all paths in C k are trivially rigid. Finally,paths in C k are connected because any path in C k is also a path in C and,as observed above, coproducts of paths in C k are computed in C . Therefore, C k is an arboreal category. (cid:3) Definition 7.6.
Let { C k } be a resource-indexed arboreal category. Wedefine a resource-indexed arboreal cover of E by C to be an indexed familyof comonadic adjunctions C k E L k R k ⊥ with corresponding comonads G k on E . Example 7.7.
Our key examples arise by taking the extensional category E to be Struct ( σ ). For each k ≥
0, there are evident forgetful functors L Ek : R Ek → Struct ( σ ) , L Pk : R Pk → Struct ( σ )which forget the forest order, and in the case of R Pk , also the pebblingfunction. These functors are both comonadic over Struct ( σ ). The rightadjoints build a forest over a structure A by forming sequences of elementsover the universe A , suitably labelled and with the σ -relations interpreted soas to satisfy the conditions (E) and (P) respectively. In the modal logic case,the extensional category E is the category Struct (cid:63) ( σ ) of pointed σ -structureswith morphisms the σ -homomorphisms preserving the distinguished point.There is a forgetful functor L Mk : R Mk → Struct (cid:63) ( σ ) RBOREAL CATEGORIES: AN AXIOMATIC THEORY OF RESOURCES 23 sending ( A , ≤ ) ∈ R Mk to ( A , a ), where a is the unique root of ( A , ≤ ). Thisfunctor is comonadic and its right adjoint sends a pointed σ -structure ( A , a )to the tree-ordered structure obtained by unravelling the structure A , start-ing from a , to depth k , and with the σ -relations interpreted so as to satisfythe condition (M).These constructions yield the comonads described concretely in [2, 6].The sequences correspond to plays in the Ehrenfeucht-Fra¨ıss´e, pebbling andmodal bisimulation games respectively.We now show how resource-indexed arboreal covers can be used to defineimportant notions on the extensional category. Definition 7.8.
For a resource-indexed arboreal cover of E by C , with ad-junctions L k , R k and comonads G k , we define three resource-indexed equi-valence relations on objects of E . The first two use the co-Kleisli categoryof G k , while the third uses the Eilenberg-Moore category.(1) We define a (cid:29) C k b iff there are co-Kleisli morphisms G k a → b and G k b → a .(2) We define a ∼ = C k b iff a and b are isomorphic in the co-Kleisli categoryof G k .(3) We define a ↔ C k b iff there is a bisimulation between R k a and R k b in C k . Proposition 7.9.
For objects a and b of E , a ↔ C k b iff R k a and R k b arestrong back-and-forth equivalent, iff Duplicator has a winning strategy in thegame G ( R k a, R k b ) .Proof. This follows directly from Theorems 6.3 and 6.9, and Proposition 7.5. (cid:3)
What do these notions mean in Example 7.7? For each of our threetypes of model comparison game, there are corresponding fragments L k offirst-order logic [15, 8]: • For Ehrenfeucht-Fra¨ıss´e games, L k is the fragment of quantifier-rankat most k . • For pebble games, L k is the k -variable fragment. • For bisimulation games, L k is the modal fragment with modal depthat most k .In each case, we write ∃L k for the existential positive fragment of L k , and L k ( L k with counting quantifiers [15]. For each logic L , there is the usual equivalence on σ -structures: A ≡ L B iff for all ϕ in L , A | = ϕ ⇐⇒ B | = ϕ .We now have the following result from [6]: Theorem 7.10.
For σ -structures A and B :(1) A ≡ ∃L k B ⇐⇒ A (cid:29) C k B .(2) A ≡ L k B ⇐⇒ A ↔ C k B .(3) A ≡ L k ( B ⇐⇒ A ∼ = C k B . Note that this is really a family of three theorems, one for each type ofgame arising from a resource-indexed arboreal cover C as in Example 7.7.Thus in each case, we capture the salient logical equivalences in syntax-free,categorical form. Definition 7.11.
We return to the general setting. Given a resource-indexed arboreal cover of E by C , we know by comonadicity that for each k , C k is isomorphic to the Eilenberg-Moore category of coalgebras for thecomonad G k . For each object a of E , we can ask if it carries a G k -coalgebrastructure; that is, whether there is a morphism α : a → G k a satisfying the G k coalgebra conditions. Moreover, we can ask for the least k such that thisis the case. We call this the coalgebra number of a .The intuition behind this, as explained in [2, 6], is that the resourceparameter is bounding access to the structure, meaning that the lower thevalue of k , the more difficult it is to have a morphism in E with codomain G k a . So the least k for which this is possible is a significant invariant of thestructure. This intuition is born out by the following result from [2, 6]. Theorem 7.12.
The following statements hold:(1) For the Ehrenfeucht-Fra¨ıss´e comonad, the coalgebra number of A corresponds precisely to the tree-depth of A .(2) For the pebbling comonad, the coalgebra number of A correspondsprecisely to the tree-width of A .(3) For the modal comonad, the coalgebra number of A corresponds pre-cisely to the modal unfolding depth of A . What underlies these results is the comonadicity of the arboreal covers,which means that the coalgebras are witnesses for the various forms of treedecompositions of structures in E corresponding to these combinatorial in-variants. 8. Extendable Objects
As a further illustration of the use of our axiomatic setting, we show thatit is possible to give an account of the key notion of extendability , used byRossman in his seminal results on homomorphism preservation [19], at thislevel of generality.The following lemma is an abstraction of the (trivial) observation thatany two models that are equivalent in a logic L are also equivalent in theexistential positive fragment ∃L of L ( cf. Theorem 7.10). Recall that twoobjects
X, Y in a category are said to be homomorphically equivalent if thereexist morphisms X → Y and Y → X . Lemma 8.1.
Let C be an arboreal category, and X, Y ∈ C . If X and Y arebisimilar, then they are homomorphically equivalent. RBOREAL CATEGORIES: AN AXIOMATIC THEORY OF RESOURCES 25
Proof.
Suppose that we have a span of open pathwise embeddings in C asdisplayed below. X Z Y f g
We show that there exists a morphism X → Y ; the existence of a morphism Y → X follows by symmetry. Because X is path-generated, for any object Y (cid:48) , to obtain a morphism X → Y (cid:48) it is enough to specify a cocone withvertex Y (cid:48) over the diagram P X .Let m : P (cid:26) X be any path embedding. We define, by induction on m ,a path embedding n m : P (cid:26) Z such that f ◦ n m = m in C :(i) Suppose that m is the root of P X . Since P f sends the root of P X to the root of P Y , it follows by Proposition 4.2 that P f issurjective. Hence there exists a path embedding n m : Q (cid:26) Z suchthat P f ( n m ) = m in P X . As f is a pathwise embedding, we canassume without loss of generality that Q = P and f ◦ n m = m in C .(ii) Assume we have defined n m , and let m (cid:48) : Q (cid:26) X be a path embed-ding satisfying m ≺ m (cid:48) in P X . Then there is a path embedding j : P (cid:26) Q such that m (cid:48) ◦ j = m . By inductive hypothesis we have f ◦ n m = m in C and so the following square commutes. P QZ X jn m m (cid:48) f Because f is open, there exists a diagonal filler n m (cid:48) : Q (cid:26) Z . Inparticular, f ◦ n m (cid:48) = m (cid:48) .The following is then a cocone with vertex Z over P X by construction: { n m : P (cid:26) Z | m ∈ P X } . Thus there exists a morphism (in fact, a pathwise embedding) X → Z in C .Composing with g : Z → Y , we obtain the desired morphism X → Y . (cid:3) Remark 8.2.
Direct inspection of the previous proof shows that the state-ment of Lemma 8.1 can be strengthened to the effect that, for any twobisimilar objects
X, Y , there are pathwise embeddings X → Y and Y → X .We seek sufficient conditions on X and Y so that the converse of theprevious lemma holds. To this end, inspired by the work of Rossman [19]and its categorical interpretation in [1], we introduce the following notion. Definition 8.3.
An object X of an arboreal category is extendable if, givenany commutative diagram as on the left-hand side below, with P a path, PX Y m nfg
QX Y m (cid:48) n (cid:48) f (cid:48) g (cid:48) ( i.e. , such that the equations f ◦ m = n and g ◦ n = m are satisfied) anda path embedding n (cid:48) : Q (cid:26) Y such that n ≤ n (cid:48) in P Y , there exist a pathembedding m (cid:48) : Q (cid:26) X and morphisms f (cid:48) : X → Y and g (cid:48) : Y → X suchthat m ≤ m (cid:48) in P X and the rightmost diagram above commutes. Theorem 8.4.
Let C be an arboreal category, and X, Y extendable objectsof C . If X and Y are homomorphically equivalent, then they are bisimilar.Proof. By Theorem 6.3, it is enough to show that X and Y are strong back-and-forth equivalent. Let f : X → Y and g : Y → X be morphisms in C andlet m ∈ P X , n ∈ P Y be generic elements satisfying dom( m ) ∼ = dom( n ). Weclaim that the set B := { (cid:74) m, n (cid:75) | ∃ s : X → Y, t : Y → X s.t. P s ( m ) = n and P t ( n ) = m } is a strong back-and-forth system between X and Y .Note that P f ( ⊥ X ) = ⊥ Y and P g ( ⊥ Y ) = ⊥ X entail (cid:74) ⊥ X , ⊥ Y (cid:75) ∈ B . So,item (i) in Definition 6.1 is satisfied.For item (ii), suppose that (cid:74) m, n (cid:75) ∈ B and let m (cid:48) ∈ P X satisfy m ≺ m (cid:48) .We must find an n (cid:48) ∈ P Y such that n ≺ n (cid:48) and (cid:74) m (cid:48) , n (cid:48) (cid:75) ∈ B . By assumption,there are morphisms s : X → Y and t : Y → X such that P s ( m ) = n and P t ( n ) = m . Thus, setting P := dom( m ) and Q := dom( n ), there existisomorphisms ϕ : P → Q and ψ : Q → P such that s ◦ m = n ◦ ϕ and t ◦ n = m ◦ ψ in C . By Lemma 5.4(a) we have ψ = ϕ − , and so the left-handdiagram below commutes. PX Y m n ◦ ϕst P (cid:48) X Y m (cid:48) n (cid:48) s (cid:48) t (cid:48) Let P (cid:48) := dom( m (cid:48) ). Since Y is extendable, there exist a path embedding n (cid:48) : P (cid:48) (cid:26) Y and morphisms s (cid:48) : X → Y and t (cid:48) : Y → X such that n ◦ ϕ ≤ n (cid:48) , s (cid:48) ◦ m (cid:48) = n (cid:48) , and t (cid:48) ◦ n (cid:48) = m (cid:48) , as displayed in the right-hand diagram above.It follows that (cid:74) m (cid:48) , n (cid:48) (cid:75) ∈ B (just observe that P s (cid:48) ( m (cid:48) ) = n (cid:48) because thecomposite s (cid:48) ◦ m (cid:48) is an embedding, and similarly P t (cid:48) ( n (cid:48) ) = m (cid:48) ). It remainsto show that n ≺ n (cid:48) . For any forest order ( U, ≤ ), define the height ht( x ) ofan element x ∈ U to be the length of the finite chain ↓ x . As n = n ◦ ϕ ≤ n (cid:48) in P Y , it is enough to show that ht( n (cid:48) ) = ht( n ) + 1. Using the fact thattree morphisms preserve the height of points, and P s (cid:48) ( m (cid:48) ) = s (cid:48) ◦ m (cid:48) , we getht( n (cid:48) ) = ht( s (cid:48) ◦ m (cid:48) ) = ht( m (cid:48) ) = ht( m ) + 1 . Item (iii) in Definition 6.1 is proved in a similar manner, using the factthat X is extendable. Finally, it is easy to see that the back-and-forthsystem B is strong. (cid:3) RBOREAL CATEGORIES: AN AXIOMATIC THEORY OF RESOURCES 27
References
1. S. Abramsky,
Whither semantics? , Theoretical Computer Science (2020), 3–14.2. S. Abramsky, A. Dawar, and P. Wang,
The pebbling comonad in finite model theory ,32nd Annual ACM/IEEE Symposium on Logic in Computer Science (LICS), 2017,pp. 1–12.3. S. Abramsky, R. Jagadeesan, and P. Malacaria,
Full abstraction for PCF , Informationand computation (2000), no. 2, 409–470.4. S. Abramsky and D. Marsden,
Comonadic semantics for guarded fragments , Preprintavailable at https://arxiv.org/abs/2008.11094 , 2020.5. S. Abramsky and N. Shah,
Relating structure and power: Comonadic semantics forcomputational resources , 27th EACSL Annual Conference on Computer Science Logic,CSL 2018, September 4-7, 2018, Birmingham, UK, 2018, pp. 2:1–2:17.6. S. Abramsky and N. Shah,
Relating structure and power: Comonadic semantics forcomputational resources , Extended version to appear in Journal of Logic and Compu-tation. Preprint available at https://arxiv.org/abs/2010.06496 , 2020.7. J. Ad´amek, H. Herrlich, and G.E. Strecker,
Abstract and concrete categories. The joyof cats , Online edition, 2004.8. P. Blackburn, M. De Rijke, and Y. Venema,
Modal logic , Cambridge Tracts in Theor-etical Computer Science, vol. 53, Cambridge University Press, 2002.9. A. ´O Conghaile and A. Dawar,
Game comonads & generalised quantifiers , 29th EACSLAnnual Conference on Computer Science Logic, CSL (C. Baier and J. Goubault-Larrecq, eds.), LIPIcs, vol. 183, Schloss Dagstuhl - Leibniz-Zentrum f¨ur Informatik,2021, pp. 16:1–16:17.10. P.J. Freyd and G.M. Kelly,
Categories of continuous functors, I , Journal of Pure andApplied Algebra (1972), no. 3, 169–191.11. J.M.E. Hyland and C.-H.L Ong, On full abstraction for PCF: I, II, and III , Informa-tion and computation (2000), no. 2, 285–408.12. A. Joyal, M. Nielsen, and G. Winskel,
Bisimulation from open maps , Information andComputation (1996), no. 2, 164–185.13. A. Joyal, M. Nielson, and G. Winskel,
Bisimulation and open maps , Proceedings of8th Annual IEEE Symposium on Logic in Computer Science, 1993, pp. 418–427.14. T. Kloks,
Treewidth: computations and approximations , Springer Lecture Notes inComputer Science, vol. 842, Springer Science & Business Media, 1994.15. L. Libkin,
Elements of Finite Model Theory (Texts in Theoretical Computer Science.An EATCS Series) , Springer, 2004.16. S. Mac Lane,
Categories for the working mathematician , 2nd ed., GTM, vol. 5,Springer-Verlag, New York, 1998.17. J. Neˇsetˇril and P. Ossona de Mendez,
Tree-depth, subgraph coloring and homomorph-ism bounds , European Journal of Combinatorics (2006), no. 6, 1022–1041.18. E. Riehl, Factorization systems , Notes available at .19. B. Rossman,
Homomorphism preservation theorems , J. ACM (2008), no. 3, 15:1–15:53.20. ACM SIGLOG, Alonzo Church Award , https://siglog.org/winners-of-the-2017-alonzo-church-award/ , 2017. Department of Computer Science, University of Oxford, United Kingdom
Email address : [email protected] Department of Computer Science, University of Oxford, United Kingdom
Email address ::