• No results found

Nominal linear relations

In document Nominal Models of Linear Logic (Page 91-94)

3.4 Nominal relations

3.4.1 Nominal linear relations

One major drawback of the previous construction is that it does not have products and co- products. We can tackle this problem by moving from functions to relations. The category of relations is one of the simplest known models of linear logic. We carefully adapt it to take care of polarities and names.

Definition 3.16. A nominal linear relation R : A → B is a nominal subset of A × B such that if(a, b) ∈ R then ν(a)= ν(b).

In the future, we will write a R b for (a, b) ∈ R . Linear nominal relations compose as relations and the identity relation is linear nominal. Consequently, they organise themselves as a category. We shall specify a full subcategory of it, whose objects correspond to denotations of formulas ofMALL. We denote this sub-categoryNomLinRel. Its objects are nominal sets of non-empty separated, annotated lists of atomes, where the adjective annotated highlights the fact that lists will be built using patterns. More precisely, the elements L of the sets are built from the following grammar :

L := a | • | inl(L) | inr(L) | L1.L2

where a ∈ A, and L1#L2.

Note that the previously enforced condition that the sets are 1-orbit, or non-empty is dropped. The categoryNomLinRelcan be equipped with a monoidal product, written ?. The monoidal product of relations is usually defined via the cartesian product of sets, but to accom- modate names and lists we rather use the separated concatenation ?, just as inNomLinList.

• A ⊗ B = A ? B = {L1.L2| L1 ∈ A, L2∈ B, L1#L2}

• R1⊗ R2= R1? R2 = {(a.b, c.d) | (a, c) ∈ R1, (b, d) ∈ R2, a#b ∧ c#d}

The unit of the monoidal product is the set I = {•}. Once again, the use of the separated product as a monoidal product prevents the category from having non-linear morphisms, simi- larly asNomLinList. In the sequel, given L= L1.L2in A ⊗ B, we will write A for the projection

Theinl,inrconstructors are called patterns, and will allow us to form coproducts, denoted by ⊕.

• A ⊕ B =inl(A) ]inr(B)= {inl(L) | L ∈ A} ] {inr(L) | L ∈ B}. • R1⊕ R2=inl( R1) ]inr( R2)

where, given R : A → B, we defineinl( R ) = {inl(L1).L2 | L1.L2 ∈ R, L1 ∈ A, L2 ∈ B}, and

respectively forinr. Furthermore, we write ] to express the union of disjoint sets.

The unit of the coproduct 0 is the empty set ∅. ⊕ is not a simple tensor product, it actually defines a biproduct: A ⊕ B is the biproduct of A and B. We remind here that a biproduct is an object that can act both as a coproduct of A,B, as a product of A, B, and does both in a compatible way that we will not describe here.

The category (NomLinRel, ⊗, ⊕) is a monoidal category with coproduct. Furthermore, the

tensor product distributes over the coproduct: A ⊗ (B ⊕ C) ' (A ⊗ B) ⊕ (A ⊗ C), in the sense that there is an isomorphism between them. As a result, (NomLinRel, ⊗, ⊕) defines a model of

the (⊗, ⊕) fragment of MALL, where ~1 = I, ~X = AX, ~0 = 0NomLinRel. One can easily

see thatNomLinListis a subcategory ofNomLinRel, and we write I for the inclusion functor

NomLinList−→I NomLinRel. We say that an object of the category is well-typed if it can be built out of the ~X, I, 0 using the two previously described operations. This time, as we dropped the restriction that the objects are 1-orbit, some objects might not be well-typed. A typical example of such an object is A. The subcategory of well-typed objects ofNomLinRel corresponds to the biproduct completion ofNomLinList. In the sequel, we will restrictNomLinRelto its full subcategory of well-typed objects.

Each element of a morphism of NomLinRel defines a set of axiom links, that is, a set- function from the atomic literals on the domain to the codomain. For instance, an element (a1.a2, a2.a1) of X ⊗ X → X ⊗ X defines the following set of axiom-links.

σ : A ⊗ A → A ⊗ A

In contrast to Rel, the category of sets and relations, NomLinRelis not monoidal closed, notably due to the linear condition on the relations. Indeed, given a relation A → B, if the category was closed there would be a corresponding “name” R0: I → A( B, and, as a result, for all x in A ( B, if • R x then ν(x) = ν(•) = ∅. Hence the only elements of A ( B would be lists of atomes of empty support. To solve this, we want to apply, as we did in the previous section, theIntconstruction. Therefore, we first have to address its traced structure.

Just as its sibling NomLinList, tracing NomLinRel is not straightforward. For instance, taking R as above, defined by (a1.a2) R (a2.a1). Then tracingtrAA21,A1( R ) (where A2are the right

hand side A’s), requires us to equate a2and a1, but the element (a1.a1, a1.a1) is not part of the

3.4.1.1 Category of lax nominal relations

In order to bypass the above restriction, we close linear relations under strict substitutions be- fore composing them. We define strict substitutions to be name substitutions of the form [an/bn]...[a1/b1] where for each i, there is a type variable Xisuch that ai, bi ∈ AXi. Similarly as

for nominal permutations, we write “·” for the action of strict substitutions on elements. We call Ξ the set of strict substitutions, and often use the lowercase e to refer to one of its elements. The composition of strict substitutions e1, e2consists in concatenating their sequences, and is there-

fore written e1.e2. We devise several properties of strict substitutions and define them formally

in the appendix 9.4. We then have e1.e2· x= e1· (e2· x). We also introduce the following nota-

tion. Given a well-typed set A of annotated name-distinct lists, we write ˆAfor the corresponding set of annotated lists, such that the name-distinct property is dropped. Formally, ˆAis defined as follows by induction on the structure of A.

ˆ

AX = AX {•}c= {•} [

A1? A2= ˆA1× ˆA2 A ] B[ = ˆA ] ˆB

That way, if an element x ∈ A, then the set ˆx= {e · x | e ∈ Ξ} ⊆ ˆA. For R : A a linear relation, we write ˆR : ˆAfor the closure under strict substitutions of R , that is:

b

R = {e · r | r ∈ R , e ∈ Ξ}.

Proposition 3.17. ˆ(.) defines a symmetric monoidal functor from the category NomLinRelto the category of nominal linear, non-separated, relations. We call this categoryLaxNomLinRel. It has nominal sets of annotated lists as objects, and linear relations as morphisms.

To prove the property, we will use this following lemma of strict substitutions, that is proven appendix 9.4.

Lemma 3.18. Let x an element of nominal set, and e ∈ Ξ. Then e · x = e0· (π · x), where if e0 = [an/bn]...[a1/b1], and, writing e0i for[ai/bi]...[a1/b1], then ai+1, bi+1 ∈ ν(e0i · (π · x)) and

whereπ is a nominal permutation.

Given an element x and e ∈ Ξ, we refer to the (e0, π) in the above lemma as a canonical form of e given x. Equivalently, we say that e is in canonical form for x, if (e,id) is a canonical form of e given x. The lemma basically says that the action of a strict substitution on an element consists of two distinct actions: a name-permutation followed by a name-merging.

Proof of Proposition 3.17. Given R : A → B and Q : B → C, we need to prove that:

[

First, we consider the left to right inclusion. Let u ∈ [R ; Q . Then ∃e ∈Ξ, ∃u0∈ R ; Q .u= e·u0. Furthermore ∃u00 ∈ A × B × C such that u00 A × B ∈ R , u00 B × C ∈ Q , and u00 ˆA × ˆC= u0. Hence e · u00  ˆA × ˆC = u and e · u00  ˆA × ˆB ∈ bR , e · u00  ˆB × ˆC ∈ bQ , hence u ∈ ˆR ; ˆQ , that is, it belongs in the second set. Now let us prove the right to left inclusion. Formally, let u0 ∈ bR ; bQ . It entails that there exist u ∈ ˆA × ˆB × ˆCsuch that u ˆA × ˆB ∈ bR , u  ˆB × ˆC ∈ bQ , and u  A × C = u0. Then let us, as above, use canonical forms for the strict substitutions and use

the fact that both R and Q are closed under nominal permutations. Hence u ˆA × ˆB= e1· u1,

u1 ∈ R and e1 is in canonical form for u1. Furthermore u  ˆB × ˆC = e2· u2, u2 ∈ Q and

e2 is in canonical form for u2. Let us call x = u1  B and y = u2  B. As there exists

strict substitutions that equate them, it entails that the lists have same length and same type. Hence, thanks to the fact that the lists are separated, they are nominally equivalent, that is, there exists a permutation π such that π · u1  B = u2  B. Now, by using the fact that

every permutation can be encoded as a strict substitution for a given specific element (property refprop:permsubstitution), we write π−1 for the strict substitution that encodes π−1 for π · u

1.

Hence e2·u2  B = e1·(u1 B) = e1.π−1·π·(u1 B) = e1.π−1·(u2  B). As ν(u2 B) = ν(u2 C),

e2· u2 C = e1.π−1u2 C. Let u00 = e1.π−1· (π · u1|Bu2), where |Bindicates that we merge the

two B parts of the lists, that are equal. Therefore, as π · u1 ∈ R , we can conclude that u00 A ×C

belongs in [R ; Q , and moreover u00 = u.

Also, one can prove that idA,LaxNomLinRelˆ = idA,NomLinRel

V

. The inclusion idA,NomLinRel

V

idA,LaxNomLinRelˆ is automatic, whereas the other consists in proving that any element of

idA,LaxNomLinRelˆ can be obtained from an element ofidA,NomLinRelby means of substitutions.

The monoidality comes from [A? B = A × B by definition, and similarly on morphisms: [

R ? Q = R × Q . 

LaxNomLinRelis not an appropriate category to model morphisms of linear logic, as there might be morphisms A ⊗ A → A or A → A ⊗ A. On the other hand, to relax the separated condition will prove useful in the future to deal with tracing, and therefore, with composition when dealing with the compactification of this category through theInt-construction.

In document Nominal Models of Linear Logic (Page 91-94)