towards a uniform presentation of logical systems by ...€¦ · also, from a categorical...

38
Towards a Uniform Presentation of Logical Systems by Indexed Categories and Adjoint Situations U. Wolter: Department of Informatics, University of Bergen - Norway E-mail : [email protected] A. Martini : Faculdade de Inform´ atica, PUCRS - Brasil E-mail : [email protected] E. H. H¨ ausler : Departamento de Ciˆ encia da Computa¸c˜ ao, PUC-Rio - Brasil E-mail : [email protected] Abstract Logical Systems are paramount to almost every subject in computer science. This vast number of application areas had a deep influence on us and thus on how we perceive what a formal specification of a logical system should be. Lawvere´s [29, 30] essential idea is that the fundamental relationship between syntax and semantics can be precisely formulated by adjoint functors. In this work, we show that Institutions from Goguen and Burstall [19] and Entailment Systems from Meseguer [36] are in its essence, a family of local adjoint situations between the syntactical and semantical aspects underlying these systems. These abstractions are named Indexed Frames. Also, from a categorical perspec- tive, Tarski´s consequence operator [40] can be formalized as Indexed Closure Operators, a construction that maps each language to the corresponding co-monad. Finally, in the framework of preorder categories, both concepts, Indexed Frames and Indexed Closure Operators are equivalent. Keywords: general logics, adjoint situations, indexed categories, galois connections, co- monads. 1 Introduction There has been many influential works proposing a definition or presentation for what a logical system really is, like for instance, [37, 17, 19, 36, 1, 9, 16]. Especially, when considering logics for specification and programming, many of these approaches are either based or strongly related to the notion of an Institution [19]. This concept carries in its essence the linguistic aspects of a logic, namely, it considers a category of signatures and signature morphisms as a building block of the very concept of a logical system. Besides, it also draws attention to the fact that the language of indexed (and fibred) categories is a very powerful tool around which we can organize in a modular way many aspects of a logic [35, 41, 22, 9, 39, 8]. Correspondent Author. Partially supported by the Brazilian Research Council (CNPq) (grant No. 303427/2010-8)

Upload: others

Post on 25-Jun-2020

4 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

Towards a Uniform Presentation of Logical

Systems by Indexed Categories and

Adjoint Situations

U. Wolter: Department of Informatics, University of Bergen - NorwayE-mail: [email protected]

A. Martini†: Faculdade de Informatica, PUCRS - BrasilE-mail: [email protected]

E. H. Hausler‡: Departamento de Ciencia da Computacao, PUC-Rio - BrasilE-mail: [email protected]

Abstract

Logical Systems are paramount to almost every subject in computer science. Thisvast number of application areas had a deep influence on us and thus on how we perceivewhat a formal specification of a logical system should be. Lawvere´s [29, 30] essentialidea is that the fundamental relationship between syntax and semantics can be preciselyformulated by adjoint functors. In this work, we show that Institutions from Goguen andBurstall [19] and Entailment Systems from Meseguer [36] are in its essence, a family oflocal adjoint situations between the syntactical and semantical aspects underlying thesesystems. These abstractions are named Indexed Frames. Also, from a categorical perspec-tive, Tarski´s consequence operator [40] can be formalized as Indexed Closure Operators,a construction that maps each language to the corresponding co-monad. Finally, in theframework of preorder categories, both concepts, Indexed Frames and Indexed ClosureOperators are equivalent.

Keywords: general logics, adjoint situations, indexed categories, galois connections, co-monads.

1 Introduction

There has been many influential works proposing a definition or presentation for what a logicalsystem really is, like for instance, [37, 17, 19, 36, 1, 9, 16]. Especially, when considering logicsfor specification and programming, many of these approaches are either based or stronglyrelated to the notion of an Institution [19]. This concept carries in its essence the linguisticaspects of a logic, namely, it considers a category of signatures and signature morphisms asa building block of the very concept of a logical system. Besides, it also draws attention tothe fact that the language of indexed (and fibred) categories is a very powerful tool aroundwhich we can organize in a modular way many aspects of a logic [35, 41, 22, 9, 39, 8].

†Correspondent Author.‡Partially supported by the Brazilian Research Council (CNPq) (grant No. 303427/2010-8)

Page 2: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

1 INTRODUCTION

On the other hand, it is well-known from category theory that adjoint situations ariseeverywhere [31, 3]. Especially, the seminal work of Lawvere [30, 29] stresses that adjointfunctors capture in a precise and formal way the very nature of the Formal-Conceptual Dualitythat is ubiquitous in mathematics and logic. More precisely in [30], he states1

"That pursuit of exact knowledge which we call mathematics seems to involvein an essential way two dual aspects, which we may call the Formal and theConceptual. For example, we manipulate algebraically a polynomial equationand visualize geometrically the corresponding curve. Or we concentrate in onemoment on the deduction of theorems from the axioms of group theory, and inthe next consider the classes of actual groups to which the theorems refer. Thusthe Conceptual is in a certain sense the subject matter of the Formal".

In the context of a logical system, the Formal is represented usually by a formal languageSyn, i.e., a set of sentences , while the Conceptual (denotation) Den is often defined accordingto one of the following traditional views2:

• a model theoretic approach, that takes the binary satisfaction relation between modelsand sentences as basic;

• a proof-theoretic approach, that requires a binary entailment relation between sets ofsentences;

• a Tarskian-approach (if you like), that assumes a consequence or closure operator on agiven set of sentences.

In the first case, one can immediately define a partial ordering on Syn and Den so thata Galois connection can be established between both structures and hence the mappingssem : Syn → Den and fml : Den → Syn become adjoint functors between the correspondingpartial orders viewed as categories, where fml (formulas) is left-adjoint to sem (semantics),fml a sem:

Synsem⊥ // Denfmloo

The arrows in Den are inclusion of subcategories of models, while in Syn, they are (op-posite) inclusions of specifications (theory presentations). The mappings (functors) sem andfml are defined by assignment of models with respect to specifications, respectively, theories(closed set of sentences) induced by a certain class of models. These functions are actuallycompatible in a natural way with respect to change of languages (or syntactic vocabulary) sothat both sem and fml become indexed functors. This crucial observation leads to the notionof Indexed Frames. By a chain of stepwise constructions and lemmas we will see that in thecase of Institutions, the satisfaction condition is both necessary and sufficient to impose thisnaturality. Thus, at the level of specifications and corresponding subcategories of models,an Institution defines exactly an indexed frame, where each index refers to a partial ordercategory. Hence they are called Indexed Partial Order Frames.

1This remark from Lawvere was also pointed out in [36].2The first two are already mentioned in [36].

2

Page 3: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

2 NOTATIONS AND BASICS

In the proof-theoretic approach, the arrows in Den are entailment relations between spec-ifications, (so that Den is actually a preorder), while the arrow in Syn are reverse inclusions ofspecifications. The axioms of Entailment Systems described in [36] ensure again a naturalitycondition so that sem and fml are also indexed functors. Here sem is just an inclusion,while fml maps each specification to its corresponding closed set with respect to entailment.Thus, at the level of specifications and corresponding entailments between set of formulas,an Entailment System defines again an Indexed Frame, where each index refers to a preordercategory. Thus here, they are called Indexed Preorder Frames.

In the Tarskian-style [40] we have the following situation: a closure (or consequent) oper-ator from the point of view of category theory is simply a co-monad. Here closure operatorsessentially maps specifications to their corresponding closed set of sentences. Moreover, ifwe take into account change of languages, we are naturally led to the notion of Indexed Clo-sure Operator, which associates each language (index) to the corresponding monad. However,there is a caveat: this closure is no longer compatible in a natural way with respect to changeof syntax. Fortunately, the categorical notion of lax natural transformation fixes in a preciseway how closures and translation of languages behave with respect to each other.

Furthermore, both categorical structures, indexed frames and indexed closure operatorsare in some sense equivalent in the framework of preorder categories. Via canonical fac-torization of co-monads into adjoints one can build an Indexed Frame carrying the sameinformation. Likewise, local adjointness entails lax naturality, and hence that each indexedframe defines a corresponding Indexed Closure Operator.

This paper is organized as follows: in section 3 we present the concept of Institutions[19] and show that at the level of specifications and corresponding (full) subcategories ofmodel classes, the (invariant) institution condition has an equivalent description as a naturaltransformation. An abstraction of this observation is named an Indexed Frame, a categorical,more general, specification of Institution-like logics, where each index is associated to a partialorder category. In section 4 we present the concept of Entailment Systems [36], and again, atthe level of entailment between specifications we observe that this concept is also an instanceof the concept of an Indexed Frame, where each index is associated to a preorder category.In section 6 we provide a detailed presentation of linear logic (actually a sublogic of it) as anIndexed Frame. The example is important because it shows a situation where the categoriesinduced by the indexes of a given category Ind are neither pre- nor partial order categories.Moreover, in section 7, we discuss another important logical system as an Indexed Frame,namely that of generalized sketches. The special situation here is that this logical sytem isdefined with fibred rather than indexed semantics, e.g., as in Institutions. Then we showthat generalized sketches, even with fibred semantics, also give rise to Indexed Partial OrderFrames. Finally, in section 8, we extend the notion of monads and introduce the idea of anIndexed Closure Operator. By exploiting the initial and final solutions to the factorizationproblem of monads by means of adjoint functors, we are also able to state that IndexedClosure Operators and Indexed Preorder Frames are equivalent categorical formulations andthus essentially the same concept.

2 Notations and Basics

Below we summarize notation and essential background for reading this paper. Most of itcan be seen as folklore. It can be omitted (on a first reading) if you are familiar with these

3

Page 4: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

2 NOTATIONS AND BASICS

topics.

Consider a set A and a binary relation ≤ on A. Then ≤ is called a preorder on A, written(A,≤), if we have that, for all x, y, z ∈ A that

• x ≤ x (reflexivity)

• x ≤ y and y ≤ z then x ≤ z (transitivity)

If the relation ≤ is in addition antisymmetric, that is, for all x, y ∈ A we have that x ≤ yand y ≤ x implies x = y then (A,≤) is also called a partial order. For instance, let P(A) ={X|X ⊆ A}, i.e., the set of all subsets of A, called the powerset of A. Then (P(A),⊆) and(P(A),⊇) are partially order sets (also known as posets) and thus also preorder sets. Giventwo partially order sets (A,≤1) and (B,≤2), a Galois connection between these posets iscomprised by two monotone functios F : A→ B and G : B → A, such that for all a ∈ A andb ∈ B we have that

a ≤1 G(a) if and only if F (a) ≤2 b

Most Galois connections arise in the following way. Let A and B be sets and R ⊆ A × B abinary relation from A to B. Then for any subset X on A we define a subset fml(X) of Bby the rule

fml(X) = {y ∈ B | ∀x ∈ X. (x, y) ∈ R}

and similarly, for any subset Y of B, we define a subset sem(Y ) of A by

sem(Y ) = {x ∈ A | ∀y ∈ Y. (x, y) ∈ R}

Thus we have two mappings

fml : P(A)→ P(B) and sem : P(B)→ P(A)

such that fml and sem form a Galois connection, once one of partial order sets the inclusionis interpreted in the opposite ordering, i.e, if the order ≤ is interpreted as the reverse inclusion⊇ between sets.

Definition 2.1. Given a preorder (A,≤), a closure operator on A is a function cl : A → Awith the following properties:

• x ≤ cl(x) for all x ∈ A, i.e. cl is extensive

• for all x, y ∈ A, if x ≤ y, then cl(x) ≤ cl(y), i.e. cl is monotonically increasing

• cl(cl(x)) ≤ cl(x) for all x ∈ A, i.e. cl is an idempotent function.

Fact 2.2. Let A and B be sets and K : P(A)→ P(B), L : P(B)→ P(A) be maps which forma Galois connection. Then:

• The map L ◦K is a closure operator on P(A).

• The map K ◦ L is a closure operator on P(B).

4

Page 5: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

2 NOTATIONS AND BASICS

Thus, given fml : P(A)→ P(B) and sem : P(B)→ P(A) as above, we have that fml; semis a closure operator on P(A) and sem; fml is a closure operator on P(B).

Below, we assume the reader is familiar with basic notions of category theory (e.g.,[3, 31]).Nevertheless, the essential background is presented below. The collection of objects of acategory C will be denoted |C|. Given objects a, b ∈ |C|, the set of arrows from a to b isdenoted C(a, b). The category Set is the category of sets and total functions, while Cat is thecategory of all categories and functors (lying in a higher set-theoretic universe).

Let C be a category and A,B arbitrary objects in |C|. Then C is a preorder categoryif the cardinality of the collection C(A,B) is at most equal to one. Additionally, C is called apartial order category if for any objects A and B in C, the existence of an isomorphismi : A→ B entails A = B and thus i = idA = idB.

We also write PO to denote the category of all partial orders. We consider here partialorders as special categories thus PO is taken as a full subcategory of the category Cat ofcategories. In the same way, we write PRE to represent the category of all preorders. ThusPRE is a full subcategory of Cat and it follows that PO is also a full subcategory of PRE.

We represent composition of maps (functors) in diagrammatic order. For instance if F :

A→ B and G : B→ C are functors and a ∈ |A|, then F ;G : A→ C and (F ;G)(a)def= G(F (a))

is an object of C, or equivalently, G(F (a)) ∈ |C|.Also, different institutions, frames, logics, are denoted with primed superscripts (e.g.,

I, I ′, I ′′,etc.), while different objects within an institution (frame, logic), as signatures, mod-els, etc., are denoted with numbered subscripts (e.g., Σ1,Σ2,M1,M2,etc.).

Moreover, if α : F ⇒ G : A → B and β : G ⇒ H : A → B are natural transformations,then the vertical composition of α and β is denoted α;β : F ⇒ H : A → B such that for

each a ∈ |A|, (α;β)(a)def= α(a);β(a). Also, if F : A → B, G,G′ : B → C, H : C → D

are functors and α : G ⇒ G′ : B → C is a natural transformation, then the horizontalcompositions of F with α, and α with H are represented as (F � α) : F ;G ⇒ F ;G′ : A → C

and (α �H) : G;H ⇒ G′;H : B→ D such that for each b ∈ |B|, a ∈ |A|, (F � α)(a)def= α(F (a))

whereas (α �H)(b)def= H(α(b)).

AF // B

G((

G′

66�� α CH // D

We have immediately according to the definition of composition

idB � α = α and α � idC = α (1)

and since functors map identities to identities we have also

F � idG = idF ;G and idG �H = idG;H (2)

Moreover we have for functors F : A → B, G : B → A, H,H ′, H ′′ : C → D, I : D → E andnatural transformations γ : H ⇒ H ′, δ : H ′ ⇒ H ′′ the following laws

AF // B

G // C

H

""�� γ==

H′′�� δ

// DI // E

5

Page 6: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

3 INSTITUTIONS AND INDEXED FRAMES

(F ;G) � γ = F � (G � γ) and G � (γ; δ) = (G � γ); (G � δ) (3)

(G � γ) � I = G � (γ � I) and (γ; δ) � I = (γ � I); (δ � I) (4)

Let A and B be categories. If F : A → B and G : B → A, we say that F is left adjointto G and G is right adjoint to F provided there is a natural transformation η : idA ⇒ F ;Gsuch that for any two objects a of A and b of B and any arrow f : a→ G(b) there is a uniquearrow g : F (a)→ b that solves the equation

f = η(a);G(?)

It is usual to write F a G to denote the above situation. The data (F,G, η) constitute anadjunction and the transformation η is called the unit of the adjunction. The definition above,implies the following proposition, establishing a crucial symmetry of the above situation:

Fact 2.3. Suppose that F : A → B and G : B → A are functors such that F a G. Then,there is a natural transformation ε : G;F ⇒ idB such that for any arrow g : F (a)→ b, thereis a unique arrow f : a→ G(b) that solves the equation

g = F (?); ε(b)

3 Institutions and Indexed Frames

The concept of an Institution introduced by Goguen and Burstall [19] formally capturesthe notion of logical systems and allowed them to reformulate and to generalize the workthey had done in the 70’s on structuring (equational) specifications (see [4, 5]) independentlyof the underlying logic. A similar proposal of an abstract concept of a logic had been givenalready by Barwise [1]. The following definition can be found in [19].

Definition 3.1 (Institution). An Institution I = (Sign, Sen,Mod, |=) is given by thefollowing data and operations:

+ a category of abstract signatures Sign;

+ a syntax functor Sen : Sign→ Set, defining for each signature its set of sentences;

+ a model functorMod : Signop → Cat, defining for each signature, its correspondingcategory of models;

+ an indexed family of satisfaction relations |=Σ⊆ |Mod(Σ)| × Sen(Σ),Σ ∈|Sign|; such that the following Institution condition

Mod(φ)(M2) |=Σ1 ϕ1 ⇐⇒M2 |=Σ2 Sen(φ)(ϕ1)

holds for each φ : Σ1 → Σ2 in Sign, M2 ∈ |Mod(Σ2)|, and ϕ1 ∈ Sen(Σ1).

Remark 3.2 (Component Implications). It will be essential for us to have a deeper under-standing of the above institution condition when we see it from the perspective of the twocomponent implications. Therefore, we label them for future reference.

ICSen⇒Mod Mod(φ)(M2) |=Σ1 ϕ1 ⇐M2 |=Σ2 Sen(φ)(ϕ1)ICMod⇒Sen Mod(φ)(M2) |=Σ1 ϕ1 ⇒M2 |=Σ2 Sen(φ)(ϕ1)

6

Page 7: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

3 INSTITUTIONS AND INDEXED FRAMES

Institutions are based on a pointwise assignment of signatures, sentences, and models.But in formal specifications, the relevant objects are not sentences, but sets of sentences(theories). The following investigations on this level of abstraction provide new insights intothe conceptual nature of logical systems so that we can give a fully categorical account of theinstitution condition.

Assuming an institution I, and a set of Σ-sentences Γ ⊆ Sen(Σ), we define the categorymod(Σ)(Γ) as the full subcategory induced by those models in |Mod(Σ)| that satisfy Γ, i.e.,

|mod(Σ)(Γ)| def= {M ∈ |Mod(Σ)| | ∀ϕ ∈ Γ : M |=Σ ϕ}. (5)

Analogously, we define for a given subcategory M ⊆ Mod(Σ) of Σ-models, the set oftheorems th(Σ)(M) ⊆ Sen(Σ) given by those sentences ϕ ∈ Sen(Σ) which are satisfied by allmodels in M, i.e., we have

th(Σ)(M)def= {ϕ ∈ Sen(Σ) | ∀M ∈ |M| : M |=Σ ϕ}. (6)

Obviously, mod(Σ) and th(Σ) induce mappings between Σ-specifications and subcategoriesof Σ-models and vice-versa.

Definition 3.3 (Partial Order Categories). Given a signature Σ ∈ |Sign|, we define thepartial order category Spec(Σ) of strict specifications, the category where the objects are allsets Γ ⊆ Sen(Σ), and the arrows are all the inverse inclusions Γ1 ⊇ Γ2. Analogously, thepartial order category Sub(Σ) has as objects all subcategories M ⊆ Mod(Σ) and as arrows allinclusion functors M1 ⊆ M2.

By definition of Spec(Σ) and Sub(Σ), we can formulate the usual categorical presentationof the Galois correspondence arising from any (satisfaction) relation as an adjunction th(Σ) amod(Σ).

Proposition 3.4 (Galois Correspondence). Given a signature Σ ∈ |Sign|, the equations (5)and (6) define functors mod(Σ) : Spec(Σ)→ Sub(Σ) and th(Σ) : Sub(Σ)→ Spec(Σ), such thatth(Σ) is left-adjoint tomod(Σ), written th(Σ) a mod(Σ), where for any M,M1,M2 ∈ |Mod(Σ)|,and Γ,Γ1,Γ2 ∈ |Spec(Σ)|, we have:

1. th(Σ) functor: M1 ⊆ M2 implies th(Σ)(M1) ⊇ th(Σ)(M2);

2. mod(Σ) functor: Γ2 ⊇ Γ1 implies mod(Σ)(Γ2) ⊆ mod(Σ)(Γ1);

3. unit: M ⊆ mod(Σ)(th(Σ)(M));

4. counit: th(Σ)(mod(Σ)(Γ)) ⊇ Γ;

5. adjointness: M ⊆ mod(Σ)(Γ) iff th(Σ)(M) ⊇ Γ.

Sub(Σ)th(Σ)

> // Spec(Σ)mod(Σ)oo

Proof.

• th(Σ) functor: Let ϕ ∈ th(Σ)(M2). Then ∀M ∈ |M2| : M |=Σ ϕ. This implies that∀M ∈ |M1| : M |=Σ ϕ, since by assumption M1 ⊆ M2. Thus ϕ ∈ th(Σ)(M1).

7

Page 8: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

3 INSTITUTIONS AND INDEXED FRAMES

• mod(Σ) functor: Let M ∈ |mod(Σ)(Γ2)|. Then ∀ϕ ∈ Γ2 : M |=Σ ϕ. This implies∀ϕ ∈ Γ1 : M |=Σ ϕ, since by assumption Γ1 ⊆ Γ2. Thus M ∈ |mod(Σ)(Γ1)|. Thus|mod(Σ)(Γ2)| ⊆ |mod(Σ)(Γ1)|.

• unit: It follows from the adjointness property below.

• counit: It follows from the adjointness property below. adjointness: Note that:

M ⊆ mod(Σ)(Γ)iff ∀M ∈ |M| : M ∈ |mod(Σ)(Γ)|iff ∀M ∈ |M| : ∀ϕ ∈ Γ : M |=Σ ϕiff ∀ϕ ∈ Γ : ∀M ∈ |M| : M |=Σ ϕiff ∀ϕ ∈ Γ : ϕ ∈ th(Σ)(M)iff Γ ⊆ th(Σ)(M)

Fact 3.5 (Power Functors). For a set A let P(A) be the partial order (P(A),⊇) consideredas a category, where P(A) is the powerset of A. And for a category C let P(C) be the partialorder category over C, where the objects are all subcategories M ⊆ C and arrows all inclusionfunctors M1 ⊆ M2. Then we obtain

+ for any function f : A→ B the existential image powerset functor f : P(A)→P(B), by setting f(A′) = {f(a)|a ∈ A′} for any A′ ∈ P(A), and

+ for any functor F : C → D the inverse image power category functor F−1 :P(D) → P(C), where for any M ⊆ D: C ∈ |F−1(M)| iff F (C) ∈ M and g is an arrowin F−1(M) iff F (g) is an arrow in M.

Remark 3.6. Note that if A ⊇ A′ then f(A) ⊇ f(A′) by monotonicity of function application.Preservation of compositionality and identities follow from transitivity of subset inclusion andthe fact that there is at most one arrow (inclusion) between any two subsets. Analogouslyfor any two subcategories M,M′ in |P(D)| , if M ⊆ M′ then F−1(M) ⊆ F−1(M)′.

By Fact 3.5, we obtain for any signature morphism φ : Σ1 → Σ2 functors

Sen(φ) : Spec(Σ1)→ Spec(Σ2) and Mod(φ)−1 : Sub(Σ1)→ Sub(Σ2).

Lemma 3.7. A 4-tuple I = (Sign, Sen,Mod, |=) satisfies the institution condition for asignature morphism φ : Σ1 → Σ2 in Sign iff

mod(Σ2)(Sen(φ)(Γ1)) = Mod(φ)−1(mod(Σ1)(Γ1)), for all Γ1 ∈ |Spec(Σ1)|.

Σ1

φ

��

Spec(Σ1)mod(Σ1) //

Sen(φ)

��=

Sub(Σ1)

Mod(φ)−1

��Σ2 Spec(Σ2) mod(Σ2) // Sub(Σ2)

Proof. It suffices to show that the institution condition is equivalent to the following inequali-ties:

8

Page 9: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

3 INSTITUTIONS AND INDEXED FRAMES

1. mod(Σ2)(Sen(φ)(Γ1)) ⊆Mod(φ)−1(mod(Σ1)(Γ1)) for all Γ1 ∈ |Spec(Σ1)|.

2. Mod(φ)−1 (mod(Σ1)(Γ1)) ⊆ mod(Σ2) (Sen(φ)(Γ1)), for all Γ1 ∈ |Spec(Σ1)|.

ICSen⇒Mod implies inequality 1: For any M2 ∈ |Mod(Σ2)| we obtain

M2 ∈ |mod(Σ2)(Sen(φ)(Γ1))|⇔ M2 |=Σ2 Sen(φ)(ϕ1) for all ϕ1 ∈ Γ1 (def. mod(Σ2))⇒ Mod(φ)(M2) |=Σ1 ϕ1 for all ϕ1 ∈ Γ1 (ICSen⇒Mod))⇔ Mod(φ)(M2) ∈ |mod(Σ1)(Γ1)| (def. mod(Σ1))⇔ M2 ∈ |Mod(φ)−1(mod(Σ1)(Γ1))| (def. Mod(φ)−1)

Note that, concerning Lemma 3.7.1 and 3.7.2, the reader has to bear in mind that theinverse image of a full subcategory becomes a full subcategory as well.

Inequality 1 implies ICSen⇒Mod: For any M2 ∈ |Mod(Σ2)| we obtain

M2 |=Σ2 Sen(φ)(ϕ1) ⇔ M2 ∈ |mod(Σ2)(Sen(φ)(ϕ1))| (def. mod(Σ2))⇒ M2 ∈ |Mod(φ)−1(mod(Σ1)(ϕ1))| (inequality 1)⇔ Mod(φ)(M2) ∈ |mod(Σ1)(ϕ1)| (def. Mod(φ)−1)⇔ Mod(φ)(M2) |=Σ1 ϕ1 (def. mod(Σ1))

The equivalence of ICMod⇒Sen and inequality 2 is shown analogously.

Since the categories Spec(Σ) and Sub(Σ) are partial order categories, i.e., only the exis-tence of arrows matters, lemma 3.7 shows that the institution condition (the two implicationsaltogether) is equivalent to the following equation:

mod(Σ1);Mod(φ)−1 = Sen(φ);mod(Σ2). (7)

To summarize our analysis and to give an overall picture we have to remind:

Fact 3.8 (Power Construction Functors). Let A,B be sets and C,D be categories. Then wehave:

1. The assignments A 7→ P(A) and (f : A → B) 7→ (f : P(A) → P(B)), due to Fact 3.5,define a functor P : Set→ Cat.

2. The assignments C 7→ P(C) and (F : C→ D) 7→ (F−1 : P(D)→ P(C)), due to Fact 3.5,define a functor P− : Catop → Cat.

Now, our definitions can be compressed to

Specdef= Sen;P : Sign→ Cat and Sub

def= Modop;P− : Sign→ Cat (8)

and equation 7 says that mod(Σ) is the component at Σ of an indexed functor mod : Spec⇒Sub : Sign→ Cat, i.e., the institution condition is equivalent to a naturality requirement.

Together with proposition 3.4 this crucial observation leads to the following abstractconcept of logic, which was introduced in [35].

9

Page 10: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

3 INSTITUTIONS AND INDEXED FRAMES

Definition 3.9 (Indexed Frame). An Indexed Frame

IF = (Ind, Syn,Den, sem, fml)

is given by the following data and operations:

+ a category Ind;

+ an indexed category (syntax functor) Syn : Ind→ Cat;

+ an indexed category (denotation functor) Den : Ind→ Cat;

+ a family sem of functors sem(i) : Syn(i)→ Den(i), i ∈ |Ind|;

+ a family fml of functors fml(i) : Den(i)→ Syn(i), i ∈ |Ind|;

+ a family (fml(i), sem(i), η(i), ε(i)), i ∈ |Ind| of local adjunctions, i.e., fml(i) left-adjoint to sem(i), fml(i) a sem(i) in symbols, with unit η(i) : idDen(i) ⇒ fml(i); sem(i)and co-unit ε(i) : sem(i); fml(i)⇒ idSyn(i);

such that the family of functors sem(i), i ∈ |Ind| constitute an indexed functor sem :Syn =⇒ Den : Ind→ Cat, that is to say, the following indexed frame condition

sem(i);Den(σ) = Syn(σ); sem(j) holds for each σ : i→ j in Ind.

Moreover, if the indexed functors Syn and Den are into the category PO of all partialorder categories, we call the above structure an Indexed Partial Order Frame, writtenIFPO. In case they are into the category PRE of all preorders, we name it an IndexedPreorder Frame, written IFPRE .

i

σ

��

Syn(i)sem(i)

⊥ //

Syn(σ)

��

Den(i)fml(i)oo

Den(σ)

��j Syn(j)

sem(j)

⊥ // Den(j)fml(j)oo

Definition 3.9 specializes the concept of Indexed Frame introduced in [35] to partialorder and preorder categories. We remind the reader that functors between partial ordercategories are nothing but monotone mappings and that adjunctions between partial ordercategories are just (a categorical reformulation of) Galois correspondences.

Theorem 3.10 (Institutional Frame). A 4-tuple I = (Sign, Sen,Mod, |=) is an institutioniff the 5-tuple

IF = (Sign, Spec, Sub,mod, th)

is an indexed partial order frame, called the institutional frame for I.

Σ1

φ

��

Spec(Σ1)mod(Σ1)

⊥ //

Spec(φ)

��

Sub(Σ1)th(Σ1)oo

Mod(φ)−1

��Σ2 Spec(Σ2)

mod(Σ2)

⊥ // Sub(Σ2)th(Σ2)oo

10

Page 11: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

4 ENTAILMENT SYSTEMS

Proof. Immediately by Proposition 3.4, Lemma 3.7, and Fact 3.8.

Remark 3.11. Note that the above theorem does not say that an indexed partial order frameis an Institution, but that the data and axioms of an Institution define a structure that at thelevel of specifications and corresponding categories of models match all the data and satisfyall constrains of an indexed frame. Hence, an indexed frame is a categorical structure whichin some sense is more general that an Institution.

4 Entailment Systems

The concept of entailment system introduced in [36] reflects those properties of the entailmentrelation Γ ` ϕ which are independent from the particular rules used to generate the relation`. This section is devoted to validate the concept of indexed partial order frame by showingthat also entailment systems give rise, quite naturally, to indexed partial order frames.

Definition 4.1 (Entailment System). An entailment system is a triple E = (Sign, Sen,`)with Sign a category of signatures, Sen : Sign → Set a functor, and ` a function associatingto each signature Σ a binary relation `Σ⊆ P(Sen(Σ)) × Sen(Σ) called entailment relationsuch that the following properties are satisfied:

+ reflexivity: for any ϕ ∈ Sen(Σ), {ϕ} ` ϕ;

+ monotonicity: if Γ1 `Σ ϕ and Γ2 ⊇ Γ1 then Γ2 `Σ ϕ;

+ transitivity: if Γ `Σ ϕi, for i ∈ I, and Γ ∪ {ϕi | i ∈ I} `Σ ψ, then Γ `Σ ψ;

+ `-translation: if Γ1 `Σ1 ϕ1, then for any φ : Σ1 → Σ2 in Sign, Sen(φ)(Γ1) `Σ2

Sen(φ)(ϕ1).

The entailment relation `Σ between sets of Σ-sentences and single Σ-sentences can bestraightforwardly extended to an equivalent entailment relation between Σ-specifications.For any signature Σ in Sign we define a corresponding extended entailment relation `PΣ⊆P(Sen(Σ)) × P(Sen(Σ)) = |Spec(Σ)| × |Spec(Σ)|, where we set for any Σ-specificationsΓ1,Γ2 ∈ Spec(Σ) :

Γ1 `PΣ Γ2 iff ∀ϕ2 ∈ Γ2 : Γ1 `Σ ϕ2 (9)

Lemma 4.2. Given a signature Σ ∈ Sign the entailment relation `Σ has the properties (1)-(4) of definition 4.1 if and only if the extended entailment relation `PΣ satisfies the followingproperties for any Γ1,Γ2,Γ3 ∈ |Spec(Σ)|:

1. projection: Γ1 ∪ Γ2 `PΣ Γ2, i.e., especially Γ1 ⊇ Γ2 implies Γ1 `PΣ Γ2;

2. product property: if Γ1 `PΣ Γ2 and Γ1 `PΣ Γ3, then Γ1 `PΣ Γ2 ∪ Γ3;

3. compositionality: if Γ1 `PΣ Γ2 and Γ2 `PΣ Γ3, then Γ1 `PΣ Γ3;

4. functor property: if Γ1 `PΣ1Γ2, then for any φ : Σ1 → Σ2 in Sign, Sen(φ)(Γ1) `PΣ2

Sen(φ)(Γ2).

Proof. + Necessity:

11

Page 12: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

4 ENTAILMENT SYSTEMS

• Reflexivity: Special case of projection, taking Γ2 = {φ} and Γ1 ⊆ Γ2.

• Monotonicity: Special case of the projection Γ1 ∪ Γ2 `PΣ Γ1, taking Γ1 = {φ}, andassuming Γ1 `Σ φ and Γ2 ⊇ Γ1.

• Transitivity: Assuming compositionality, it follows directly if we set Γ1 = {ϕi | i ∈I},Γ = ∅ and Γ3 = {ψ}.• `-translation: Special case of the functor property, if Γ2 = {ψ}.

Note that for Γ1 = ∅ the projection property provides the identity property, i.e., Γ `PΣ Γfor any Γ ∈ Spec(Σ). Lemma 4.2 makes clear that the extended entailment relation `PΣdetermines a preorder category Ent(Σ).

Definition 4.3 (Extended Entailment). Given a signature Σ ∈ |Sign| we define the preordercategory Ent(Σ) of all Σ-specifications with entailment as follows: objects: are all specifica-tions Γ ∈ |Spec(Σ)|; morphisms: are all extended entailment relations Γ1 `PΣ Γ2; identities:are all entailments Γ `PΣ Γ, Γ ∈ |Spec(Σ)|; composition: is given by the compositionalityproperty in lemma 4.2.

The projection property in lemma 4.2 entails that Ent(Σ) is an extension of the categorySpec(Σ), i.e., for any signature Σ we obtain an embedding functor

em(Σ) : Spec(Σ)→ Ent(Σ) with em(Σ)(Γ) = Γ. (10)

If we consider the set of sentences provable from a specification Γ, i.e., if we set

clo(Σ)(Γ) = {ϕ ∈ Sen(Σ) | Γ `Σ ϕ}, (11)

we obtain a so-called closure functor from Ent(Σ) to Spec(Σ).

Proposition 4.4 (Galois Correspondence). Given a signature Σ ∈ |Sign|, the equations(10) and (11) define functors em(Σ) : Spec(Σ) → Ent(Σ) and clo(Σ) : Ent(Σ) → Spec(Σ),such that clo(Σ) is left-adjoint to em(Σ), i.e., for any specifications Γ,Γ1,Γ2 ∈ |Spec(Σ)| =|Ent(Σ)| we have:

1. em(Σ) functor: Γ1 ⊇ Γ2 implies Γ1 `PΣ Γ2;

2. clo(Σ) functor: Γ1 `PΣ Γ2 implies clo(Σ)(Γ1) ⊇ clo(Σ)(Γ2);

3. unit: Γ `PΣ clo(Σ)(Γ) in Ent(Σ);

4. counit: clo(Σ)(Γ) ⊇ Γ in Spec(Σ);

5. adjointness: Γ1 `PΣ Γ2 iff clo(Σ)(Γ1) ⊇ Γ2.

Ent(Σ)clo(Σ)

> // Spec(Σ)em(Σ)oo

Proof.

• em(Σ) functor : Directly from the projection property, assuming Γ1 ⊇ Γ2.

12

Page 13: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

4 ENTAILMENT SYSTEMS

• clo(Σ) functor : Assuming Γ1 `PΣ Γ2, we must show that clo(Σ)(Γ1) ⊇ clo(Σ)(Γ2). Tosee this, note that

clo(Σ)(Γ1) == {ϕ1 ∈ Sen(Σ) | Γ1 ` ϕ1} (by definition)⊇ {ϕ1 ∈ Sen(Σ) | Γ2 ` ϕ1} (Γ1 ` Γ2 and compositionality)= clo(Σ)(Γ2) (by definition)

• unit: It follows from the adjointness property below.

• co-unit: It follows from the adjointness property below.

• adjointness: Note that

Γ1 `PΣ Γ2

iff ∀ϕ ∈ Γ2 : Γ1 ` ϕiff {ψ ∈ Sen(Σ) | Γ1 ` ψ} ⊇ Γ2

iff clo(Σ)(Γ1) ⊇ Γ2

In the next steps we exploit the functor property in lemma 4.2 to gain a fully categoricalpresentation of the concept “entailment system”.

Proposition 4.5 (Entailment Functor). The mappings Spec : |Sign| → |PO| and Ent :|Sign| → |PRE| given by definition 3.3 and definition 4.3 respectively can be extended tofunctors Spec : Sign → PRE and Ent : Sign → PRE if we set for any φ : Σ1 → Σ2 in Signand for any Γ1 ∈ |Spec(Σ1)|: Spec(φ)(Γ1) = Ent(φ)(Γ1) = Sen(φ)(Γ1). In this way all thefunctors em(Σ) : Spec(Σ)→ Ent(Σ), Σ ∈ |Sign| define an indexed functor em : Spec⇒ Ent :Sign→ PRE.

Proof. Let φ1 : Σ1 → Σ2 and φ2 : Σ2 → Σ3 be arrows in Sign. Then the equationsSpec(φ1;φ2) = Spec(φ1);Spec(φ2) and Spec(idΣ) = idSpec(Σ) hold because of fact 3.5 and re-mark 3.6. On the other hand, the equations Ent(φ1;φ2) = Ent(φ1);Ent(φ2) and Ent(idΣ) =idEnt(Σ) follow from the fact that we are on top of (set-based) preorder categories, and the com-positionality and functor properties of lemma 4.2. The family of functors em(Σ),Σ ∈ |Sign|are natural with respect to the arrows in Sign because for each φ : Σ1 → Σ2 and Γ ∈ Spec(Σ1),[em(Σ1);Ent(φ)](Γ) = Sen(φ)(Γ) = [Sen(φ); em(Σ2](Γ).

Theorem 4.6 (Entailment Frames). A triple E = (Sign, Sen,`) is an entailment system iffthe 5-tuple

EF = (Sign, Spec, Ent, em, clo)

defines an indexed preorder frame, called the entailment frame for E .

Σ1

φ

��

Spec(Σ1)em(Σ1)

⊥ //

Spec(φ)

��

Ent(Σ1)clo(Σ1)oo

Ent(φ)

��Σ2 Spec(Σ2)

em(Σ2)

⊥ // Ent(Σ2)clo(Σ2)oo

13

Page 14: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

5 GENERAL LOGICS

Proof. It follows directly from propositions 4.5, 4.4 and lemma 4.2.

Note that the same comments made in remark 3.11 also apply here. Also, the conceptof π-institutions as originally introduced by Fiadeiro and Sernadas are essentially thesame as entailment systems. Only transitivity is formulated in a different but equivalentway (see [15, 16]). An abstract interpretation of π-institutions can be given in terms ofclosure operators, i.e., in terms of the functors em(Σ); clo(Σ) : Spec(Σ) → Spec(Σ). Thegeneralization of this abstraction step to arbitrary indexed frames based on the co-monadsgiven by the adjunctions fml(i) a sem(i) is approached in section 8.

5 General Logics

The concept of a general logic introduced in [36] combines the concepts of institution andentailment system. In this section we analize and discuss this concept in view of indexedframes.

Definition 5.1 (General Logic). A General Logic is a 5-tuple

L = (Sign, Sen,Mod,`, |=)

such that (Sign, Sen,`) is an entailment system; (Sign, Sen,Mod, |=) is an institution, andthe following soundness condition is satisfied for any Σ ∈ Sign, Γ ⊆ Sen(Σ), ϕ ∈ Sen(Σ)

Γ `Σ ϕ ⇒ Γ |=Σ ϕ

where Γ |=Σ ϕ iff mod(Σ)(Γ) ⊆ mod(Σ)(ϕ).

A logic is complete if, in addition, Γ `Σ ϕ ⇐ Γ |=Σ ϕ.

In view of the corresponding institutional frame IF = (Sign, Spec, Sub,mod, th) and thecorresponding entailment frame EF = (Sign, Spec, Ent, em, cl) the soundness condition meansthat Γ1 `PΣ Γ2 impliesmod(Σ)(Γ1) ⊆ mod(Σ)(Γ2) for any Σ ∈ Sign and any Γ1,Γ2 ∈ |Spec(Σ)|.That is for any Σ ∈ |Sign| the assignments Γ 7→ mod(Σ)(Γ) define a functor mod`(Σ) :Ent(Σ) → Sub(Σ) such that mod(Σ) = em(Σ);mod`(Σ). Since all the functors mod`(Σ) :Ent(Σ) → Sub(Σ) define an indexed functor mod` : Ent ⇒ Sub : Sign → Cat the soundnesscondition is equivalent to the existence of a factorization mod = em;mod` and the logicis complete if all the functors mod`(Σ) : Ent(Σ) → Sub(Σ) are full. To put things moreprecisely we introduce

Definition 5.2 (Indexed Logic). An Indexed Logic is a 8-tuple

IL = (Ind, Syn,Den, Log, sem, fml, log, sub)

such that:

+ (Ind, Syn,Den, sem, fml) is an indexed partial order frame frame;

+ (Ind, Syn, Log, log, sub) is an indexed preorder frame, and

+ there exists an indexed functor sem` : Log =⇒ Den : Ind → Cat such that sem =log; sem`

14

Page 15: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

6 LINEAR LOGIC AS AN INDEXED FRAME

An indexed logic is complete if, in addition, all the functors sem` : Log(i)→ Den(i) i ∈ |Ind|are full.

Theorem 5.3 (Indexed General Logics). A 5-tuple L = (Sign, Sen,Mod,`, |=) is a generallogic iff the 8-tuple

IL = (Sign, Spec, Sub,Ent,mod, th, em, cl)

defines an indexed logic.

Proof. This follows from theorems 3.10 and 4.6.

6 Linear Logic as an Indexed Frame

Below we make a detailed presentation of linear logic (actually a sublogic of it) as an IndexedFrame. The example is important because it shows a situation where the categories inducedby the indexes of a given category Ind are neither pre- or partial order categories.

Example 6.1 (Linear Logic). In this example we consider a substructural logic. We re-member that a sequent calculus presentation for the intuitionistic logic has some structuralrules. They are the rules of weakening, contraction, permutation and cut. A substructurallogic does not have all of these rules. Our example is the intuitionistic rudimentary linearlogic IRLL, which is a fragment of MILL (Multiplicative Intuitionistic Linear Logic), sincewe consider only the {⊗,(} fragment. In this logic we have a multiplicative conjunction ⊗and its adjoint, the linear implication (. The rules of its sequent calculus presentation areshown below.

identityA ` A

Γ1, A,B,Γ2 ` Cpermut-left

Γ1, B,A,Γ2 ` C

Γ1, A,B,Γ2 ` C⊗-left

Γ1, A⊗B,Γ2 ` C

Γ1 ` A Γ2 ` B ⊗-rightΓ1,Γ2 ` A⊗B

Γ1 ` A Γ2, B ` C(-left

Γ2, A( B,Γ1 ` C

Γ, A ` B(-right

Γ ` A( B

Γ ` AI-left

Γ, I ` AI-right` I

Γ1 ` A Γ2, A,Γ3 ` Bcut-rule

Γ2,Γ1,Γ3 ` B

The cut rule is admissible. This means that from cut-free proofs of Γ1 ` A and A,Γ2 ` B,we can obtain a cut-free proof of Γ1,Γ2 ` B. This result is called Haupsatz (firstly provedby Gentzen in 1936) and we recommend [18] for a detailed reference on its relation to LinearLogic. The Haupsatz can be also viewed as a process that from any proof of a sequent producesa cut-free proof of this very sequent. For example, in the proofs below, cut-elimination appliedto the first proof produces the second.

15

Page 16: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

6 LINEAR LOGIC AS AN INDEXED FRAME

A ` A B ` BA,B ` A⊗BA ` B( (A⊗B)

B ` B A⊗B ` A⊗BB( (A⊗B), B ` A⊗B

A,B ` A⊗B

(12)

A ` A B ` BA,B ` A⊗B (13)

There is a categorical way of reading proof-theoretical reductions. Formulas are inter-preted as objects, and logical connectives as functors. In IRLL, a sequent of the form∆1, . . . ,∆k ` B is interpreted as a morphism f from [[∆1]]⊗ . . .⊗ [[∆k]] into [[B]] in a suitablecategory C. The rules of the sequent calculus provide means to point out morphisms in anycategory C, equipped with special properties, used as semantics for the logic. The axiomA ` A is interpreted as the identity on the object [[A]]. I is the terminal object of the cate-gory. The empty tensor product (⊗) is I itself. Thus, axiom I-right is related to the identitymorphism on I. Given a morphism such as f : A ⊗ B → C, the rule (-right points outthe need of an adjoint morphism f : A → (B ( C). The existence of the morphism f mustbe provided by a natural bijection between HomC(A ⊗ B,C) and HomC(A,B ( C). Thecut has to be associated to the composition of morphisms. In fact, from the point of view ofmorphisms in the internal language of C, we would have the following proof term (tree)

f : [[Γ1]]→ [[A]] g : [[Γ2, A,Γ3]]→ [[B]]

(id[[Γ2]] ⊗ f ⊗ id[[Γ3]]); g : [[Γ2,Γ1,Γ3]]→ [[B]](14)

Thus, the corresponding proof term in the internal logic of C associated to proof (12) is

idA : A→ A idB : B → B

idA ⊗ idB : A⊗B → A⊗BidA ⊗ idB : A→ (B( (A⊗B))

idB : B → B idA⊗B : A⊗B → A⊗BevB,A⊗B : (B( (A⊗B))⊗B → A⊗B

( idA ⊗ idB ⊗ idB); evB,A⊗B : A⊗B → A⊗B

(15)

However, we also require that C is equipped with a kind of closedness property, thus

satisfying ( idA ⊗ idB)⊗ idB; evB,A⊗B = idA⊗B What the cut-elimination ensures is that thismorphism is equal to idA⊗B : A ⊗ B → A ⊗ B, which is pointed out by proof (13) and thefollowing correspondent proof term in the internal language of C:

idA : A→ A idB : B → B

idA ⊗ idB : A⊗B → A⊗B(16)

The cut-elimination is a recursively defined procedure that replaces any cut by cuts oflower degree of complexity. For example, the reduction from (17) to (18) used in thefirst proof yielding the second one corresponds to a case when the cut formula is a linearimplication.

Π1

∆1, α ` β

∆1 ` α( β

Π21

∆21 ` α

Π22

β,∆22 ` γ

∆21, α( β,∆22 ` γ

∆21,∆1,∆22 ` γ

(17)

16

Page 17: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

6 LINEAR LOGIC AS AN INDEXED FRAME

Π21

∆21 ` α

Π1

∆1, α ` β

∆21,∆1 ` β

Π22

β,∆22 ` γ

∆21,∆1,∆22 ` γ

(18)

The categorical interpretation of the logic IRLL must be done in a category having whatis required by the sequent calculus and the cut-elimination reductions. Of course the category1 (the category with one object and one moprhism) can be used as semantics. Any formula ismapped to the unique object inhabiting 1 and any morphism to the identity on this object.This is not a good semantics, since any sequent proved in the calculus is mapped to the samemorphism between the same formulas. On the other extreme we can interpret IRLL in Set,using the cartesian product to interpret ⊗ and the function space [[B]][[A]] to interpret A( B.This, however, is not a good semantics either, since the cartesian product has projectionsand we cannot derive in the sequent calculus any morphism from A⊗B in to B (or A). Sethas more morphisms and objects than IRLL is able to point out. On the other hand, thesyntactical category Proofs(Σ) made up of formulas built from a signature Σ and sequentsprovable in IRLL seems to have the intended semantics to interpret IRLL. In fact, the moreadequate semantics should be provided by the skeletal category of Proofs(Σ)3. In the casethat there are other mathematical structures adequate to provide semantics to IRLL we needa way to express this. Categorically we state that Proofs(Σ) is the free category in the subcategory of Cat satisfying the restriction imposed by IRLL. This also means that there is anadjunction between any category serving as semantics for IRLL and the category Proofs(Σ).When Σ is derived from a category C , we call Proofs(Σ) the internal language logic of C.In more detail, we have the following

Definition 6.2. A monoidal category is a category which has the structure of a monoid,that is, among the objects there is a binary operation which is associative and has an uniqueneutral or unit element. Specifically, a category C is monoidal if

¬ there is a (tensor product) bifunctor ⊗ : C× C→ C, where the images of object (A,B)and arrow (f, g) are written A⊗B and f ⊗ g, respectively.

­ there is an isomorphism αABC : (A⊗B)⊗C ∼= A⊗ (B⊗C) for arbitray objects A,B,Cin C, such that αABC is natural in A,B,C. In other words:

• α−BC : (− ⊗ B) ⊗ C ⇒ − ⊗ (B ⊗ C) is a natural transformation for arbitraryobjects B,C in C.

• αA−C : (A⊗−)⊗C ⇒ A⊗(−⊗C) is a natural transformation for arbitrary objectsA,C in C.

• αAB− : (A ⊗ B) ⊗ − ⇒ A ⊗ (B ⊗ −) is a natural transformation for arbitraryobjects A,B in C.

® there is an object I in C called the unit object (or simply the unit).

¯ for any object A in C, there are isomorphisms

λA : I ⊗A ∼= A and ρ : A⊗ I ∼= A,

3We remind the reader that a category is called skeletal if isomorphic objects are necessarily identical.

17

Page 18: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

6 LINEAR LOGIC AS AN INDEXED FRAME

such that λA and ρA are natural in A, i.e., both λ : I ⊗− ⇒ − and ρ : −⊗ I ⇒ − arenatural transformations.

satisfying the following commutative diagrams:

• unit coherence law

(A⊗ I)⊗B αAIB //

ρA⊗idB &&

A⊗ (I ⊗B)

idA⊗λBxxA⊗B

• associative coherence law

((A⊗B)⊗ C)⊗D α1 //

α3

��

(A⊗ (B ⊗ C))⊗D α2 // A⊗ ((B ⊗ C)⊗D)

α4

��(A⊗B)⊗ (C ⊗D) α5

// A⊗ (B ⊗ (C ⊗D))

where we have

α1def= αABC ⊗ idD α2

def= iαA(B⊗C)D

α3def= α(A⊗B)CD α4

def= idA ⊗ αBCD

α5def= αAB(C⊗D)

A monoidal category C with tensor product ⊗ is said to be symmetric if for every pair ofobjects A,B, there is an isomorphism ξAB : A⊗B ∼= B ×A that is natural in both A and Bsuch that the following diagrams are commutative:

• unit coherence for ξ

(A⊗ I)ξAI //

ρA##

(I ⊗A)

λA{{A

• associative coherence for ξ

(A⊗B)⊗ C αABC //

ξAB⊗id��

A⊗ (B ⊗ C)ξA(B⊗C)// (B ⊗ C)⊗A

αBCA

��(B ⊗A)⊗ C αBAC

// B ⊗ (A⊗ C)id⊗ξAC

// B ⊗ (C ⊗A)

A symmetric monoidal category is closed if for any object B, the functor (− ⊗ B) has aright adjoint (B( −). On a global level, this means that we have a natural bijection from

HomC(−⊗B,−) : Cop × C→ Set to HomC(−, B( −) : Cop × C→ Set

18

Page 19: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

6 LINEAR LOGIC AS AN INDEXED FRAME

with components

θAC : HomC(A⊗B,C)→ HomC(A,B( C)

Symmetric closed monoidal categories have all the categorical structure required to modelthe multiplicative fragment of intuitionistic linear logic.

A monoidal closed functor between monoidal closed categories is a triple⟨F, µunit, µ⊗

⟩,

where F : C→ D is a functor, together with two natural transformations µI : I ⇒ F (I) andµAB : F (A)⊗ F (B) ⇒ F (A⊗ B) satisfying some coherence diagrams (which we omit). F isstrict if µI and µAB are identities, for each A and B. A monoidal functor is symmetric if µcommutes with the symmetries ξF (A)F (B);µBA = µAB;F (ξAB) for all A and B.

A strong symmetric monoidal (closed) functor F between symmetric monoidal (closed)categories is a functor that strictly preserves the monoidal structure of the categories, thatis, F (A⊗B) = F (A)⊗′ F (B), F (I) = I ′, and hence F (A( B) = F (A)(′ F (B).

We call SMC the category whose objects are symmetric monoidal closed (SMC) categoriesand whose morphisms are symmetric monoidal closed functors.

Given any symmetric monoidal closed category C and any object A belonging to it, we caninterpret the proofs 12 and 13 above as morphism from A into A. The proof 13 is interpretedas the identity on A.

Rudimentary Linear Logic (RLL) is a propositional logic with binary connectives ⊗ and( and a logical constant I. RLL provides an internal logic for SMC (see [32]). This meansthat there are two (endo) functors L and K in SMC, such that, for each monoidal category M ,M ' K(L(M). Moreover, for each RLL Th(l) based on the language l, we have l ' L(K(l).Since these functors provide an equivalence of categories, we can see RLL as an IndexedLogic. The following Indexed Frame is used to define RLL as an Indexed Logic.

Definition 6.3.

RLL = 〈Ind,Proofs, Den, sem, fml〉

is given by:

• A category of signatures Ind;

• Proofs(i) is the category that has formulas of IRLL(i) as objects and proofs as mor-phisms. A proof of B from assumptions Γ0, . . . ,Γk in IRLL(i) is a morphism from[[Γ0]]⊗ . . .⊗ [[Γk]] to [[B]]. Equality of morphism is provided by proof-theoretical reduc-tions (cut-elimination) in the sequent calculus of IRLL.

• Den(i) is the (sub) category of symmetric monoidal categories having at least |i| distinct(possibly isomorphic) objects.

• sem(i) is the functor that maps a symmetric monoidal closed category into its skeletalcategory.

• fml(i) is the functor that maps any symmetric monoidal closed category into its internallanguage category.

The above example of an Indexed Logic does not consist of Indexed Ordered Frames.Neither A,B 6` A nor A,B 6` B hold. The syntax of the logic cannot be interprted in apreordered setting. From α ` β does not follow, in general, that α, γ ` β. That is, themonoidal structure cannot be, in general, described by a pre- or partial order structure. It

19

Page 20: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

7 GENERALIZED SKETCHES AS INDEXED FRAMES

is known that in IRLL there are tautologies that have infinitely many non-equivalent proofs.Thus, for an arbitrary i, Proofs(i) cannot be a pre-ordered category.

This view of a deduction pointing out a morphism in a category is deeply discussed in[14] and [23]. Lambek, see [25, 26, 27], seems to be the first to develop this idea followingMacLane’s coherence theorems (see [28]).

7 Generalized Sketches as Indexed Frames

Usually, only a logical system with “indexed semantics” gives rise to an Institution. Indexedsemantics separates strictly syntax from semantics and models are given by “interpretations”of the syntactic entities in a fixed “semantic universe” - the category Set in most cases.Model reduction is realized by simple composition of syntactic translations with semanticinterpretations and, since composition is associative, we get, on the global level, a modelfunctor.

In a logical system with “fibred semantics”, in contrast, syntactic and semantic entities livein the same universe/category and models are given by “instances”of syntactic entities, i.e.,by morphisms in the common category with syntactic entities as targets. Those “fibrationalapproaches” are quite common in software engineering (see, for example [13, 38]).

Model reduction in fibred semantics is a bit more complicated and not that nicely behav-ing. Model reduction is realized by pullback construction and we have to rely on an arbitrarybut fixed choice of pullbacks for the common category to define reduction functors. However,what ever choice we make, the composition of chosen pullbacks will be only associative upto isomorphism thus we get, on the global level, only a model pseudo functor for a fixedchoice of pullbacks. For other fixed choices of pullbacks we will get other equivalent modelpseudo functors.

Indexed frames abstract from single sentences and single models and allow to describetransformations of specifications or model classes, respectively, which may be not based onpoint-to-point transformations of single sentences or single models, respectively.

As a paradigmatic example for logical systems with fibred semantics we discuss in thissection generalized sketches [6, 10, 33] with fibred semantics as they have been presented in[13]4. We show that generalized sketches give rise to Indexed Partial Order Frames. Theexample exceeds the corresponding result for institutions in two aspects. First, we do havesyntax functors with target Cat instead of Set. Second, in contrast to institutions, the idea todescribe model extension simply as the inverse of model reduction doesn’t provide functorialityon the level of indexed frames. To overcome this obstacle we have to give up the choice ofpullbacks (see Remark 7.7).

Applications of generalized sketches in software engineering are usually based on the cat-egory Graph of directed (multi)graphs [10, 12, 11, 38]. Generalized sketches, however, are notrestricted to graphs only. In fact, they are generic in the sense that we can define for anybase category Base with pullbacks a variety of generalized sketch systems of different types,as we will outline in the rest of this section.

In category theory we have sketches of different types like linear sketches, finite productsketches and finite limit sketches, for example [3]. And in software engineering we havedifferent types of diagrammatic specification techniques like ER diagrams, class diagrams,

4The interested reader should consult [13] for a more detailed software engineering oriented motivation andfor a short history of generalized sketches.

20

Page 21: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

7 GENERALIZED SKETCHES AS INDEXED FRAMES

relational database schemes, for example. A meta-signature fixes the type of diagrammaticspecification techniques we are going to work with.

Definition 7.1 (Meta-Signature). A meta-signature over Base is given by a category ΠΠΠ ofpredicate symbols and dependency arrows and a functor α : ΠΠΠ→ Base. For an object P ∈ |ΠΠΠ|,the Base-object α(P ) is called the arity (shape) of P , and for a dependency arrow r : Q a Pin ΠΠΠ, α(r) : α(Q)→ α(P ) is called an arity substitution.

A dependency r : Q a P states that the concept/property P depends on (is based on) theconcept/property Q. As an example we can consider a dependency r : [commsqu] a [pullback]stating that the concept ”pullback” is based on the concept ”commutative square”. Logically,dependencies correspond to implications α(P ) ⇒ α(Q) with single predicative expressionsα(P ) and α(Q) as premise and conclusion, respectively (compare Definition 7.8).

The category Base is our common category for syntax and semantics. Considering anobject in Base as a ”signature” we can define a corresponding category of atomic constraints.

Definition 7.2 (Category of Atomic Constraints). For any object G ∈ |Base| we define thecategory Fm(G) of all atomic constraints on G as follows:

+ objects: all pairs (P, d) with P ∈ ΠΠΠ and a morphism d : α(P )→ G in Base;

+ morphisms: all labeled sequent’s r : (Q, e) a (P, d) with r : Q a P a dependencyarrow in ΠΠΠ and e = α(r); d;

+ identities: id(P,d)def= (idP : (P, d) a (P, d)) for all atomic constraints (P, d);

+ composition: the composition of any two labeled sequent’s r : (Q, e) a (P, d) andp : (P, d) a (R, c) is given by the sequent r; p : (Q, e) a (R, c).

Associativity of composition in Base ensures that composition of labeled sequent’s is in-deed defined. Moreover, the identity and associativity law is ensured by the identity andassociativity laws in Base and ΠΠΠ, respectively, and by the functor property of α, thus we getindeed a category Fm(G).

Note, that we could say that the labeled sequent r : (Q, e) a (P, d) is produced byapplying the dependency/rule r : Q a P to (P, d). In this sense, predicate dependencies serveas inference rules (see also Remark 7.11).

Now we are going to define a syntax functor on the abstraction level of ”sentences”.For a morphism φ : G → H in Base the corresponding translation of atomic constraintsis simply given by post-composition: For any atomic constraint (P, d) in Fm(G) we defineFm(φ)(P, d) = (P, d;φ) and for any labeled sequent r : (Q, e) a (P, d) in Fm(G) we geta labeled sequent Fm(φ)(r) = r : (Q, e;φ) a (P, d;φ) in Fm(H) since e = α(r); d triviallyimplies e;φ = α(r); (d;φ). In this way a signature morphism φ : G→ H gives rise to a functorFm(φ) : Fm(G)→ Fm(H) between the corresponding categories of atomic constraints.

Due to associativity of composition in Base, we have for any morphisms φ : G → H andψ : H → K in Base that Fm(φ;ψ) = Fm(φ);Fm(ψ) such that the assignments G 7→ Fm(G)and φ 7→ Fm(φ) define indeed a syntax functor Fm : Base → Cat which has, however, thecategory Cat as target and not the category Set as in institutions.

Now we take the abstraction step from ”sentences” to ”specifications”.

Definition 7.3 (Partial Order Category of Sketches). A (generalized) sketch S with baseG ∈ |Base| is a subcategory S ⊆ Fm(G)5. By Sk(G) we denote the partial order category

5Note, that [13] works actually only with sketches closed under dependencies (compare Example 7.11).

21

Page 22: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

7 GENERALIZED SKETCHES AS INDEXED FRAMES

where the objects are all sketches on G, and the arrows are all the inverse category inclusionsS1 ⊇ S2.

For a signature morphism φ : G → H the translation of sketches is defined as follows:For any sketch S with base G we denote by Sk(φ)(S) the smallest subcategory of Fm(H)containing the image Fm(φ)(S) of S w.r.t. the functor Fm(φ). Obviously, the assignmentsS 7→ Sk(φ)(S) define a functor Sk(φ) : Sk(G) → Sk(H) between the partial order categoriesSk(G) and Sk(H).

For any morphisms φ : G→ H and ψ : H → K in Base Fm(φ;ψ) = Fm(φ);Fm(ψ) entailsSk(φ;ψ) = Sk(φ);Sk(ψ) thus we get finally the intended syntax functor on the abstractionlevel of specifications.

Corollary 7.4 (Sketch Functor). The assignments G 7→ Sk(G) and φ 7→ Sk(φ) define afunctor Sk : Base→ Cat.

An instance of a signature G ∈ |Base| is given by a ”semantic” object A ∈ |Base| and amorphism a : A→ G. That is, the category of instances of G is a slice category6 Inst(G) =Base↓G. For any fixed choice of pullbacks in Base the assignments G 7→ Inst(G) can beextended to a pseudo functor Inst : Baseop → Cat (compare [13]). Since those pullbackbased model pseudo functors don’t give rise straightforwardly to denotational functors on thelevel of indexed frames (see Remark 7.7) we skip them here and continue to define directlydenotational functors.

Definition 7.5 (Partial Order Category of Subcategories of Instances). For any base objectG ∈ Base the partial order category Sub(G) has as objects all full subcategories M ⊆ Base↓Gand as arrows all inclusion functors M1 ⊆ M2.

For any morphism φ : G → H in Base we can define a ”pullback complement” functorPC(φ) : Sub(G) → Sub(H) as follows: For any full subcategory M ⊆ Base↓G the categoryPC(φ)(M) is the full subcategory of Base↓H given by all pullback complements of instances inM: (B, b) ∈ |PC(φ)(M)| iff there exists an instance (A, a) ∈ |M| and a morphism f : A → Bsuch that (a, f) is a pullback of (φ, b) in Base (see the diagram below). We call the pair((A, a), f) a witness for (B, b) ∈ |PC(φ)(M)|.

Obviously, M1 ⊆ M2 implies PC(φ)(M1) ⊆ PC(φ)(M2) thus we obtain indeed a functorPC(φ) : Sub(G)→ Sub(H).

For any morphisms φ : G → H and ψ : H → K in Base we obtain PC(φ;ψ) =PC(φ);PC(ψ): For any M ∈ Sub(G) it holds that

(PC(φ);PC(ψ))(M) = PC(ψ)(PC(φ)(M)) ⊆ PC(φ;ψ)(M)

since the composition of pullbacks is a pullback again.

Af//

a��

h(=f ;g)

''B g

//

b��

C

c��

Gφ //

φ;ψ

77Hψ // K

6We remind that slice category Base↓G has pairs (A, a) with a : A → G as objects, and arrows f : A → Bin Base such that f ; b = a as morphisms.

22

Page 23: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

7 GENERALIZED SKETCHES AS INDEXED FRAMES

The inverse inclusion PC(φ;ψ)(M) ⊆ (PC(φ);PC(ψ))(M) = PC(ψ)(PC(φ)(M)) is en-sured by pullback decomposition: Assume (C, c) ∈ |PC(φ;ψ)(M)| with witness ((A, a), h).We consider an arbitrary pullback (b, g) of (ψ, c). For the unique f : A → B with f ; g = hand f ; b = a;φ we know that (a, f) is a pullback of (φ, b) thus we get (B, b) ∈ |PC(φ)(M)| withwitness ((A, a), f) and thus, finally, (C, c) ∈ |PC(ψ)(PC(φ)(M))| with witness ((B, b), g).

Corollary 7.6 (Denotational Functor). The assignments G 7→ Sub(G) and φ 7→ PC(φ)define a functor Sub : Base→ Cat.

Remark 7.7 (Functoriality of Pullback Complements). Functoriality is based on two argu-ments. First, that the composition of pullbacks is a pullback again. Second, that the result-ing pullback (a, f) of (φ, b), in the proof above, entails (B, b) ∈ |PC(φ)(M)|. Both argumentsfail for a fixed choice of pullbacks. First, the composition of chosen pullbacks isn’t nec-essarily a chosen one. Second, the pullback (a, f) of (φ, b) may be not a chosen one, i.e.,(B, b) /∈ Inst(φ)−1(A, a) for the corresponding pseudo functor Inst : Base→ Cat.

To simulate the effect of PC(φ) by means of Inst(φ), i.e., to abstract from the choiceof pullbacks, we have to consider the closure M of M under isomorphisms. We get thenPC(φ)(M) = Inst(φ)−1(M).

Before defining satisfaction we have to fix a semantics for the predicate symbols in ourmeta-signature. Dependencies represent requirements for the relations between predicateswhich should be met by any semantics.

Definition 7.8 (Semantics of Meta-signature). A semantic interpretation of a meta-signatureα : ΠΠΠ → Base is a mapping [[..]], which assigns to each predicate symbol P a set [[P ]] ⊆|Base↓α(p)| of valid instances, where [[P ]] is assumed to be closed under isomorphisms.

The semantic interpretation is consistent if for any dependency arrow r : Q a P in ΠΠΠ, anyinstance τ : O → α(P ) of P , and any pullback (τ∗, µ) of (α(r), τ) we have that (O, τ) ∈ [[P ]]implies (O∗, τ∗) ∈ [[Q ]]. Below we will assume consistency by default.

O∗µ //

τ∗

��

Od′ //

τ��

A

a

��α(Q)

α(r) //

e

99α(P )d // G

Now we can define satisfaction of atomic constraints in semantic instances.

Definition 7.9 (Satisfaction relation). Let a : A→ G be an instance of an object G in Base.We say that this instance satisfies an atomic constraint (P, d) over G and write (A, a) |=G

(P, d), iff (O, τ) ∈ [[P ]] for a pullback (τ, d′) of (d, a) (see the diagram in Definition 7.8).

Note, that the definition of satisfaction is independent of the representative (τ, d′) since[[P ]] is assumed to be closed under isomorphisms.

Since pullbacks compose, the consistency assumption ensures soundness w.r.t. inference(see the diagram in Definition 7.8): If (A, a) |=G (P, d) and r : (Q, e) a (P, d) is a labeledsequent, then (A, a) |=G (Q, e).

Composition and decomposition of pullbacks provide also a satisfaction condition forfibred semantics.

23

Page 24: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

7 GENERALIZED SKETCHES AS INDEXED FRAMES

Corollary 7.10 (Satisfaction Condition). For any morphism φ : G→ H in Base, any instanceb : B → H of H, any pullback (a : A → G, f : A → B) of (φ, b), and any atomic constraint(P, d) on G we have

(A, a) |=G (P, d) iff (B, b) |=H (P, d;φ).

Od′ //

τ��

Af //

a

��

B

b��

α(P )d //

d;φ

66Gφ // H

The implication from left to right is ensured by pullback composition and the implicationfrom right to left by pullback decomposition, respectively.

Satisfaction gives rise to adjoint functors similar to institutional frames: For any baseobject G in Base we obtain a functor inst(G) : Sk(G)→ Sub(G) where for any sketch S withbase G the category inst(G)(S) is the full subcategory induced by those instances in |Base↓G|that satisfy all the atomic constraints in S, i.e.,

|inst(G)(S)| def= {(A, a) ∈ |Base↓G| | ∀(P, d) ∈ |S| : (A, a) |=G (P, d)}. (19)

Analogously, we obtain a functor sk(G) : Sub(G) → Sk(G) where for any full subcategoryM ⊆ Base↓G of instances, the category sk(G)(M) is the full subcategory of Fm(G) given bythose atomic constraints which are satisfied by all instances in M, i.e., we have

|sk(G)(M)| def= {(P, d) ∈ |Fm(G)| | ∀(A, a) ∈ |M| : (A, a) |=G (P, d)}. (20)

Remark 7.11 (Closed Sketches). Note, that due to soundness, all the sketches sk(G)(M) areclosed under dependencies.

A sketch S onG is said to be closed under dependencies if (P, d) in S entails also (Q,α(r); d)and r : (Q,α(r); d) a (P, d) in S for all dependency arrows r : Q a P in ΠΠΠ. More abstractly,this means that the projection functor dom : S → ΠΠΠ with dom(P, d) = P and dom(r :(Q,α(r); d) a (P, d)) = (r : Q a P ) is a split op-fibration - an observation communicated tothe first author by Zinovy Diskin in 2006.

The same argumentation as in Proposition 3.4 shows that the functor sk(G) is left-adjointto the functor inst(G), written sk(G) a inst(G), for any G ∈ Base.

Finally, a similar argumentation as in Lemma 3.7 shows that our definition of pullbackcomplement functors and the satisfaction condition in Corollary 7.10 ensure that the indexedframe condition

inst(G);PC(φ) = Sk(φ); inst(H) holds for all φ : G→ H in Base

Summarizing, we can present generalized sketches in a new perspective.

Theorem 7.12 (Sketch Frame). For any category Base with pullbacks, any meta-signatureα : ΠΠΠ → Base, and any consistent semantic interpretation [[..]] of α : ΠΠΠ → Base the 5-tuple (Base, Sk, Sub, inst, sk) is an indexed partial order frame, called the sketch frame

24

Page 25: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

8 INDEXED CLOSURE OPERATORS

for (Base,ΠΠΠ, α, [[..]]).

G

φ

��

Sk(G)inst(G)

⊥ //

Sk(φ)��

Sub(G)sk(G)oo

Sub(φ)(=PC(φ))��

H Sk(H)inst(H)

⊥ // Sub(H)sk(H)oo

Besides shedding new light on generalized sketches this result gives another evidence thatthe concept Indexed Frame is an appropriate abstraction to present logical systems in auniform way. Indexed Frames comprise not only institutions and entailment systems butalso pseudo institutions with a model pseudo functor defined by chosen pullbacks. The lastobservation in Remark 7.7 may even open a way to prove a corresponding result for arbitrary,and not only pullback based, model pseudo functors.

8 Indexed Closure Operators

In the preceding sections of this article we have seen that adjunctions can be taken as thefundamental concept in defining a Logical Framework. Indexed Partial Order and IndexedPreorder Frames have been shown to be general enough to express uniformly the most repre-sentative approaches to General Logic definitions.

This is one side of the history. Tightly related to adjunctions are co-monads, also calledco-triples. In fact, every adjunction gives rise to two co-monads, while there are at least twoways of obtaining a pair of adjoint functors from a co-monad.

On the other hand, co-monads are naturally connected to central algebraic and logicalconcepts. Co-monads appear, for example, as the categorical counterpart of logical closureoperators, as discussed below. Based on this observation we investigate in this section howco-monads relate to the main logical concepts in our approach.

Categorically, definition 2.1 can be reformulated as the very definition of a co-monad (see[2] as a quite comprehensive text on the subject).

Definition 8.1. A co-monad G = (G, ε, δ) in B is an endofunctor G : B → B together withtwo natural transformations ε : G ⇒ idB and δ : G ⇒ G2 making the following diagramscommute:

Gδ //

�

G2

G��

G

=~~

=

�

G2δ�G// G3 G G2

G�εoo

ε�G// G

In the diagrams above, Gn means G composed with G itself n times. The component ofG � ε at b ∈ |B| is ε(G(b)), whereas G(ε(b)) is the component of ε �G at b. Similarly for δ.

If B is a preorder category then both diagrams trivially commute and we obtain thefollowing categorical reformulation of closure operators as specializations of the categoricalconcept of co-monads to preorder categories.

Definition 8.2. A co-closure operator on a preorder category P is a co-monad (cl, ε, δ),where cl : P→ P is a functor, and ε : cl⇒ idP and δ : cl⇒ cl2 natural transformations.

25

Page 26: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

8 INDEXED CLOSURE OPERATORS

Note that the above definition is actually a closure operator on the reverse preordering inthe sense of definition 2.1. Thus, from now on, whenever we mention the expression closureoperator, we ask the reader to reverse the preorder (if necessary).

Due to the co-monad conditions we have for each b ∈ |P| that δ(b); ε(cl(b)) = idcl(b). Theassumption that P is a preorder ensures, in addition, ε(cl(b)); δ(b) = idcl2(b) so that δ(b) isan isomorphism with inverse ε(cl(b)).

cl

=~~

=

�

cl cl2cl�εoo

ε�cl// cl

Corollary 8.3. For any closure operator (cl, ε, δ), δ : G ⇒ G2 is a natural isomorphism.In case P is a partial order category we have, moreover, that cl = cl2 and δ is the identicalnatural transformation on cl = cl2.

The following fact will be helpful as we proceed.

Fact 8.4. Let F : C→ B and U : B→ C be functors. Then F a U with unit η : idC ⇒ F ;Uand co-unit ε : U ;F ⇒ idB if and only if

(U � η); (ε � U) = idU (21)

(η � F ); (F � ε) = idF (22)

One of the most fundamental facts about co-monads is provided by the following factdiscovered by P. Huber [21].

Fact 8.5. Let U : B→ C have a left adjoint F : C→ B with unit η : idC ⇒ F ;U and co-unitε : U ;F ⇒ idB. Then (U ;F, ε, U � η � F ) is a co-monad on B.

BU // C

IdC((

F ;U

66�� η CF // B

The fact above specializes for preorder categories to the well-known fact that any Galoiscorrespondence provides a closure operator and this specialization can be directly applied toindexed preorder frames.

Proposition 8.6. Given an Indexed Frame IF = (Ind, Syn,Den, sem, fml) with Syn :Ind→ PRE, we have for each i ∈ |Ind|, a closure operator (cl(i), ε(i), δ(i)) on Syn(i) given bythe functor cl(i) = sem(i); fml(i) : Syn(i) → Syn(i) together with natural transformations

ε(i) : cl(i) ⇒ idSyn(i) and δ(i)def= sem(i) � η(i) � fml(i) : cl(i) ⇒ cl(i)2. The functor cl(i) is

called the “logical closure operator” at index i.

Corollary 8.7. Let IF = (Ind, Spec, Sub,mod, th) and EF = (Sign, Spec, Ent, em, clo) berespectively institutional and entailment frames. Then for each Σ ∈ |Sign|,

(cl|=(Σ), ε|=(Σ), δ|=(Σ)) and (cl`(Σ), ε`(Σ), δ`(Σ))

are respectively closure operators, where:

26

Page 27: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

8 INDEXED CLOSURE OPERATORS

+ cl|=(Σ) = mod(Σ); th(Σ) : Spec(Σ)→ Spec(Σ).

+ cl`(Σ) = em(Σ); clo(Σ) : Spec(Σ)→ Spec(Σ).

+ ε|=(Σ) and ε`(Σ) are, respectively, the co-units of propositions 3.4 and 4.4.

+ δ|=(Σ) : cl|=(Σ)⇒ cl|=(Σ)2 and δ`(Σ) : cl`(Σ)⇒ cl`(Σ)2

In order to motivate the following definition, consider an institutional frame IF andits logical closure operators cl|=(Σ) for each index Σ ∈ |Sign|. From the very fact thatcl|=(Σ) is a closure operator on Spec(Σ), we would consider to define a kind of indexedstructure of the form (Sign, Spec, cl|=, ε|=, δ|=), where Spec : Sign→ PO is an indexed category,and, for each index Σ ∈ |Σ|, (cl|=(Σ), ε|=(Σ), δ|=(Σ)) is a closure operator on Spec(Σ). Wecannot expect, however, that the component functors cl|=(Σ) establish an indexed functorcl|= : Spec⇒ Spec : Sign→ PO, since there is the well-known phenomenon that the syntactictranslation of a closed set of sentences is, in general, not closed itself. In fact, for anyinstitutional frame IF = (Sign, Spec, Sub,mod, th), each morphism φ : Σ1 → Σ2 in Sign, andeach Γ ∈ Spec(Σ1), for example, we don’t get an identity but an inverse inclusion

cl|=(Σ2)(Spec(φ)(Γ)) ⊇ Spec(φ)(cl|=(Σ1)(Γ)),

that is a “comparison morphism” in Spec(Σ2). To reflect this phenomenon categorically wehave to use lax indexed functors.

Definition 8.8 (Lax Indexed Functor). A lax indexed functor ζ : C<

=⇒ D from an indexedcategory C : Ind→ Cat to an indexed category D : Ind→ PRE is given by the following dataand operations:

+ for each i ∈ |Ind| a functor ζ(i) : C(i)→ D(i);

+ for each σ : i → j in Ind and the corresponding two functors C(σ) : C(i) → C(j)and D(σ) : D(i) → D(j) , a comparison cell (a natural transformation) ζ(σ) :C(σ); ζ(j) =⇒ ζ(i);D(σ) : C(i)→ D(j)

i

σ

��

C(i)

<C(σ)

��

ζ(i) // D(i)

D(σ)��

j C(j)

ζ(σ)

3;

ζ(j)// D(j)

Remark 8.9 (Uniqueness of Comparison Cells). Note, that there can be at most one naturaltransformation ζ(σ) since D(j) is a preorder category. In the same way, the usual coherencecondition for lax indexed functors is also trivially satisfied. That is, for any σ : i → j andτ : j → k in Ind we have ζ(σ; τ) = (C(σ) �ζ(τ)); (ζ(σ) �D(τ)) since D(k) is preorder category.

i

σ

��

C(i)

<C(σ)

��

ζ(i) // D(i)

D(σ)

��

C(i)

C(σ;τ)

��

ζ(i) // D(i)

D(σ;τ)

��

j

τ

��

C(j)

<

ζ(σ)

3;

ζ(j) //

C(τ)��

D(j)

D(τ)��

=

k C(k)

ζ(τ)

3;

ζ(k)// D(k) C(k)

ζ(k)//

ζ(σ;τ)

<

;C

D(k)

27

Page 28: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

8 INDEXED CLOSURE OPERATORS

Lemma 8.10 (Local Adjointness and Lax). Let

IF = (Ind, Syn,Den, sem, fml)

be an indexed frame with Syn : Ind → PRE. Then, the family of functors fml(i), i ∈ |Ind|can be extended to a lax indexed functor fml : Den

<=⇒ Syn.

Proof. First we have to show that for each σ : i → j there is a comparison cell fml(σ) :Den(σ); fml(j)⇒: fml(i);Syn(σ) : Den(i)→ Syn(j).

i

σ

��

Den(i)

<Den(σ)

��

fml(i) // Syn(i)

Syn(σ)

��j Den(j)

fml(σ)

2:

fml(j)// Syn(j)

Now, note that, since fml(i) a sem(i), fml(j) a sem(j) by assumption, we have, forinstance, the unit ηi : idDen(i) ⇒ fml(i); sem(i) and co-unit εj : sem(j); fml(j) ⇒ idSyn(j),as depicted by the diagrams below, where f : a → b is an arrow in Den(i) and g : c → d inSyn(j).

a

f

��

a

f

��

η(i)(a) // sem(i)(fml(i)(a))

sem(i)(fml(i)(f))��

b bη(i)(b)

// sem(i)(fml(i)(b))

c

g

��

fml(j)(sem(j)(c))

fml(j)(sem(j)(f))

��

ε(j)(c)// c

g

��d fml(j)(sem(j)(d))

ε(j)(d)// d

Thus, we define fml(σ) as

fml(σ)def= (ηi �Den(σ) � fml(j)); (fml(i) � Syn(σ) � ε(j))

which is easily seen to be well-defined by pasting together the following two-cells:

Den(i)

Id ,,

fml(i);sem(i)22�� η(i) Den(i)

Den(σ)// Den(j)fml(j)// Syn(j)

and

Den(i)fml(i) // Syn(i)

Syn(σ)// Syn(j)

sem(j);fml(j),,

Id

22�� ε(j) Syn(j)

Note that this pasting is well-defined because, by assumption, we have Syn(σ); sem(j) =sem(i);Den(σ).

28

Page 29: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

9 FROM INDEXED CLOSURE OPERATORS TO INDEXED FRAMES

We can define now an (abstract) logic also by means of indexed closure operators.

Definition 8.11. An Indexed Closure Operator is a structure of the form ICO =(Ind, Syn, cl, ε, δ), with Syn : Ind → PRE an Indexed Category, cl : Syn

<=⇒ Syn a Lax

Indexed Functor, and for each i ∈ |Ind| natural transformations ε(i) : cl(i) ⇒ idSyn(i), δ(i) :cl(i)⇒ cl(i)2 constituting a closure operator on Syn(i):

Syn(i)cl(i) //

Syn(σ)��

Syn(i)

Syn(σ)��

Syn(j)cl(j)

//cl(σ)

5=

Syn(j)

Since the composition of an indexed functor and a lax indexed functor results again ina lax indexed functor, we obtain by proposition 8.6 and lemma 8.10 the main result of thissection.

Theorem 8.12. Any indexed frame IF = (Ind, Syn,Den, sem, fml) with Syn : Ind→ PREdefines an indexed closure Operator (Ind, Syn, cl, ε, δ).

Proof. According to proposition 8.6 we have for each i ∈ |Ind| a closure operator (cl(i), ε(i), δ(i))on Syn(i) with a functor cl(i) = sem(i); fml(i) : Syn(i) → Syn(i) and natural transfor-

mations ε(i) : cl(i) ⇒ idSyn(i) and δ(i)def= sem(i) � η(i) � fml(i) : cl(i) ⇒ cl(i)2. More-

over, we have, according to lemma 8.10 for each σ : i → j in Ind a natural transformationfml(σ) : Den(σ); fml(j) ⇒ fml(i);Den(σ). This allows us to define the required naturaltransformation cl(σ) : Syn(σ); cl(j)⇒ cl(i);Syn(σ) by

cl(σ)def= sem(i) � fml(σ)

i

σ

��

Syn(i)

=Syn(σ)��

sem(i) // Den(i)

<Den(σ)

��

fml(i) // Syn(i)

Syn(σ)

��j Syn(j)

sem(j)// Den(j)

fml(σ)

2:

sem(j)// Syn(j)

Note, that cl(σ) becomes indeed a natural transformation form Syn(σ); cl(j) to cl(i);Syn(σ)since we have, by assumption, Syn(σ); sem(j) = sem(i);Den(σ).

Theorem 8.12 can be applied to Institutional and Entailment Frames providing the well-known semantic or syntactic logical consequence operator, respectively (see corollary 8.7).

9 From Indexed Closure Operators to Indexed Frames

Given a co-monad there are (possibly) many ways of factoring it as adjoint pairs. Twocanonical constructions arise from a co-monad as adjoint pairs — the Kleisli and the Eilenberg-Moore constructions. The former is initial and the latter is final in the category of all suchfactorizations. For quasi-idempotent co-monads (G2 ∼= G), as in case of indexed preorderframes, both constructions are equivalent. Let us briefly describe these constructions focusingon the logical meaning they have in the context of Indexed Frames.

The following definition can be found, for instance, in [2, 24, 3].

29

Page 30: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

9 FROM INDEXED CLOSURE OPERATORS TO INDEXED FRAMES

Definition 9.1 (Kleisli Category). Given a co-monad G = (G, ε, δ) on B, the Kleisli categoryis the category K(G), having the same objects of B as its objects. Morphisms from a to b areexactly all the morphisms from G(a) to b in B. For a morphism f : G(a) → b in B we willindicate by fK : a→ b its interpretation as a ”Kleisli morphism”, i.e., as a morphism in K(G).The identical morphism from a to a in K(G) is given by the morphism ε(a) : G(a)→ a, i.e.,

idadef= ε(a)K . The composition of Kleisli morphisms fK : a→ b and gK : b→ c is defined by

fK ; gKdef= (δ(a);G(f)K ; gK) : a→ c.

Gaδ(a) // GGa

Gf // Gbg // c

Remark 9.2. Note, that K(G) becomes a preorder category if B is a preorder category. If Bis a partial order category, however, K(G) will be, in general, only a preorder category.

Example 9.3 (Theory Presentations). In an Institutional Frame IF , the Kleisli categoryK(cl|=(Σ)) for each Σ ∈ |Sign| is the category of Theory Presentations Γ ∈ |Spec(Σ)|, andthere is a morphism from Γ ∈ |Spec(Σ)| into ∆ ∈ |Spec(Σ)| iff cl|=(Σ)(Γ) ⊇ ∆. In otherwords, Γ |=Σ ∆. This category is well-known for the algebraic logicians. It is worth noticingthat, since there is at most one morphism from Γ into ∆, they are isomorphic as objects inK(cl|=(Σ)), whenever they are logically equivalent, that is Γ |=Σ ∆ and ∆ |=Σ Γ.

On the other hand, theories are captured by the following construction [2, 24, 3].

Definition 9.4 (Eilenberg-Moore Category). Also known as the category of co-algebras fora co-monad, the Eilenberg-Moore construction BG for a co-monad G = (G, ε, δ) on B hasG-algebras as objects, which are pairs (a, α), with α : a→ G(a) a morphism in B, as objectssatisfying the following axioms, for each a ∈ |B|:

aα //

=

Ga

ε(a)

��

aα //

�

Ga

δ(a)��

a GaGα// GGa

Note that if B is a preorder category, then the axioms above are trivially satisfied. Nowa morphism between G-algebras (a, α) and (b, β) is any morphism f : a → b in B for which,the following diagram commutes:

a

f��

α // Ga

Gf��

bβ// Gb

The composition in BG is provided by the composition on B itself.

Example 9.5 (Theories). In an Institutional Frame IF , the Eilenberg-Moore category

Spec(Σ)cl|=(Σ)

for each Σ ∈ |Sign|, is the category of Theories, i.e., of sets of sentences satisfying the “closed-ness condition” ∆ ⊇ cl|=(Σ)(∆), i.e., satisfying the condition ∆ = cl|=(Σ)(∆), since we havecl|=(Σ)(Γ) ⊇ Γ for all sets of sentences. In such a way, ∆ ⊇ Γ means also cl(Σ)(∆) ⊇ cl(Σ)(Γ)

for theories ∆ and Γ thus Spec(Σ)cl|=(Σ) is indeed the full subcategory of Spec(Σ) given byall theories.

30

Page 31: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

9 FROM INDEXED CLOSURE OPERATORS TO INDEXED FRAMES

The above pair of examples on Kleisli and Eilenberg-Moore constructions show equivalentcategories. For closure operators, in general, both constructions provide equivalent categoriesthus we can concentrate on one of these constructions. We will look now at the adjunctionprovided by the Kleisli construction.

Proposition 9.6 (Kleisli Functors). For any co-monad G = (G, ε, δ) on B the assignmentsa 7→ a and (f : a→ b) 7→ ((ε(a); f)K : a→ b) define a functor UG : B→ K(G).

a

f��

Gaε(a) // a

f��

b b

Moreover, the assignments a 7→ G(a) and (gK : a → b) 7→ (δ(a);G(g) : G(a) → G(b))define a functor FG : K(G)→ B

Gaδ(a) // GGa

Gg��

Ga

g��

Gb b

left-adjoint to UG, FG a UG, and such that UG;FG = G.

BUG

⊥ // K(G)FGoo

ε : UG;FG ⇒ idB is the co-unit and the unit ηG : idK(G) ⇒ FG;UG is given by ηG(a) =

(idKG(a) : a→ G(a)) for each a in K(G).

Finally, the co-monad that we construct due to fact 8.5 out of the adjunction (FG, UG, ηG, ε)is exactly the original co-monad (G, ε, δ), i.e., in addition to G = UG;FG we have alsoδ = UG � ηG � FG.

Example 9.7 (Semantical Entailment). For an Institutional Frame IF , the functor Ucl|=(Σ) :

Spec(Σ) → K(cl|=(Σ)) is the identity on objects and assigns to each inverse inclusion Γ ⊇∆ the semantical entailment Γ |=Σ ∆. And, the functor Fcl|=(Σ) : K(cl|=(Σ)) → Spec(Σ)

translates a semantical entailment Γ |=Σ ∆ into an inverse inclusion cl|=(Σ)(Γ) ⊇ cl|=(Σ)(∆)between the corresponding theories.

For preorder categories proposition 9.6 allows to construct for any closure operator aGalois correspondence that defines exactly this closure operator. And this specialization canbe directly applied to Indexed Closure Operators.

Proposition 9.8. Given an indexed closure operator ICO = (Ind, Syn, cl, ε, δ) we have foreach i ∈ |Ind|, a Galois correspondence (adjunction) between preorder categories

(Fcl(i), Ucl(i), ηcl(i), ε(i))

with functors Fcl(i)def= Fcl(i) : K(cl(i)) → Syn(i), Ucl(i)

def= Ucl(i) : Syn(i) → K(cl(i))

such that Fcl(i) a Ucl(i), and Ucl(i);Fcl(i) = cl(i) together with natural transformations

ε(i) : cl(i)⇒ idSyn(i) and ηcl(i)def= ηcl(i) : idK(cl(i)) ⇒ Fcl(i);Ucl(i).

31

Page 32: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

9 FROM INDEXED CLOSURE OPERATORS TO INDEXED FRAMES

Proof. It follows directly from definition 8.11, remark 9.2 and proposition 9.6.

In the next step we can show that the ”local” Galois correspondences give rise to a globalnatural transformation.

Proposition 9.9. Given an indexed closure operator ICO = (Ind, Syn, cl, ε, δ) the assign-ments i 7→ K(cl(i)) can be extended to a functor K(cl) : Ind → PRE such that the functorsUcl(i) : Syn(i)→ K(cl(i)) constitute a natural transformation Ucl : Syn⇒ K(cl).

Proof. First, we show that for each σ : i → j in Ind the functor Syn(σ) : Syn(i) → Syn(j)can be extended to a functor K(cl(σ)) : K(cl(i)) → K(cl(j)) such that Ucl(i);K(cl(σ)) =Syn(σ);Ucl(j):

Syn(i)Ucl(i) //

Syn(σ)��

K(cl(i))

K(cl(σ))��

Syn(i)cl(i) //

Syn(σ)��

Syn(i)

Syn(σ)��

Syn(j)Ucl(j)

// K(cl(j)) Syn(j)cl(j)

//cl(σ)

5=

Syn(j)

For each i ∈ Ind we have |Syn(i)| = |K(cl(i))| and Ucl(i) is the identity on objects thus we

can set K(cl(σ))(a)def= Syn(σ)(a) for all a ∈ |K(cl(i))| and obtain commutativity for all

objects a ∈ |Syn(i)|:

K(cl(σ))(Ucl(i)(a)) = K(cl(σ))(a) = Syn(σ)(a) = Ucl(j)(Syn(σ)(a))

Further the natural transformation cl(σ) allows us to assign to any Kleisli morphism fK :a→ b, i.e., any morphism f : cl(i)(a)→ b in Syn(i) the morphism

K(cl(σ))(fK)def= (cl(σ)(a);Syn(σ)(f))K in K(cl(j)).

cl(j)(K(cl(σ))(a))cl(σ)(a) // Syn(σ)(cl(i)(a))

Syn(σ)(f) // K(cl(σ))(b)

Since K(cl(j)) is a preorder category these assignments are trivially compatible with identitiesand composition thus we get a functor K(cl(σ)) : K(cl(i))→ K(cl(j)).

It remains to show commutativity for arbitrary morphisms g : a → b in Syn(i): Due tothe definition of Ucl(i) and K(cl(σ)) we have

K(cl(σ))(Ucl(i)(g)) = (cl(σ)(a);Syn(σ)(ε(i)(a));Syn(σ)(g))K

cl(j)(K(cl(σ))(a))cl(σ)(a) //

ε(j)(Syn(σ)(a)) **

Syn(σ)(cl(i)(a))

Syn(σ)(ε(i)(a))��

Syn(σ)(a)Syn(σ)(g)

// K(cl(σ))(b)

Since Syn(j) is a preorder category we can assume

cl(σ)(a);Syn(σ)(ε(i)(a)) = ε(j)(Syn(σ)(a))

thus we get finally the required equality due to the definition of Ucl(j):

K(cl(σ))(Ucl(j)(g)) = (ε(Syn(σ)(a));Syn(σ)(g))K = Ucl(j)(Syn(σ)(g)).

32

Page 33: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

10 SEMANTICAL ENTAILMENT FOR INDEXED PREORDER FRAMES

Syn : Ind → PRE is a functor and the functors K(cl(σ)) coincide with the functorsSyn(σ) on objects thus the assignments σ 7→ K(cl(σ)) are compatible w.r.t. identities andcomposition since all the categories K(cl(i)) are preorder categories.

Now we can formulate the main result of this section that can be seen as an inverse totheorem 8.12.

Theorem 9.10. Any Indexed Closure Operator ICO = (Ind, Syn, cl, ε, δ) defines an indexedpreorder frame (Ind, Syn,K(cl), Ucl, Fcl).

Proof. Follows immediately from proposition 9.8 and proposition 9.9.

In the discussion above, the Eilenberg-Moore construction associated to the presentationof the logic L in terms of its Indexed Closure Operator cl resembles the syntactical modelbuilt up from maximal consistent set of sentences, largely used in proof of completeness, whilethe Kleisli construction resembles the algebraically defined Lindenbaum models for a logic Lbased on equivalence classes of equiprovable sentences. This connection between proofs ofcompleteness and solutions to factoring of co-monads is, apart from worth of mentioning, outof scope of the present article.

10 Semantical Entailment for Indexed Preorder Frames

The concept of General Logic [36] is based on semantical entailment in institutions (seedefinition 5.1). In the last section we have seen, in the examples 9.3 and 9.7, that thecorresponding semantical entailment in institutional frames can be described, on an abstractcategorical level, by the Kleisli construction.

Following this observation, we want to generalize in this section semantical entailmentto arbitrary indexed preorder frames. The key for this generalization is the well-known factthat the Kleisli adjunction is initial in the category of all adjoint factorizations of a givenco-monad. By lifting up this result to indexed preorder categories we can define semanticalentailment for arbitrary indexed preorder frames and we can show, finally, that semanticalentailment provides for any indexed preorder frame a complete Indexed Logic in the sense ofdefinition 5.2.

Due to fact 8.5 any adjunction (F,U, η, ε) between categories B and C gives rise to a co-monad (G, ε, δ) = (U ;F, ε, U � η �F ) on B and, due to proposition 9.6, the Kleisli constructionprovides for this co-monad another adjunction (FG, UG, ηG, ε) with UG;FG = G(U ;F ).

BU

⊥ // CFoo

BUG

⊥ // K(G)FGoo

A complete proof of the initiality of the Kleisli category can be found in [24]. Here we needonly the initiality w.r.t. the original adjunction.

Fact 10.1. For any adjunction (F,U, η, ε) between categories B and C there exists a uniquefunctor EG : K(G)→ C such that UG;EG = U , EG;F = FG and η � EG = EG � η.

BUG

//

U

66K(G)

FGoo EG // C

F

vv

33

Page 34: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

10 SEMANTICAL ENTAILMENT FOR INDEXED PREORDER FRAMES

EG is given by EG(a) = U(a) for all objects a in K(G) and EG(fK) = η(U(a));U(f) for allmorphisms fK : a→ b in K(G).

Since any adjunction (F,U, η, ε) between categories B and C provides a bijection betweenthe hom-sets K(G)(a, b) = B(FUa, b) and C(Ua,Ub) for any objects a and b in B we haveimmediately:

Corollary 10.2. For any adjunction (F,U, η, ε) between categories B and C the functorEG : K(G)→ C is full.

Now, we lift up the initiality of Kleisli categories to indexed preorder frames.

Proposition 10.3. Given an indexed preorder frame IF = (Ind, Syn,Den, sem, fml) weconsider the corresponding indexed closure operator (Ind, Syn, cl, ε, δ), due to theorem 8.12.Then the functors

Ecl(i)def= Ecl(i) : K(cl(i))→ Den(i),

which can be construct due to fact 10.1, constitute a natural transformation Ecl : K(cl) ⇒Den such that Ucl;Ecl = sem.

Proof. For any σ : i→ j in Ind we have to show that Ecl(i);Den(σ)) = K(cl(σ));Ecl(j):

Syn(i)Ucl(i) //

sem(i)

**

Syn(σ)

��

K(cl(i))Ecl(i) //

K(cl(σ))

��

Den(i)

Den(σ)

��Syn(j)

Ucl(j)//

sem(j)

44K(cl(j))Ecl(j)

// Den(j)

For any a ∈ |K(cl(i))| we have, due to the definition of Ecl(i) and K(cl(σ)):

Den(σ))(Ecl(i)(a)) = Den(σ)(sem(i)(a))

Ecl(j)(K(cl(σ))(a)) = sem(j)(Syn(σ)(a))

thus commutativity for objects is ensured by the indexed frame condition

sem(i);Den(σ) = Syn(σ); sem(j).

The commutativity for morphisms follows trivially since Den(j) is a preorder category. Fi-nally, Ucl;Ecl = sem follows immediately from fact 10.1.

Finally, we can formulate our last theorem summarizing the properties of semanticalentailment.

Theorem 10.4. Any indexed preorder frame IF = (Ind, Syn,Den, sem, fml) defines a com-plete indexed logic

(Ind, Syn,Den,K(cl), sem, fml, Ucl, Fcl)

with the indexed functor Ecl : K(cl)⇒ Den such that sem = Ucl;Ecl.

Proof. Follows immediately from definition 5.2, theorem 8.12, theorem 9.10, and proposition10.3 where completeness is ensured by corollary 10.2.

34

Page 35: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

REFERENCES

11 Concluding Remarks

Logical Systems are paramount to almost every subject in computer science. This vast numberof application areas have had a deep influence on us and thus on how we perceive what a formalspecification of a logical system should be. Instititution-like presentation of logics have shownto be of great use for computer scientists interested in the development of meta-theories forspecification, programming, and also in the reuse and borrowing of logical tools. The latter isespecially based on appropriate notions of maps between logical systems [7, 20, 34], which wehave not considered in this paper. On the other hand, axiomatizations of logics using simpleconcepts like satisfaction relations, entailment relations and closure operators are universaltools which are familiar to anyone with the slightest interest in logic itself.

Using Lawvere´s essential idea that the fundamental relationship between syntax andsemantics can be precisely formulated by galois connections or adjoint functors, we haveshown that even complex formalizations of logics like Institutions of Goguen and Burstalland Entailment Systems of Meseguer are in their essence, a family of local adjoint situationsbetween the syntactical and semantical aspects (of each index) satisfying some kind of naturalcoherence condition with respect to change of syntax. Indexed categories here are usedessentially to fix changes of languages, which is essential for computer science applications.But it is by using adjoint functors that we establish a uniform language to describe theessential ideas behind satisfaction relations, entailment relations, and closure operators aswell.

One should not perceive the tools introduced here as yet another formal notion of logic.They should not be understood in any way as substitutes for any candidate of what a logicalsystem really is. In fact, these notions were brought to the surface by a careful examinationof the concepts exemplified in this paper. They serve here primarily as a tool to present thesecomplex systems in a simple, elegant and uniform way. Yet, they become also witness to thefact that adjoint situations arise everywhere, especially when one is looking for the essentialrelationship between syntax and semantics in any given logical system.

References

[1] K. J. Bairwise. Axioms for Abstract Model Theory. Annals of Mathematical Logic,7:221–265, 1974.

[2] M. Barr and C. Wells. Toposes, Triples and Theories. Springer-Verlag, 1984.

[3] M. Barr and C. Wells. Category Theory for Computing Science. Series in ComputerScience. Prentice Hall International, London, 1990.

[4] R. M. Burstall and J. A. Goguen. Putting Theories together to make Specifications. InProc. Int. Conf. Artificial Intelligence, 1977.

[5] R. M. Burstall and J. A. Goguen. The Semantics of Clear, a Specification Language.In D. Bjøner, editor, Abstract Software Specification, Proc. 1979 Copenhagen WinterSchool, LNCS 86, pages 292–332. Springer, 1980.

[6] B. Cadish and Z. Diskin. Algebraic graph-oriented approach to view integration. PartI: Specification framework and general strategy. Technical Report 9301, Frame InformSystems/LDBD, Riga, Latvia, 1993. http://citeseer.ist.psu.edu/340019.html.

35

Page 36: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

REFERENCES REFERENCES

[7] M. Cerioli and J. Meseguer. May I Borrow Your Logic? Transporting Logical Structuresalong Maps. Theoretical Computer Science, 173(2):311–347, 1997.

[8] R. J. Crole. Categories for Types. Cambridge University Press, 1993.

[9] R. Diaconescu. Grothendieck Institutions. Applied Categorical Structures, 10(4):383–402,2002.

[10] Z. Diskin. Towards algebraic graph-based model theory for computer science. Bulletinof Symbolic Logic, 3:144–145, 1997. Presented (by title) at Logic Colloquium’95.

[11] Z. Diskin. Mathematics of UML: Making the Odysseys of UML less dramatic. In H. Kilovand K. Baclawski, editors, Practical Foundations of Business System Specifications, pages348–381. Kluwer Academic Publishers, 2003.

[12] Z. Diskin and B. Kadish. A graphical yet formalized framework for specifying viewsystems. In R. Manthey and V. Wolfengagen, editors, Advances in Databases and In-formation Systems, pages 123–132, 1997. ACM SIGMOD Digital Anthology: vol.2(5),ADBIS’97.

[13] Zinovy Diskin and Uwe Wolter. A Diagrammatic Logic for Object-Oriented Visual Mod-eling. ENTCS, 203/6:19–41, 2008.

[14] Kosta Dosen. Cut Elimination in Categories. Trends in Logic, Studia Logica Library.Kluwer Academic Publishers, 1999.

[15] J. Fiadeiro. Categories for Software Engineering. Springer, Berlin, 2005.

[16] Jose Luiz Fiadeiro and Amılcar Sernadas. Structuring theories on consequence. In Proc.5th Workshop on Specification of Abstract Data Types, LNCS 332, pages 44–72, 1987.

[17] D. M. Gabbay. What is a logical system. In D. M. Gabbay, editor, What is a LogicalSystem, pages 179–216. Clarendon Press, Oxford, 1994.

[18] Jean-Yves Girard, Y. Lafont, and P. Taylor. Proofs and Types. Cambridge UniversityPress, 1989.

[19] J. A. Goguen and R. M. Burstall. Institutions: Abstract Model Theory for Specificationand Programming. Journal of the ACM, 39(1):95–146, January 1992.

[20] J. A. Goguen and G. Rosu. Institutions Morphisms. Formal Aspects of Computing,12(3-5):274–307, July 2002.

[21] P. Huber. Homotopy Theory in General Categories. Matematische Annalen, (144):361–385, 1961.

[22] B. Jacobs. Categorical Logic and Type Theory, volume 141 of Studies in Logic and theFoundations of Mathematics. Elsevier, Amsterdam, 2001.

[23] J. Lambek and P. J. Scott. Introduction to Higher Order Categorical Logic. Cambridgestudies in advanced mathematics. Cambridge University Press, 1986.

36

Page 37: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

REFERENCES REFERENCES

[24] J. Lambek and P.J. Scott. Introduction to Higher Order Categorical Logic. CambridgeUniversity Press, 1986.

[25] Joachim Lambek. Deductive systems and categories i. syntactic calculus and residuatedcategories. Mathematical Systems Theory, 2(4):287–318, 1968.

[26] Joachim Lambek. Deductive systems and categories ii. standard constructions and closedcategories. In Category Theory, Homology Theory and their Applications I, number 86in Lecture Notes in Mathematics, pages 76–126. Springer-Verlag, 1969.

[27] Joachim Lambek. Deductive systems and categories iii. cartesian closed categories, intu-itionistic propositional calculus and combinatory logic. In Toposes, Algebraic Geometryand Logic, number 274 in Lecture Notes in Mathematics, pages 57–82. Springer-Verlag,1971.

[28] Saunders Mac Lane. Natural associativity and commutativity. Technical report, RiceUniversity Studies, Papers in Mathematics, 1963.

[29] F. W. Lawvere. Functorial semantics of algebraic theories. Proceedings of the NationalAcademy of Science, 50(5):869–872, November 1963.

[30] F.W. Lawvere. Adjointness in Foundations. Theory and Application of Categories,(16):1–16, 2006.

[31] S. Mac Lane. Categories for the Working Mathematician. Springer Verlag, Berlin Hei-delberg New York, 1970.

[32] M.E. Maietti, P. Maneggia, V. de Paiva, and E. Ritter. Relating categorical semanticsfor intuitionistic linear logic. Journal of Categorical Structures, 12(1), 2005.

[33] M. Makkai. Generalized sketches as a framework for completeness theorems. Journal ofPure and Applied Algebra, 115:49–79, 179–212, 214–274, 1997.

[34] A. Martini. Relating Arrows between Institutions in a Categorical Framework. PhDthesis, Technical University of Berlin, 1999.

[35] A. Martini, U. Wolter, and E. H. Haeusler. Fibred and Indexed Categories for AbstractModel Theory. Journal of the IGPL, 15(5-6):707–739, October/December 2007.

[36] J. Meseguer. General Logics. In H.-D. Ebbinghaus et. al., editor, Logic colloquium ’87,pages 275–329. Elsevier Science Publishers B. V.,North Holland, 1989.

[37] T. Mossakowski, J. Goguen, R. Diaconescu, and A. Tarlecki. What is a Logic? In J.-YBeziau, editor, Logica Universalis, pages 113–133. Birkhauser, 2005.

[38] Adrian Rutle, Alessandro Rossini, Yngve Lamo, and Uwe Wolter. A formal approachto the specification and transformation of constraints in MDE. Journal of Logic andAlgebraic Programming, 81/4:422–457, 2012.

[39] A. Tarlecki, R.M. Burstall, and J.A. Goguen. Some Fundamental Algebraic Tools forthe Semantics of Computation. Part iii: Indexed Categories. TCS, 91:239–264, 1991.

37

Page 38: Towards a Uniform Presentation of Logical Systems by ...€¦ · Also, from a categorical perspec-tive, Tarski s consequence operator [40] can be formalized as Indexed Closure Operators,

REFERENCES REFERENCES

[40] A. Tarski. Fundamentale Begriffe der Methodologie der Deduktiven Wissenschaften I.Monatshefte fur Mathematik und Physik, 37:361–404, 1930.

[41] U. Wolter and A. Martini. Shedding New Light in the World of Logical Systems. InE. Moggi and G. Rosolini, editors, Category Theory and Computer Science, 7th Interna-tional Conference, CTCS’97, pages 159–176. Springer, LNCS 1290, 1997.

38