• Aucun résultat trouvé

Counting and Computing Join-Endomorphisms in Lattices

N/A
N/A
Protected

Academic year: 2021

Partager "Counting and Computing Join-Endomorphisms in Lattices"

Copied!
24
0
0

Texte intégral

(1)

HAL Id: hal-02422624

https://hal.archives-ouvertes.fr/hal-02422624v2

Submitted on 21 Jan 2020

HAL is a multi-disciplinary open access archive for the deposit and dissemination of sci- entific research documents, whether they are pub- lished or not. The documents may come from teaching and research institutions in France or abroad, or from public or private research centers.

L’archive ouverte pluridisciplinaire HAL, est destinée au dépôt et à la diffusion de documents scientifiques de niveau recherche, publiés ou non, émanant des établissements d’enseignement et de recherche français ou étrangers, des laboratoires publics ou privés.

Computing Distributed Knowledge as the Greatest Lower Bound of Knowledge

Santiago Quintero, Sergio Ramírez, Camilo Rueda, Frank Valencia

To cite this version:

Santiago Quintero, Sergio Ramírez, Camilo Rueda, Frank Valencia. Computing Distributed Knowl-

edge as the Greatest Lower Bound of Knowledge. RAMICS 2021 - Relational and Algebraic Methods

in Computer Science, Nov 2021, Marseille, France. pp.413-432. �hal-02422624v2�

(2)

Lattices

?

Santiago Quintero2, Sergio Ramirez1, Camilo Rueda1, Frank Valencia1,3

1 Pontificia Universidad Javeriana Cali

2 LIX, ´Ecole Polytechnique de Paris

3 CNRS-LIX, ´Ecole Polytechnique de Paris

Abstract. Structures involving a lattice and join-endomorphisms on it are ubiq- uitous in computer science. We study the cardinality of the setE(L)of all join- endomorphisms of a given finite latticeL. In particular, we show that whenLis Mn, the discrete order ofnelements extended with top and bottom,|E(L)| = n!Ln(−1) + (n+ 1)2 whereLn(x)is the Laguerre polynomial of degreen.

We also study the following problem: Given a latticeLof sizenand a setS ⊆ E(L)of sizem, find the greatest lower boundd

E(L)S. The join-endomorphism d

E(L)Shas meaningful interpretations in epistemic logic, distributed systems, and Aumann structures. We show that this problem can be solved with worst-case time complexity inO(n+mlogn)for powerset lattices,O(mn2)for lattices of sets, andO(mn+n3)for arbitrary lattices. The complexity is expressed in terms of the basic binary lattice operations performed by the algorithm.

1 Introduction

There is a long established tradition of using lattices to model structural entities in many fields of mathematics and computer science. For example, lattices are used in concur- rency theory to represent the hierarchical organization of the information resulting from agent’s interactions [13].Mathematical morphology(MM), a well-established theory for the analysis and processing of geometrical structures, is founded upon lattice theory [2,14]. Lattices are also used as algebraic structures for modal and epistemic logics as well as Aumann structures (e.g., modal algebras and constraint systems [8]).

In all these and many other applications, latticejoin-endomorphismsappear as fun- damental. In MM, join-endomorphisms correspond to one of its fundamental opera- tions;dilations.In modal algebra, they correspond via duality to the box modal operator.

In epistemic settings, they represent belief or knowledge of agents. In fact, our own in- terest in lattice theory derives from using join-endomorphisms to model the perception that agents may have of a statement in a lattice of partial information [8].

For finite lattices, devising suitable algorithms to compute lattice maps with some given properties would thus be of great utility. We are interested in constructing al- gorithms for computing lattice morphisms. This requires, first, a careful study of the space of such maps to have a clear idea of how particular lattice structures impact on

?This work has been partially supported by the ECOS-NORD project FACTS (C19M03)

(3)

the size of the space. We are, moreover, particularly interested in computing themaxi- mumjoin-endomorphism below a given collection of join-morphisms. This turns out to be important, among others, in spatial computation (and in epistemic logic) to model the distributed information (resp. distributed knowledge) available to a set of agents as conforming a group [9]. It could also be regarded as the maximum perception consistent with (or derivable from) a collection of perceptions of a group of agents.

Problem.Consider the setE(L)of all join-endomorphisms of a finite latticeL. The setE(L)can be made into a lattice by ordering join-endomorphisms point-wise wrt the order ofL.We investigate the following maximization problem:Given a latticeLof sizenand a setS ⊆ E(L)of sizem, find inE(L)the greatest lower bound ofS, i.e., d

E(L)S.Simply takingσ:L→Lwithσ(e)def=d

L{f(e)|f ∈S}does not solve the problem asσmay not be a join-endomorphism. Furthermore, sinceE(L)can be seen as the search space, we also consider the problem of determining its cardinality. Our main results are the following.

This paper.We present characterizations of the exact cardinality ofE(L)for some fundamental lattices. Our contribution is to establish the cardinality of E(L) for the stereotypical non-distributive latticeL=Mn.We show that|E(Mn)|equalsrn0+. . .+ rnn+r1n+1 =n!Ln(−1) + (n+ 1)2whererkmis the number of ways to placeknon- attacking rooks on anm×mboard andLn(x)is the Laguerre polynomial of degree n. We also present cardinality results for powerset and linear lattices that are part of the lattice theory folklore: The number of join-endomorphisms isnlog2n for powerset lattices of size nand 2nn

for linear lattices of sizen+ 1. Furthermore, we provide algorithms that, given a latticeLof sizenand a set S ⊆ E(L)of sizem, compute d

E(L)S.Our contribution is to show thatd

E(L)Scan be computed with worst-case time complexity inO(n+mlogn)for powerset lattices,O(mn2)for lattices of sets, and O(nm+n3)for arbitrary lattices.

2 Background: Join-Endomorphisms and Their Space

We presuppose basic knowledge of order theory [3] and use the following notions. Let (L,v)be a partially ordered set (poset), and letS ⊆L. We useF

LSto denote the least upper bound (orsupremumorjoin) ofSinL, if it exists. Dually,d

LS is the greatest lower bound (glb) (infimumormeet) ofSinL, if it exists. We shall often omit the index LfromF

Landd

Lwhen no confusion arises. As usual, ifS ={c, d},ctdandcud representF

S andd

S, respectively. IfLhas a greatest element (top)>, and a least element (bottom)⊥, we haveF

∅=⊥andd

∅=>. The posetLisdistributiveiff for everya, b, c∈L,at(buc) = (atb)u(atc).

The posetLis alatticeiff each finite nonempty subset ofLhas a supremum and infimum inL, and it is a complete latticeiff each subset of Lhas a supremum and infimum inL. Aself-maponLis a functionf :L→L. A self-mapf ismonotonicif avbimpliesf(a)vf(b). We say thatf preservesthe join ofS ⊆Lifff(FS) = F{f(c)|c∈S}.

We shall use the following posets and notation. Givenn, we usento denote the poset{1, . . . , n}with the linear orderxvyiffx≤y.The posetn¯is the set{1, . . . , n}

with the discrete orderxvyiffx=y. Given a posetL, we useLfor the poset that

(4)

results from adding a bottom element to L. The poset L> is similarly defined. The lattice2n is then-fold Cartesian product of2ordered coordinate-wise. We defineMn as the lattice(¯n)>.Alattice of setsis a set of sets ordered by inclusion and closed under finite unions and intersections. Apowerset latticeis a lattice of sets that includes all the subsets of its top element.

We shall investigate the set of all join-endomorphisms of a given lattice ordered point-wise. Notice that every finite lattice is a complete lattice.

Definition 1 (Join-endomorphisms and their space).LetLbe a complete lattice. We say that a self-map is a (lattice) join-endomorphismiff it preserves the join of every finite subset ofL. DefineE(L)as the set of all join-endomorphisms ofL. Furthermore, givenf, g∈ E(L), definef vE gifff(a)vg(a)for everya∈L.

The following are immediate consequences of the above definition.

Proposition 1. LetLbe a complete lattice.f ∈ E(L)ifff(⊥) = ⊥andf(atb) = f(a)tf(b)for alla, b∈L. Iff is a join-endomorphism ofLthenf is monotonic.

Given a setS ⊆ E(L), whereLis a finite lattice, we are interested in finding the greatest join-endomorphism inE(L)below the elements ofS, i.e.,d

E(L)S. Since every finite lattice is also a complete lattice, the existence of d

E(L)S is guaranteed by the following proposition.

Proposition 2 ([7]).If(L,v)is a complete lattice,(E(L),vE)is a complete lattice.

In the following sections we study the cardinality ofE(L)for some fundamental lattices and provide efficient algorithms to computed

E(L)S.

3 The Size of the Function Space

The main result of this section is Theorem 1. It states the size of E(L)when Lis a discrete order extended with a top and bottom. Propositions 3 and 4 state, respectively, the size ofE(L)for the cases whenLis a powerset lattice and whenLis a total order.

3.1 Distributive Lattices

We begin with lattices isomorphic to2n. They includefinite boolean algebrasandpow- ersetlattices [3]. The size of these lattices are easy to determine from the observation that their join-preserving are determined by their action on their atoms.

Proposition 3. Suppose thatm ≥ 0. LetLbe any lattice isomorphic to the product lattice2m. Then|E(L)|=nlog2nwheren= 2mis the size ofL.

Thus powerset lattices and boolean algebras have a super-polynomial, sub-exponen- tial number of join-endomorphisms. Nevertheless, linear order lattices allow for an ex- ponential number of join-endomorphisms given by the central binomial coefficient.

The following proposition is also easy to prove from the observation that the join- homorphisms over a linear order are also monotonic functions. In fact, this result ap- pears in [1] and it is well-known among RAMICS community [11,16].

(5)

Proposition 4. Suppose thatn≥0.LetLbe any lattice isomorphic to the linear order latticen. Then|E(L)|= 2nn

. It is easy to prove that24nn2nn

≤4nforn≥1.Together with Prop.4, this gives us explicit exponential lower and upper bounds for|E(L)|whenLis a linear lattice.

3.2 Non-distributive Case

The number of join-endomorphisms for some non-distributive lattices of a given size can be much bigger than that for those distributive lattice of the same size in the previous section. We will characterize this number for an archetypal non-distributive lattice in terms of Laguerre (and rook) polynomials.

Laguerre polynomialsare solutions to Laguerre’s second-order linear differential equationxy00+ (1−x)y0+ny= 0wherey0andy00are the first and second derivatives of an unknown functionyof the variablexandnis a non-negative integer. The Laguerre polynomial of degreeninx,Ln(x)is given by the summationPn

k=0 n k

(−1)k k! xk. The latticeMn is non-distributive for anyn ≥3. The size ofE(Mn)can be suc- cinctly expressed as follows.

Theorem 1. |E(Mn)|= (n+ 1)2+n!Ln(−1).

In combinatorics rook polynomials are generating functions of the number of ways to place non-attacking rooks on a board. Arook polynomial(for square boards)Rn(x) has the formPn

k=0xkr(k, n)where the (rook) coefficientr(k, n)represents the num- ber of ways to place k non-attacking rooks on an n×n chessboard. For instance, r(0, n) = 1,r(1, n) =n2andr(n, n) =n!. In generalr(k, n) = nk2

k!.

Rook polynomials are related to Laguerre polynomials byRn(x) =n!xnLn(−x−1).

Therefore, as a direct consequence of the above theorem, we can also characterize

|E(Mn)|in combinatorial terms as the following sum of rook coefficients.

Corollary 1. Letr0(n+ 1, n) = r(1, n+ 1)andr0(k, n) = r(k, n)if k ≤ n. Then

|E(Mn)|=Pn+1

k=0r0(k, n).

We conclude this section with another pleasant correspondence between the endo- morphisms inE(Mn)andRn(x). Letf : L →Lbe a function over a lattice(L,v).

We say thatf isnon-reducinginLiff it does not map any value to a smaller one; i.e., there is no e ∈ Lsuch thatf(e) @ e. The number of join-endomorphisms that are non-reducing inMnis exactly the value of the rook polynomialRn(x)forx= 1.

Corollary 2. Rn(1) =|{f ∈ E(Mn)|f is non-reducing inMn}|.

Table 1 illustrates the join-endomorphisms over the lattice Mn as the union of four familiesF1, . . . ,F4. Corollary 2 follows from the observation that the set of non- reducing functions inMnis equal toF4whose size isRn(1)as shown in the following proof of Th. 1.

(6)

3.3 Proofs

We present proofs for the statements of this section. Propositions 3 and 4 follow from simple observations and they are part of the lattice theory folklore [1,11,16]. We present original proofs of these proposition in the Appendix.

Proof of Proposition 3. We wish to prove the following:LetLbe any lattice isomor- phic to the product lattice 2m. Then |E(L)| = nlog2n wheren = 2m is the size of L.

Take any setS of size m. Consider the powerset latticeL = P(S) ordered by inclusion. We haven = |P(S)| = 2m. We shall show that|E(L)| = nlog2n. Since P(S)is isomorphic to2m, Proposition 3 follows from the fact that isomorphic lattices have the same number of join-endomorphisms.

Let F be the family of functions f : P(S) → P(S) that satisfy (a) f(T) = S

t∈Tf({t}) if|T| > 1 and (b) f(∅) = ∅. The equality |E(L)| = nlog2n follows from the following claim: (1)F=E(L)and (2)|F |=nlog2n.

To prove (1) one can verify that iff ∈ F thenf is a join-endomorphism where t is∪ and⊥is the∅. Hence f ∈ E(L). On the other hand, iff 6∈ F then either f(T)6=S

t∈Tf({t})for someT ⊆Sorf(∅)6=∅. But sincet=∪and⊥=∅, we haveT =F

t∈T{t}butf(T)6=F

t∈Tf({t})orf(⊥)6=⊥.Hencef 6∈ E(L).

To prove (2) notice that givenf ∈ F, for eachT ⊆ Sif|T| > 1then the value f(T)is determined by the values offapplied to each singleton{t} ⊆S, and if|T|= 0 the valuef(T)is fixed to∅. The setP(S)haslog2n=msingletons. Since there is no restriction on how eachf ∈ F should map singletons,|F |=nlog2nas wanted. ut Proof of Proposition 4. We now show that the size ofE(L)for linear orders is deter- mined by the central binomial coefficient.LetLbe any lattice isomorphic to the linear order latticen. We want to show that|E(L)|= 2nn

.

LetM(L)be the set of monotonic functions fromL toLthat preserve⊥. We claim thatM(L) =E(L).The inclusionE(L)⊆ M(L)follows from Proposition 1 and the fact that join-endomorphisms preserve bottoms. For M(L) ⊆ E(L), take f ∈ M(L).By definitionf(⊥) =⊥. Take anya, b∈L. So eitheravborbva. If avbthenf(atb) =f(b)and by monotonicity off,f(b) =f(a)tf(b). Similarly ifbvathenf(atb) =f(a) =f(a)tf(b).We conclude thatf ∈ E(L).

Now, for everyf ∈ M(L)we havef(⊥) = ⊥, then|E(L)| = |M(L)| =

|M(L\ {⊥} →L)|whereM(L\ {⊥} →L)is the set of monotonic functions from L\{⊥}toL.Thus to prove Proposition 4 it suffices to show|M(L\{⊥} →L)|= 2nn

. Notice that|L|=n+ 1. Consider the equationPn+1

i=1 Xi =nwhere the variable Xitakes a value between0andn. LetSol(n)be the set of all solutions to this equation.

We can show that|Sol(n)|=|M(L\ {⊥} →L)|by providing the following bijection σ:M(L\ {⊥} →L)→Sol(n).The functionσassociates eachf ∈ M(L\ {⊥} → L)with a solutionσ(f)assigning to everyXithe number of consecutive values from L\ {⊥}mapped byf to thei-th value ofL.

From combinatorics we know that for any pair of positive integersn andk, the number ofk-tuples of non-negative integers whose sum isnequals n+k−1n

[5]. For

(7)

1 2 3 4 5

>

1 2 3 4 5

>

LetF1 be the family of functionsf that for all e∈Mn, f(e) =⊥.

LetF2be the family of bottom preserving func- tionsfsuch that for somee, e0∈I: (a)f(>) = e, (b)f(e0) =⊥orf(e0) =e, and (c)f(e00) = efor alle00∈I\ {e0}.

1 2 3 4 5

>

1 2 3 4 5

>

Let F3 be the family of top and bottom pre- serving functionsf such that for somee ∈ I:

(a) f(e) = ⊥, and (b) f(e0) = > for all e0∈I\ {e}.

LetF4be the family of top and bottom preserv- ing functionsfthat for someJ⊆I:

(a)f(e) = >for every e ∈ J, (b) fI\J is injective, and (c)Img(fI\J)⊆I.

Table 1: FamiliesF1, . . . ,F4of join-endomorphisms ofMn. I ={1, . . . , n}. fAis the restriction off to a subsetAof its domain.Img(f)is the image off. A function from eachFiforM5is depicted with blue arrows.

k=n+ 1these tuples correspond exactly to the solutions inSol(n). Therefore we have shown|E(L)|=|M(L)|=|M(L\ {⊥} →L)|=|Sol(n)|= 2nn

as wanted. ut Proof of Theorem 1. We shall show that|E(Mn)|can be expressed in terms of La- guerre polynomials:|E(Mn)|= (n+ 1)2+n!Ln(−1).

LetF = S4

i=1Fi where the mutually exclusiveFi’s are defined in Table 1, and I = {1, . . . , n}. The proof is divided in two parts: (I)F = E(Mn)and (II)|F | = (n+ 1)2+n!Ln(−1).

Part (I) ForF ⊆ E(Mn), it is easy to verify that eachf ∈ Fis a join-endomorphism.

ForE(Mn)⊆ Fwe show that for any functionf fromMn toMniff 6∈ F, then f 6∈ E(Mn). Immediately, iff(⊥)6=⊥thenf 6∈ E(Mn).

Supposef(⊥) = ⊥. Let J, K, H be disjoint possibly empty sets such thatI = J ∪K∪H and let j = |J|,k = |K| and h = |H|. The sets J, K, H represent the elements ofI mapped byf to>, to elements ofI, and to⊥, respectively. More

(8)

precisely,Img(fJ) ={>},Img(fK)⊆IandImg(fH) ={⊥}. Furthermore, for everyfeither (1)f(>) =⊥, (2)f(>)∈Ior (3)f(>) =>. We show thatf 6∈ E(Mn).

1. Casef(>) =⊥.

Sincef 6∈ F1there is ane∈I such thatf(e)6=⊥. We haveev >butf(e)6v f(>). Thenfis not monotonic. From Prop. 1 we concludef 6∈ E(Mn).

2. Casef(>)∈I.

LetK1, K2be disjoint possibly empty sets such thatK1∪K2=K,Img(fK1) = {f(>)}andImg(fK2)6= {f(>)}. Notice that ifj >0or|K2| >0,f is non- monotonic and thenf 6∈ E(Mn).

Now, forj = 0andK2 =∅. SinceImg(fK) ={f(>)}andf 6∈ F2thenh >1.

Therefore there must bee1, e2 ∈ H such thatf(e1) = f(e2) = ⊥. This implies f(e1te2) =f(>)6=⊥=f(e1)tf(e2), thereforef 6∈ E(Mn).

3. Casef(>) =>.

3.1. Supposek = 0. Notice thatf 6∈ F3 andf 6∈ F4 henceh 6= 1andh 6= 0.

Thush > 1implies that there are at least twoe1, e2 ∈H such thatf(e1) = f(e2) =⊥.But thenf(e1te2) =f(>) => 6=⊥=f(e1)tf(e2), hence f 6∈ E(Mn).

3.2. Supposek >0. Assumeh= 0.Notice thatK =I\J andImg(fK)⊆I.

Sincef is a⊥and>preserving function and it satisfies conditions (a) and (c) ofF4 but f 6∈ F4, then f must violate condition (b). Thus fK is not injective. Then there area, b ∈ K such thata 6= bbutf(a) = f(b). Then f(a)tf(b)6=>=f(atb). Consequently,f 6∈ E(Mn).

Assumeh >0. There must bee1, e2, e3∈Isuch thatf(e1) =⊥andf(e2) = e3. Notice thatf(e1)tf(e2) = e3 6=> =f(>) = f(e1te2). Therefore, f 6∈ E(Mn).

Part (II) We prove that|F |=P4

i=1|Fi|= (n+ 1)2+n!Ln(−1). Recall thatn=|I|.

It is easy to prove that|F1|= 1,|F2|=n2+nand|F3|=n.

1. |F1|= 1.

There is only one function mapping every element inMnto⊥.

2. |F2|=n2+n.

Since> is mapped to an element of I, there are n possibilities to choose such element. If there is an element ofImapped to⊥, for each one of the previousn options there are alsonpossibilities to choose an element ofIto be mapped to⊥.

Then, in this case there aren2functions. If no element ofIis mapped to⊥, then there arenadditional functions.

3. |F3|=n.

One of the elements ofIis mapped to⊥. All the other elements ofIare mapped to>. Then, there arenfunctions that can be defined inF3.

4. |F4|=n!Ln(−1).

Letf ∈ F4and letJ ⊆Ibe a possibly empty set such thatImg(fJ) ={>}and Img(fI\J)⊆I, wherefI\Jis an injective function. We shall callj=|J|.

For each of the nj

possibilities forJ, the elements ofI\J are to be mapped to Iby the injective functionfI\J. The number of functionsfI\Jisn!j!. Therefore,

(9)

1 2

>

(a)f1:···→,f2:→,f:99K

1 2

>

(b)f1:···→,f2:→,σS:99K

1 2 3

>

(c)f1:···→,f2:→,δS:99K Fig. 1:S={f1, f2} ⊆ E(L). (a)f =d

E(L)S. (b)σS(c)def=f1(c)uf2(c)is not a join- endomorphism ofM2S(1t2) 6=σS(1)tσS(2).(c)δS in Lemma 1 is not a join- endomorphism of the non-distributive latticeM3S(1)tδS(2) = 16=⊥=δS(1t2).

|F4|=Pn j=0

n j

n!

j!. This sum equalsn!Ln(−1)which in turn is equal toRn(1).

It follows that|F |=P4

i=1|Fi|= (n+ 1)2+n!Ln(−1)as wanted.

It follows that|F |=P4

i=1|Fi|= (n+ 1)2+n!Ln(−1), as wanted. ut

4 Algorithms

We shall provide efficient algorithms for the maximization problem mentioned in the introduction: GivenLandS⊆ E(L)findd

E(L)S, i.e., the greatest join-endomorphism in the latticeE(L)below all the elements ofS.

Findingd

E(L)Smay not be immediate. E.g., seed

E(L)Sin Fig.1a for a small lattice of four elements and two join-endomorphisms. As already mentioned, anaive approach is to computed

E(L)Sby takingσS(c)def=d

L{f(c)|f ∈S}for eachc∈L. This does not work sinceσS is not necessarily a join-endomorphism as shown in Fig.1b.

Abrute forcesolution to computingd

E(L)S can be obtained by generating the set S0 = {g | g ∈ E(L)andg v f for allf ∈ S} and taking its join. This approach works sinceFS0 =d

E(L)Sbut as shown in Section 3, the size ofE(L)can be super- polynomial for distributive lattices and exponential in general.

Nevertheless, one can use lattice properties to computed

E(L)Sefficiently. For dis- tributive lattices, we use the inherent compositional nature of d

E(L)S. For arbitrary lattices, we present an algorithm that uses the function σS in the naive approach to computed

E(L)Sby approximating it from above.

We will give the time complexities in terms of the number of basic binary lattice operations (i.e., meets, joins and subtractions) performed during execution.

(10)

4.1 Meet of Join-Endomorphisms in Distributive Lattices

Here we shall illustrate some pleasant compositionality properties of the infima of join- endomorphisms that can be used for computing the join-endomorphismd

E(L)S in a finite distributive latticeL. In what follows we assumen=|L|andm=|S|.

We useXJto denote the set of tuples(xj)j∈Jof elementsxj∈X for eachj∈J.

Lemma 1. Let L be a finite distributive lattice and S = {fi}i∈I ⊆ E(L). Then d

E(L)S=δSwhere δS(c)def=d

L{F

i∈Ifi(ai)|(ai)i∈I ∈LIand F

i∈Iaiwc}.

The above lemma basically says that d

E(L)S

(c)is the greatest element inLbelow all possible applications of the functions inSto elements whose join is greater or equal toc. The proof that δS wE d

E(L)S uses the fact that join-endomorphisms preserve joins. The proof thatδS vE d

E(L)S proceeds by showing thatδS is a lower bound in E(L)ofS. Distributivity of the latticeLis crucial for this direction. In fact without it d

E(L)S=δSdoes not necessarily hold as shown by the following counter-example.

Example 1. Consider the non-distributive latticeM3 andS ={f1, f2}defined as in Fig.1c. We obtainδS(1t2) =δS(>) = ⊥andδS(1)tδS(2) = 1t ⊥= 1. Then, δS(1t2)6=δS(1)tδS(2), i.e.,δSis not a join-endomorphism.

Naive AlgorithmA1. One could use Lemma 1 directly in the obvious way to provide an algorithm ford

E(L)Sby computingδS: i.e., computing the meet of elements of the formF

i∈Ifi(ai)for every tuple(ai)i∈I such thatF

i∈Iaiwc.For eachc∈L,δS(c) checksnmtuples(ai)i∈I, each one with a cost inO(m). ThusA1can computed

E(L)S by performingO(n×nm×m) =O(mnm+1)binary lattice operations.

Nevertheless, we can use Lemma 1 to provide a recursive characterization ofd

E(L)S that can be used in a divide-and-conquer algorithm with lower time complexity.

Proposition 5. LetLbe a finite distributive lattice andS = S1∪S2 ⊆ E(L). Then d

E(L)S (c) =d

L{ d

E(L)S1

(a)t d

E(L)S2

(b)|a, b∈L and atbwc}.

The above proposition bears witness to the compositional nature of d

E(L)S. It can be proven by replacing d

E(L)S1

(a)and d

E(L)S2

(b)by δS1(a)andδS2(b) using Lemma 1 (see Appendix A).

Naive AlgorithmA2. We can use Prop.5 to computed

E(L)S with the following re- cursive procedure: Take any partition{S1, S2} of S such that the absolute value of

|S1| − |S2|is at most 1. Then compute the meet of all d

E(L)S1

(a)t d

E(L)S2 (b) for every a, b such that at b w c. Then given c ∈ L, the time complexity of a naive implementation of this algorithm can be obtained as the solution of the equa- tionT(m) = n2(1 + 2T(m/2))andT(1) = 1which is inO(mn2 log2m). Therefore, d

E(L)Scan be computed inO(mn1+2 log2m).

The time complexity of the naive algorithmA2is better than that ofA1. However, by using a simple memoization technique to avoid repeating recursive calls and the following observations one can computed

E(L)Sin a much lower time complexity order.

(11)

4.2 Using Subtraction and Downsets to characterized

E(L)S In what follows we show that d

E(L)S can be computed in O(mn2) for distributive lattices and, in particular, inO(n+mlogn)for powerset lattices. To achieve this we use the subtraction operator from co-Heyting algebras and the notion of down set.

Subtraction Operator. Notice that in Prop.5 we are consideringallpairsa, b∈Lsuch thatatbwc. However, because of the monotonicity of join-endomorphisms, it suffices to take, for eacha∈L, justthe leastbsuch thatatbwc. In finite distributive lattices, and more generally in co-Heyting algebras [6], thesubtractionoperatorc\agives us exactly such a least element. The subtraction operator is uniquely determined by the property (Galois connection)bwc\aiffatbwcfor alla, b, c∈L.

Down-sets. Besides using justc\ainstead of allb’s such thatatb w c, we can use a further simplification: Rather than including everya ∈L,we only need to consider everyain thedown-setof c. Recall that the down-set ofc is defined as↓c = {e ∈ L |e v c}. This additional simplification is justified using properties of distributive lattices to show that for any a0 ∈ L, such thata0 6v c, there existsa v c such that

d

E(L)S1

(a)t d

E(L)S2

(c\a)v d

E(L)S1

(a0)t d

E(L)S2

(c\a0).

The above observations lead us to the following theorem.

Theorem 2. Let L be a finite distributive lattice and S = S1∪S2 ⊆ E(L). Then d

E(L)S (c) =d

L{ d

E(L)S1

(a)t d

E(L)S2

(c\a)|a∈ ↓c}.

The above result can be used to derive a simple recursive algorithm that, given a finite distributive latticeLandS ⊆ E(L), computesd

E(L)S in worst-case time com- plexityO(mn2)wherem=|S|andn=|L|. We show this algorithm next.

4.3 Algorithms for Distributive Lattices

We first describe the algorithm DMEETAPP that computes the value d

E(L)S (c).

We then describe the algorithm DMEET that computes the functiond

E(L)S by call- ing DMEETAPPin a particular order to avoid repeating computations. To specify the calling order we need the following definition.

Definition 2. Abinary partition tree (bpt)of a finite setS 6=∅is a binary tree such that (a) its root isS, (b) if|S|= 1then its root is a leaf, and (c) if|S|>1it has a left and a right subtree, themselves bpts ofS1andS2resp., for a partition{S1, S2}ofS.

Let∆be a bpt ofS.We use∆(S0)for the subtree of∆rooted atS0 ⊆S, if it exists.

Clearly,∆=∆(S). We use the triplehS, ∆1, ∆2ifor the bpt ofSwith∆1and∆2as its left and right subtrees.

The following proposition is an immediate consequence of the previous definition.

Proposition 6. The size (number of nodes) of any bpt ofSis2m−1wherem=|S|.

(12)

DMEETAPP(∆, c). Let∆=hS, ∆1, ∆2ibe a bpt ofS⊆ E(L)whereLis a distribu- tive lattice. The recursive program DMEETAPP(∆, c)defined in Algorithm 1 computes

d

E(L)S

(c). It uses a global lookup tableT for storing the results of calls to DMEE-

TAPP. Initially each entry ofT stores anullvalue not included in L. SinceS is the union of the roots of∆1and∆2, the correctness of DMEETAPP(∆, c)follows from Thm.2. Termination follows from the fact thatLis finite and the bpts∆1and∆2in the recursive calls are strictly smaller than∆.

Algorithm 1DMEETAPP(∆, c)returns d

E(L)S

(c)where∆ is a bpt ofS ⊆ E(L) andLis a finite distributive lattice. The global variableT is used as a lookup table.

1: procedureDMEETAPP(∆, c) . ∆=hS, ∆1, ∆2i

2: ifIsNull(T[S, c])then 3: ifS={f}then

4: T[S, c]←f(c)

5: else

6: T[S, c]←d

L{DMEETAPP(∆1, a)tDMEETAPP(∆2, c\a)|a∈ ↓c}.

Computingd

E(L)Sfor Distributive Lattices. We show how to computed

E(L)Swith a worst-case time complexity inO(mn2).

LetL be a finite lattice of sets and ∆ = hS, ∆1, ∆2i be a bpt of S ⊆ E(L).

Letn =|L|andm = |S|.Let us consider an execution of DMEETAPP(∆, c). From the definition of subtraction it follows that c\a ∈ ↓c. Then for each recursive call DMEETAPP(∆0, a0)performed by an execution of DMEETAPP(∆, c)we havea0∈ ↓c. The above leads us to the following observation about the order of the number of bi- nary lattice operations (meets, joins, and subtractions) performed by DMEETAPP(∆, c).

Observation 3 Let∆ = hS, ∆1, ∆2iwith∆1 and∆2rooted atS1and S2. Assume that T[S1, a0], T[S2, a0] ∈ Lfor everya0 ∈ ↓c .Then the number of binary lattice operations performed byDMEETAPP(∆, c)is inO(| ↓c|).

Since each entry ofT is initialized with a null value not inL, the assumption in Obs.3 implies that for everya0 ∈ ↓c the values of DMEETAPP(∆1, a0)and DMEE-

TAPP(∆2, a0)have been previously stored inT.Under this condition DMEETAPP(∆, c) performs at most| ↓c|binary joins,| ↓c|subtractions,| ↓c| −1binary meets.

DMEET(L, S, P). The values of d

E(L)S

(c)for eachc∈P ⊆Lare computed by the program in Algorithm 2 as follows. The program first initializes the tableT with a nullvalue. Then, to satisfy the assumption in Obs.3, it traverses∆and the elements ofP as follows: It visits each nodeS0 of∆inpost-order(i.e., before visiting a node it first visits its children). For each subtree∆(S0)of∆, it calls DMEETAPP(∆(S0), c) for everyc∈ Pinincreasing order with respect to the order ofL: I.e., before calling DMEETAPP(∆(S0), c)it calls first DMEETAPP(∆(S0), c0)for eachc0∈(P∩↓c)\{c}.

The correctness of the call DMEET(L, S, P)follows from that of DMEETAPP(∆, c).

(13)

Algorithm 2 Given a finite distributive lattice L, P ⊆ L and S ⊆ E(L), DMEET(L, S, P)computes T[S, c] = d

E(L)S(c)for each c ∈ P.∆ is a bpt of S andT is a global lookup table.

1: T[S0, a]←null .for eacha∈Pand each nodeS0of∆ 2: foreachS0in a post-order traversal sequence of∆do .visit eachS0of∆in post-order 3: foreachc∈Pin increasing orderdo .visit eachc∈Pin increasing order w.r.tL 4: DMEETAPP(∆(S0), c)

Complexity for Distributive Lattices. Assume thatLis a distributive lattice of sizenand thatSis a subset ofE(L)of sizem. The above-mentioned traversals of∆andPensure that the assumption in Obs.3 is satisfied by each call of the form DMEETAPP(∆(S0), c) performed during the execution of DMEET(L, S). From Prop.6 we know that the num- ber of iterations of the outerforis2m−1. Clearly| ↓c|and|P|are both inO(n).Thus, givenS0 we conclude from Obs.3 that the total number of operations from all calls of the form DMEETAPP(∆(S0), c), executed in the innerfor, is inO(n2).The worst-case time complexity of DMEET(L, S, L)is then inO(mn2).

Complexity for Powerset Lattices. Assume now thatLis a powerset lattice. We can compute d

E(L)S in a much lower worst-case time complexity as follows: First call DMEET(L, S, P)whereP =J(L)∪ {⊥}andJ(L)is the set ofjoin-irreducibleele- ments (i.e., the singleton sets in this case) ofL. Since|J(L)|= log2nand| ↓c|= 2 for every c ∈ J(L), DMEET(L, S, P) can be performed in O(mlogn). This pro- duces T[S, c] = d

E(L)S

(c)for eachc ∈ P ⊆ L. The computation ofT[S, e] = d

E(L)S

(e)for eache ∈L\P can be performed inO(n).This can be achieved by visiting eache∈L\P in increasing order and settingT[S, e] =T[S, a]tT[S, b]for somea, b∈ ↓e\ {e}such thate=atb.Sincee6∈P there must beaandbsatisfying the above conditions. The total cost of computingd

E(L)Sis therefore inO(n+mlogn).

4.4 Algorithms for Arbitrary Lattices

The previous algorithm may fail to produce thed

E(L)Sfor non-distributive finite lat- tices. Nonetheless, for any arbitrary finite latticeL,d

E(L)Scan be computed by succes- sive approximations, starting with some self-map known to be smaller than eachf∈S and greater thand

E(L)S. Assume a self-mapσ: L→ Lsuch thatσwd

E(L)S and, for all f ∈ S, σ v f. A good starting point is σ(u) = d

{f(u) |f ∈ S}, for all u∈L. By definition ofu,σ(u)is the biggest function under all functions inS, hence σwd

E(L)S. The program GMEETin Algorithm 3 computes decreasing upper bounds ofd

E(L)Sby correctingσvalues not conforming to the followingjoin-endomorphism property:σ(u)tσ(v) = σ(utv).The correction decreasesσand maintains the in- variantσwd

E(L)S, as stated in Thm.4.

Theorem 4. LetLbe a finite lattice,u, v ∈ L,σ : L → LandS ⊆ E(L). Assume σwd

E(L)Sholds, and consider the following updates:

1. whenσ(u)tσ(v)@σ(utv), assignσ(utv)←σ(u)tσ(v)

(14)

2. whenσ(u)tσ(v)6vσ(utv), assignσ(u)←σ(u)uσ(utv)and alsoσ(v)← σ(v)uσ(utv)

Letσ0be the function resulting after the update. Then, (1)σ0@σand (2)σ0 wd

E(L)S.

Algorithm 3GMEETfindsσ=d

E(L)S 1: σ(u)←d

{f(u)|f∈S} .for allu∈L

2: whileu, v∈L∧σ(u)tσ(v)6=σ(utv)do

3: ifσ(u)tσ(v)@σ(utv)then .case (1)

4: σ(utv)←σ(u)tσ(v)

5: else .case (2)

6: σ(u)←σ(u)uσ(utv) 7: σ(v)←σ(v)uσ(utv)

The procedure (see Algo.3) loops through pairsu, v ∈ Lwhile there is some pair satisfying cases (1) or (2) above for the currentσ. When there is, it updatesσas men- tioned in Thm.4. At the end of the loop all pairsu, v ∈Lsatisfy the join preservation property. By the invariant mentioned in the theorem, this meansσ=d

E(L)S.

As for the previous algorithms in this paper the worst-time time complexity will be expressed in terms of the binary lattice operations performed during execution. Assume a fixed set S of sizem. The complexity of the initialization (Line 1) of GMEET is O(nm)withn =|L|. The value ofσfor a givenw ∈ Lcan be updated (decreased) at mostntimes. Thus, there are at mostn2updates ofσfor all values ofL. Finding a w=utvwhereσ(w)needs an update becauseσ(u)tσ(v)6=σ(utv)(test of the loop, Line 2) takesO(n2). Hence, the worst time complexity of the loop is inO(n4).

The program GMEET+ in Algo.4 uses appropriate data structures to reduce signifi- cantly the time complexity of the algorithm. Essentially, different sets are used to keep track of properties of(u, v)lattice pairs with respect to the currentσ. We have a support (correct) pairs setSupw={(u, v)|w=utv∧σ(u)tσ(v) =σ(w)}. We also have a conflicts setConw = {(u, v)|w =utv∧σ(u)tσ(v)@σ(w)}and failures set Failw={(u, v)|w=utv∧σ(u)tσ(v)6vσ(w)}.

Algorithm 4 updatesσas mentioned in Thm.4 and so maintains the invariantσw d

E(L)S. An additional invariant is that, for allw, setsSupw,Conw,Failware pairwise disjoint. When the outer loop finishes setsConwandFailware empty (for allw) and thus every(u, v)belongs toSuputv, i.e. the resultingσ=d

E(L)S.

Auxiliary procedureCHECKSUPPORTS(u)identifies all pairs of the form(u, x)∈ Suputx that may no longer satisfy the join-endomorphism propertyσ(u)tσ(x) = σ(utx)because of an update toσ(u). When this happens, it adds(u, x)to the ap- propriateCon, orFailset. The time complexity of the algorithm depends on the set operations computed for eachw ∈Lchosen, either in theconflictsConwset or in the failuresFailwset. When awis selected (for some(u, v)such thatutv = w) the following holds: (1) at least one ofσ(w), σ(u), σ(v)is decreased, (2) some fixknum- ber of elements are removed from or added to a set, (3) a union of twodisjointsets is computed, and (4) new support sets ofw, uorvare calculated.

(15)

Algorithm 4GMEET+ findsσ=d

E(L)S 1: σ(u)←d

{f(u)|f∈S} .for allu∈L

2: InitializeSupw,Conw,Failw, for allw

3: whilew∈Lsuch that(u, v)∈Conwdo .some conflict set not empty 4: Conw←Conw\{(u, v)}

5: σ(w)←σ(u)tσ(v)

6: Failw←Failw∪Supw .all pairs previously inSupware now failures 7: Supw← {(u, v)}

8: CHECKSUPPORTS(w) .foru∈L, verify propertySupwtu

9: whilez∈Lsuch that(x, y)∈Failzdo .some failures set not empty 10: Failz←Failz\{(x, y)}

11: ifσ(x)6=σ(x)uσ(z)then

12: σ(x)←σ(x)uσ(z) . σ(x)decreases

13: Failx←Failx∪Supx .all pairs inSupxare now failures

14: Supx← ∅

15: CHECKSUPPORTS(x) .foru∈L, verify propertySupxtu

16: ifσ(y)6=σ(y)uσ(z)then

17: σ(y)←σ(y)uσ(z) . σ(y)decreases

18: Faily←Faily∪Supy .all pairs inSupyare now failures

19: Supy← ∅

20: CHECKSUPPORTS(y) .foru∈L, verify propertySupytu

21: ifσ(x)tσ(y) =σ(z)then

22: Supz←Supz∪ {(x, y)} .(x, y)is now correct

23: else

24: Conz←Conz∪ {(x, y)} .(x, y)is now a conflict

With an appropriate implementation, operations (1)-(2) takeO(1), and also opera- tion (3), since sets are disjoint. Operation (4) clearly takesO(n). In each loop of the (outer or inner) cycles of the algorithm, at least oneσreduction is computed. Further- more, for each reduction ofσ,O(n)operations are performed. The maximum possible number ofσ(w)reductions, for a givenw, is equal to the lengthdof the longest strictly decreasing chain in the lattice. The total number of possibleσreductions is thus equal tond. The total number of operations of the algorithm is then O(n2d). In general,d could be (at most) equal ton, therefore, after initialization, worst case complexity is O(n3). The initialization (Lines 1-2) takesO(nm) +O(n2), wherem = |S|. Worst time complexity is thusO(mn+n3). For powerset lattices,d= log2n, thus worst time complexity in this case isO(mn+n2log2n).

4.5 Experimental Results and Small Example

Here we present some experimental results showing the execution time of the proposed algorithms. We also discuss a small example with join-endomorphisms representing dilation operators from Mathematical Morphology [2]. We use the algorithms presented above to compute the greatest dilation below a given set of dilations and illustrate its result for a simple image.

(16)

Fig. 2:Average performance time of GMEET+, DMEETand BRUTE-FORCE. Plots A and D use 2nlattices, B and E distributive lattices, and C and F arbitrary (possibly non-distributive) lattices.

Plots A-C have a fixed number of join-endomorphisms and plots D-F have a fixed lattice size.

Consider Figure 2. In plots 2.A-C, the horizontal axis is the size of the lattice. In plots 2.D-F, the horizontal axis is the size ofS. Curves in images 2.A-C plot, for each algorithm, the average execution time of 100 runs (10 for 2.A) with random setsS ⊆ E(L) of size 4. Images 2.D-F, show the mean execution time of each algorithm for 100 runs (10 for 2.D) varying the number of join-endomorphisms (|S| = 4i,1 ≤i≤ 8). The lattice size is fixed:|L| = 10for 2.E and 2.F, and |L| = 25 for 2.D. In all cases the lattices were randomly generated, and the parameters selected to showcase the difference between each algorithm with a sensible overall execution time. For a given latticeLandS ⊆ E(L), the brute-force algorithm explores the whole spaceE(L)to find all the join-endomorphism below each element ofSand then computes the greatest of them. In particular, the measured spike in plot 2.C corresponds to the random lattice of seven elements with the size ofE(L)being bigger than in the other experiments in the same figure. In our experiments we observed that for a fixedS, as the size of the lattice increases, DMEEToutperforms GMEET+. This is noticeable in lattices2n(see 2.A). Similarly, for a fixed lattice, as the size ofS increases GMEET+ outperforms DMEET. GMEET+ performance can actually improve with a higher number of join- endomorphisms (see 2.D) since the initialσis usually smaller in this case.

To illustrate some performance gains, Table 2 shows the mean execution time of the algorithms discussed in this paper. We includeA1andA2, the algorithms outlined just after Lemma 1 and Proposition 5.

An MM Example.Mathematical morphology (MM) is a theory, based on topologi- cal, lattice-theoretical and geometric concepts, for the analysis of geometric structures.

Its algebraic framework comprises [2,14,17], among others, complete lattices together with certain kinds of morphisms, such asdilations, defined asjoin-endomorphisms[14].

Our results give bounds about the number of all dilations over certain specific finite lat- tices and also efficient algorithms to compute their infima.

A typical application of MM is image processing. Consider the spaceG=Z2. A dilation [2] bysi ⊆ P(G)is a functionδsi : P(G) → P(G) such thatδsi(X) =

(17)

Size A1 A2 GMEET GMEET+ DMEET

16 2.01 0.958 0.00360 0.000603 0.000632

32 64.6 25.3 0.0633 0.00343 0.00181

64 1901 600 0.948 0.0154 0.00542

128 >600 >600 15.4 0.0860 0.0160

256 >600 >600 252 0.361 0.0483

512 >600 >600 >600 2.01 0.166

1024 >600 >600 >600 10.7 0.547

Table 2: Average time in seconds over powerset lattices with|S|= 4

{x+e|x∈X ande∈si}. The dilationδsi(X)describes the interaction of an image X with thestructuring elementsi. Intuitively, the dilation ofX bysi is the result of superimposesi on every activated pixel ofX, with the center ofsi aligned with the corresponding pixel of X. Then, each pixel of every superimposed si is included in δsi(X).

LetLbe the powerset lattice for some finite setD⊆G.It turns out that the dilation d

E(L)Scorresponds to the intersection of the structuring elements of the corresponding dilations in S. Fig.3 illustratesd

E(L)S for the two given dilationsδs1(I)andδs2(I) with structuring elementss1ands2over the given imageI.

Fig. 3:Binary imageI(on the left). Dilationsδs1s2 for structuring elementss1,s2. On the right d

E(L)s1, δs2}

(I). New elements of the image after each operation in grey and black.

5 Conclusions and Related Work

We have shown that given a latticeLof sizenand a setS ⊆ E(L)of sizem,d

E(L)S can be computed in the worst-case inO(n+mlogn)binary lattice operations for pow- erset lattices,O(mn2)for lattices of sets, andO(nm+n3)for arbitrary lattices. We illustrated the experimental performance of our algorithms and a small example from mathematical morphology.

In [10] a bit-vector representation of a lattice is discussed. This work gives algo- rithms of logarithmic (in the size of the lattice) complexity for join and meet opera-

(18)

tions. These results count bit-vector operations. From [1] we know thatE(L)is iso- morphic to the downset of(P ×Pop), whereP is the set of join-prime elements of L, and that this, in turn, is isomorphic to the set of order-preserving functions from (P ×Pop) to2. Therefore, for the problem of computing d

E(L)S, we get bounds O(mlog2(2(n2)) = O(mn2)for set lattices andO(m(log2n)2)for powerset lattices wheren =|L|andm =|S|.This, however, assumes a bit-vector representation of a lattice isomorphic toE(L). Computing this representation takes time and space propor- tional to the size ofE(L)[10] which could be exponential as stated in the present paper.

Notice that in our algorithms the input lattice isLinstead ofE(L).

We have stated the cardinality of the set of join-endomorphismsE(L)for signifi- cant families of lattices. To the best of our knowledge we are the first to establish the cardinality(n+ 1)2+n!Ln(−1)for the latticeMn.The cardinalitiesnlog2nfor power sets (boolean algebras) and 2nn

for linear orders can also found in the lattice literature [1,11,16]. We presented our original proofs of these statements.

The latticeE(L) have been studied in [7]. The authors showed that a finite lat- ticeLis distributive iffE(L)is distributive. A lower bound of22n/3 for the number of monotonic self-maps of any finite posetLis given in [4]. Nevertheless to the best of our knowledge, no other authors have studied the problem of determining the size E(L)nor algorithms for computingd

E(L)S.We believe that these problems are impor- tant, as argued in the Introduction, algebraic structures consisting of a lattice and join- endomorphisms are very common in mathematics and computer science. In fact, our interest in this subject arose in the algebraic setting of spatial and epistemic constraint systems [9] where continuous join-endomorphisms, called space functions, represent knowledge and the infima of endomorphisms correspond to distributed knowledge. We showed in [9] that distributed knowledge can be computed inO(mn1+log2(m))for dis- tributive lattices and O(n4) in general. In this paper we have provided much lower complexity orders for computing infima of join-endomorphisms. Furthermore [9] does not provide the exact cardinality of the set of space function of a given lattice.

As future work we plan to explore in detail the applications of our work in mathe- matical morphology and computer music [15]. Furthermore, in the same spirit of [12]

we have developed algorithms to generate distributive and arbitrary lattices. In our experiments, we observed that for every lattice Lof size nwe generated,nlog2n

|E(L)| ≤(n+ 1)2+n!Ln(−1)and if the generated lattice was distributive,nlog2n

|E(L)| ≤ 2nn

.We plan to establish if these inequalities hold for every finite lattice.

Acknowledgments. We are indebted to the anonymous referees and editors of RAM- ICS 2020 for helping us improve one of the complexity bound, some proofs, and the overall quality of the paper.

References

1. Birkhoff, G.: Lattice Theory. No. v. 25,pt. 2 in American Mathematical Society colloquium publications, American Mathematical Society (1967)

2. Bloch, I., Heijmans, H., Ronse, C.: Mathematical morphology. In: Aiello, M., Pratt- Hartmann, I., Van Benthem, J. (eds.) Handbook of Spatial Logics. pp. 857–944. Springer Netherlands (2007)

(19)

3. Davey, B.A., Priestley, H.A.: Introduction to lattices and order. Cambridge university press, 2nd edn. (2002)

4. Duffus, D., Rodl, V., Sands, B., Woodrow, R.: Enumeration of order preserving maps. Order 9(1), 15–29 (1992)

5. Feller, W.: An introduction to probability theory and its applications. Wiley series in proba- bility and mathematical statistics: Probability and mathematical statistics, Wiley (1971) 6. Gierz, G., Hofmann, K.H., Keimel, K., Lawson, J.D., Mislove, M., Scott, D.S.: Continuous

lattices and domains. Cambridge University Press (2003)

7. Gr´’atzer, G., Schmidt, E.: On the lattice of all join-endomorphisms of a lattice. Proceedings of The American Mathematical Society - PROC AMER MATH SOC9, 722–722 (1958) 8. Guzm´an, M., Haar, S., Perchy, S., Rueda, C., Valencia, F.D.: Belief, knowledge, lies and

other utterances in an algebra for space and extrusion. J. Log. Algebr. Meth. Program.86(1), 107–133 (2017)

9. Guzm´an, M., Knight, S., Quintero, S., Ram´ırez, S., Rueda, C., Valencia, F.D.: Reasoning about Distributed Knowledge of Groups with Infinitely Many Agents. In: CONCUR 2019 - 30th International Conference on Concurrency Theory. vol. 29, pp. 1–29 (2019)

10. Habib, M., Nourine, L.: Tree structure for distributive lattices and its applications. Theoreti- cal Computer Science165(2), 391 – 405 (1996)

11. Jipsen, P.: Relation algebras, idempotent semirings and generalized bunched implication al- gebras. In: Relational and Algebraic Methods in Computer Science. pp. 144–158. Springer International Publishing (2017)

12. Jipsen, P., Lawless, N.: Generating all finite modular lattices of a given size. Algebra univer- salis74(3), 253–264 (2015)

13. Knight, S., Palamidessi, C., Panangaden, P., Valencia, F.D.: Spatial and Epistemic Modali- ties in Constraint-Based Process Calculi. In: 23rd International Conference on Concurrency Theory. Lecture Notes in Computer Science, vol. 7454, pp. 317–332. Springer (2012) 14. Ronse, C.: Why mathematical morphology needs complete lattices. Signal Processing21(2),

129–154 (1990)

15. Rueda, C., Valencia, F.: On validity in modelization of musical problems by ccp. Soft Com- puting8(9), 641–648 (2004)

16. Santocanale, L.: On Discrete Idempotent Paths. In: Combinatorics on Words. vol. 11682, pp.

312–325. Springer (2019)

17. Stell, J.: Why mathematical morphology needs quantales. In: Wilkinson, M., Roerdink, J.

(eds.) International Symposium on Mathematical Morphology, ISMM09. pp. 13–16. Institute for Mathematics and Computing Science, University of Groningen (2009)

(20)

A Proofs

A.1 Proof of Lemma 1

Let L be a finite distributive lattice and S = {fi}i∈I ⊆ E(L). Then d

E(L)S = δSwhere δS(c)def=d

L{F

i∈Ifi(ai)|(ai)i∈I ∈LIand F

i∈Iaiwc}.

Proof. Recall thatd

E(L)S =max{h∈ E(L)|hvE gfor allg∈S}and let us define Γ ={F

i∈Ifi(ai)|(ai)i∈I ∈LI and F

i∈Iai wc}. We prove (1)d

E(L)SvE δSand (2)δS vE d

E(L)S.

1. d

E(L)S vE δS.

Letc ∈ Land(ai)i∈I ∈ LI be an arbitrary tuple such that F

i∈Iai w c. No- tice thatF

i∈I

d

E(L)S

(ai)vF

i∈Ifi(ai). Sinced

E(L)Sis a join-endomorphism ofLand monotonic, we know thatF

i∈I

d

E(L)S

(ai) = d

E(L)S (F

i∈Iai) w d

E(L)S

(c). Thus d

E(L)S (c)vF

i∈Ifi(ai), i.e., d

E(L)S

(c)is a lower bound ofΓ. Then for everyc∈L, d

E(L)S

(c)vδS(c). Therefored

E(L)SvE δS. 2. δS vE d

E(L)S.

We prove (a)δS ∈ E(L)and (b)δS vE fifor everyfi ∈S.

(a) Prove thatδS vE fi, for everyfi∈S.

Letc∈L. From definition ofδS, for everyi∈I, the elementfi(c) =fi(c)t F

j∈I\{i}fj(⊥) ∈ Γ. Then for everyc ∈ L,δS(c) v fi(c). Therefore for everyfi∈S,δS vE fi.

(b) δS∈ E(L).

We show that for anyH ⊆L,δS(F

H) =F

S(e)| for everye∈H}. Since His finite, it suffices to show that our claim holds forH=∅andH={c, d}.

AssumeH =∅. One can verify thatδS(⊥) =⊥.

AssumeH ={c, d}. Firstly, we prove thatδS is monotonic. Supposec wd.

For any(ai)i∈I ∈LIsuch thatF

i∈Iai wc, we haveF

i∈Iaiwd. Therefore, {F

i∈Ifi(ai)| F

i∈Iai wc} ⊆ {F

i∈Ifi(ai)| F

i∈Iai wd}which implies δS(c)wδS(d).

By monotonicity ofδS, we knowδS(ctd)wδS(c)tδS(d). The other direc- tion follows from the derivation below:

(21)

δS(c)tδS(d)

=hDefinition ofδS(d)i δS(c)tl

L

{G

i∈I

fi(bi)|(bi)i∈I ∈LIand G

i∈I

biwd}

=htdistributes overui l

L

S(c)tG

i∈I

fi(bi)|(bi)i∈I ∈LI and G

i∈I

biwd}

=hDefinition ofδS(c)i l

L

{l

L

{G

i∈I

fi(ai)|(ai)i∈I ∈LI and G

i∈I

aiwc} tG

i∈I

fi(bi)|(bi)i∈I ∈LI and G

i∈I

biwd}

=htdistributes overui l

L

{l

L

{G

i∈I

fi(ai)tG

i∈I

fi(bi)|(ai)i∈I ∈LIand G

i∈I

aiwc} |(bi)i∈I ∈LI and G

i∈I

biwd}

=hAssociativity ofui l

L

{G

i∈I

(fi(ai)tfi(bi))|(ai)i∈I,(bi)i∈I ∈LI and G

i∈I

aiwcand G

i∈I

biwd}

whxwyandwwzimpliesxtwwytz;ci=aitbi;fi(ci)=fi(aitbi)i l

L

{G

i∈I

fi(ci)|(ci)i∈I ∈LI and G

i∈I

ciwctd}

=hDefinition ofδS(ctd)i δS(ctd)

Thus we concludeδS ∈ E(L).

From items (a) and (b),δS vE d

E(L)Sholds.

We concluded

E(L)S=δS. A.2 Proof of Corollary 2.

We wish to prove that|A|=Rn(1)whereA={f ∈ E(Mn)|f is non-reducing inMn}.

LetF =S4

i=1Fiwhere the mutually exclusiveFi’s are defined in Table 1. In the proof of Theorem 1 we show thatE(Mn) = F and thatRn(1) = |F4|. Notice that every function inF4is non-reducing and every function inF \ F4is not non-reducing. Hence A=F4, thus|A|=Rn(1).

A.3 Proof of Proposition 5

Let(L,v)be a finite distributive lattice andS ={fi}i∈I ⊆ E(L). LetS1, S2 ⊆ E(L) be such thatS=S1∪S2. Then

l

E(L)S

(c) =l

L

{ l

E(L)S1

(a)t l

E(L)S2

(b)|atbwc}.

Références

Documents relatifs

In this paper we give a strong negative solution to this problem, by proving (Corollary 4.2) that in any non-distributive variety of lattices, if F is any (bounded or not) free

It originates in the observation that the construction of the Boolean algebra of the proof of Theorem A does not rely on the Axiom of Choice (but it has size the continuum), while

Hence all finite, or, more generally, finitely presented lattices, lower bounded homomorphic images of free lattices, and projective lattices have the weak minimal join-cover

The Strong Independence Theorem for automorphism groups and congruence lattices of arbitrary lattices.. George Grätzer,

Most known partial neg- ative solutions to CLP are obtained via certain infinitary sentences of the theory of semilattices that hold in all semilattices of the form Con c L, for L

In other words, the joint distribution of the number of non-initial contacts (of the lower path) and the initial rise (of the upper path) is symmetric.. For any ring A, we denote

When G is a simple Lie group, for instance, Theorem 2.9 and Proposition 2.2 imply that every IRS of G is supported on discrete subgroups, except for a possible atom on the

The transition from the low density phase to a glass phase is continuous at small p and discontinuous at large