<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>Steps in the Representation of Concept Lattices and Median Graphs</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Alain Gély</string-name>
          <email>alain.gely@loria.fr</email>
          <xref ref-type="aff" rid="aff2">2</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Miguel Couceiro</string-name>
          <email>miguel.couceiro@loria.fr</email>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Laurent Miclet</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Amedeo Napoli</string-name>
          <email>amedeo.napoli@loria.fr</email>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>Univ Rennes</institution>
          ,
          <addr-line>CNRS, IRISA, Rue de Kérampont, 22300 Lannion</addr-line>
          ,
          <country country="FR">France</country>
        </aff>
        <aff id="aff1">
          <label>1</label>
          <institution>Université de Lorraine</institution>
          ,
          <addr-line>CNRS, Inria, LORIA, F-54000 Nancy</addr-line>
          ,
          <country country="FR">France</country>
        </aff>
        <aff id="aff2">
          <label>2</label>
          <institution>Université de Lorraine</institution>
          ,
          <addr-line>CNRS, LORIA, F-57000 Metz</addr-line>
          ,
          <country country="FR">France</country>
        </aff>
      </contrib-group>
      <fpage>247</fpage>
      <lpage>258</lpage>
      <abstract>
        <p>Median semilattices have been shown to be useful for dealing with phylogenetic classification problems since they subsume median graphs, distributive lattices as well as other tree based classification structures. Median semilattices can be thought of as distributive ∨-semilattices that satisfy the following property (TRI): for every triple x, y, z, if x ∧ y, y ∧ z and x ∧ z exist, then x ∧ y ∧ z also exists. In previous work we provided an algorithm to embed a concept lattice L into a distributive ∨-semilattice, regardless of (TRI). In this paper, we take (TRI) into account and we show that it is an invariant of our algorithmic approach. This leads to an extension of the original algorithm that runs in polynomial time while ensuring that the output is a median semilattice.</p>
      </abstract>
      <kwd-group>
        <kwd>Median graph</kwd>
        <kwd>Distributive lattice</kwd>
        <kwd>Order embedding</kwd>
        <kwd>Formal Concept Analysis</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>-</title>
      <p>
        Trees constitute noteworthy examples of classification structures that are
commonly used in applied sciences [
        <xref ref-type="bibr" rid="ref10 ref6">6,10</xref>
        ]. However, they do not offer a sufficient
representation power for some applications. For instance, in phylogenetic
modeling they fail to capture the complexity of evolution in presence of parallel or
reverse mutations [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ]. Indeed, the latter mutations introduce ambiguity, and it
is not possible to design a tree representing such evolution.
      </p>
      <p>Distributive lattices can model phylogenetic evolution by exhibiting in a
single structure all potential evolutions, while preserving the principle of parsimony,
which states that no unnecessary evolution is introduced. The drawback is that
classical tree-like structures are not lattices but remain relevant for several simple
cases.</p>
      <p>
        A generalization of both trees and distributive lattices is provided by the
so called median algebras [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ]. In finite cases, they can be considered in two
equivalent ways:
– as median graphs that ensure the existence and uniqueness of a “barycenter”
of every triple of vertices (which, in turn, ensures parsimony): for every
triple x, y, z of vertices, there exists a unique vertex at the intersection of
the shortest paths between any pair of these vertices, or
– as median semilattices, i.e., distributive ∨-semilattices that satisfy the
following additional property: for every triple x, y, z of elements, if x ∧ y, y ∧ z
and x ∧ z exist, then x ∧ y ∧ z also exists.
      </p>
      <p>
        An example of median graph is shown in Fig. 1 for binary data used by Bandelt
[
        <xref ref-type="bibr" rid="ref5">5</xref>
        ] and coming from [
        <xref ref-type="bibr" rid="ref25">25</xref>
        ]. The data table shows variations from a consensus
value for some sequences in mitochondrial DNA (nucleotide positions, denoted
by a, b, . . . , j in table) for 8 individuals groups of Khoisan-speaking
huntergathered populations in southern Africa. Vertices of the median graph are either
individuals (numbered from 0 to 7) or latent vertices (spotted as Lx), added such
that only one variation exists for nucleotide sequences (principle of parsimony
supposes that there is no chance that two variations arise exactly at the same
moment for a population in an evolutionary process).
      </p>
      <p>As stated, this graph contains every parsimonious tree as covering tree: For
individuals represented by vertex 0, there is not enough data to determine if
the evolutionary path from the consensus started with a variant on position k
and then j, or started with a variant on j and then k. The strength of median
graphs is to display these two possibilities at once, which is not possible with
a parsimonious tree. Every finite ∨-semilattice with a ⊥ element constitutes a
a b c d e f g h i j k
0
1 ×
2
3 ×
4
5
6
7
×
×
×
×
×
×
×</p>
      <p>× ×
×
× ×</p>
      <p>× ×
×</p>
      <p>×
×
×</p>
      <p>L3
i e
consensus</p>
      <p>k j
a L4 L1</p>
      <p>h j k c d
L2 0 / jk 2 / cj
b
j h</p>
      <p>
        f
3 / ai 1 / ae 6 / bhk 4 / hjk 7 / cfj 5 / d
lattice, and thus a concept lattice to some extent. Uta Priss [
        <xref ref-type="bibr" rid="ref22 ref23">22,23</xref>
        ] used this
observation to establish some facts about median semilattices from a Formal
Concept Analysis [
        <xref ref-type="bibr" rid="ref15">15</xref>
        ] perspective, and sketched an algorithm to compute median
semilattices from concept lattices.
      </p>
      <p>
        In [
        <xref ref-type="bibr" rid="ref16">16</xref>
        ], we tried to formalize these ideas and to implement this algorithm.
In our approach, we set an assumption on the family of ∨-irreducible elements,
exhibiting an invariant between the initial lattice and the lattice produced by
the algorithm i.e., the poset of ∨-irreducible elements of the two lattices are
isomorphic. We showed that the proposed algorithm produces a distributive
∨semilattice but not necessarily a minimal one. In fact, we observed in [
        <xref ref-type="bibr" rid="ref17">17</xref>
        ] that
such a minimum may not exist. Moreover, our algorithm does not take into
account the condition:
if x ∧ y, y ∧ z, x ∧ z exist, then x ∧ y ∧ z also exists,
(TRI)
which ensures that the semilattice is a median semilattice. In this paper we
revisit our algorithm, taking into account the condition (TRI), and we show
that it effectively and (to some extent) efficiently computes median semilattices
from any formal context. Moreover, it does so in polynomial time.
      </p>
      <p>The paper is organized as follows. After recalling some basic notions,
preliminary and results (Section 2), we show in Section 3 that if the condition
(TRI) is not satisfied in an input concept lattice L, then there is only one
distributive ∨-semilattice with the same poset of ∨-irreducible elements as L. We
discuss in Section 4 about possible hypotheses other than the isomorphism of
a ∨-irreducible poset to embed a concept lattice (minus bottom element) in a
median semilattice.
2</p>
    </sec>
    <sec id="sec-2">
      <title>From Lattices to Median Graphs</title>
      <p>
        In this section we recall basic notions and notations needed throughout the
paper. We will mainly adopt the formalism of [
        <xref ref-type="bibr" rid="ref15">15</xref>
        ], and we refer the reader to
[
        <xref ref-type="bibr" rid="ref12 ref14">12,14</xref>
        ] for related notions. All sets considered in this paper are assumed to be
finite.
2.1
      </p>
      <sec id="sec-2-1">
        <title>Posets, lattices and semilattices</title>
        <p>Throughout the paper (P, ≤) denotes a partially ordered set (or poset, for short)
with the (partial) order ≤, (L, ∨, ∧) denotes a lattice, S∨ = (S, ∨) denotes a
∨semilattice, and S∧ = (S, ∧) denotes a ∧-semilattice. As usual, ∨ is referred to
as the supremum or join, whereas ∧ is referred to as the infimum or meet. When
clear from the context, we will use P , L and S to respectively denote a poset, a
lattice and a semilattice.</p>
        <p>
          Note that every lattice is a semilattice, and that every semilattice S∨
(similarly, S∧) is a poset with the partial order defined by x ≤ y if y = x ∨ y
(x = x ∧ y, respectively). Also, every (finite) poset and every lattice can be
visualized thanks to their Hasse diagrams [
          <xref ref-type="bibr" rid="ref14">14</xref>
          ] that represent the covering relations
between elements.
        </p>
        <p>Let (X1, R1) and (X2, R2) be two relational structures (e.g., posets,
semilattices or lattices). A mapping f : X1 → X2 is said to be a homomorphism
between (X1, R1) and (X2, R2) if for every x, y ∈ X1, xR1y ⇐⇒ f (x)R2f (y).
If f is an injective homomorphism, then it is said to be an embedding, and if
the inverse f −1 exists and both f and f −1 are embeddings, then f is said to be
an isomorphism. More specifically,
– if R1 = ” ≤ ”, then f is said to be an order-homomorphism (resp., order
embedding, order isomorphism);
– if R1 is the graph of ∧ (dually of ∨), then f is said to be a ∧-homomorphism
(resp., ∧-embedding, ∧-isomorphism);
Moreover, f is a lattice homomorphism if it is both a ∧-homomorphism and a
∨homomorphism. The notions of lattice embedding and lattice homomorphism are
defined similarly. A poset P1 is said to be a subposet of a poset P2 if there exists
an order embedding from P1 into P2. Similarly, a (semi)lattice L1 is said to be
a sub(semi)lattice of a (semi)lattice L2 if there exists a (semi)lattice embedding
from L1 into L2. Note that if L1 is a sub(semi)lattice of L2, then it is also a
subposet. However the converse is not necessarily true.</p>
        <p>An element x ∈ L such that x = y ∨ z implies x = y or x = z is called
∨irreducible. Dually, an element x ∈ L such that x = y ∧ z implies x = y or x = z
is called ∧-irreducible. We will denote the set of ∧-irreducible and ∨-irreducible
elements of L by M(L) and J (L), respectively. Observe that both M(L) and
J (L) are posets when ordered by ≤L. In this case (M(L), ≤L) stands for the
poset and ≤L is understood as the restriction of ≤L, the order relation on the
lattice L, to elements in M(L) (resp. for (J (L), ≤L)).</p>
        <p>We say that two lattices L1 and L2 are invariant wrt ∧-irreducible
elements (resp. ∨-irreducible elements) iff there exists an order-isomorphism f
between (M(L1), ≤L1 ) and (M(L2), ≤L2 ) (resp. (J (L1), ≤L1 ) and (J (L2), ≤L2 )).
Clearly, L1 and L2 are invariant wrt ∧-irreducible and ∨-irreducible elements iff
there exists a lattice isomorphism f : L1 → L2.</p>
        <p>
          The family of lattices invariant wrt ∨-irreducible elements was studied by
Bordalo and Monjardet in [
          <xref ref-type="bibr" rid="ref9">9</xref>
          ]. The family of lattices that order-embed a given
poset was studied by Nation and Pogel in [
          <xref ref-type="bibr" rid="ref21">21</xref>
          ]. Notice that these two families
are themselves lattices when ordered by inclusion.
2.2
        </p>
      </sec>
      <sec id="sec-2-2">
        <title>Formal concept analysis</title>
        <p>
          Formal Concept Analysis [
          <xref ref-type="bibr" rid="ref15">15</xref>
          ] is a mathematical formalism based on lattice
theory and aimed at data analysis and classification tasks. Concept lattices are built
from a binary table called a formal context via a Galois connection.
        </p>
        <p>A formal context is a triple (G, M, I), where G is a set of objects, M is a
set of attributes and I is an incidence relation between objects and attributes.
For instance, in phylogenetic data, objects are usually species, attributes are
mutations, and I is a binary relation where (g, m) ∈ I (or in infix notation gIm)
states that the mutation m is spotted in specie g.</p>
        <p>Every formal context (G, M, I) induces a Galois connection between objects
and attributes: for X ⊆ G and Y ⊆ M , defined by:</p>
        <p>X0 = {y ∈ M | xIy for all x ∈ X},</p>
        <p>Y 0 = {x ∈ G | xIy for all y ∈ Y }.</p>
        <p>A formal concept is then a pair (X, Y ) such that X0 = Y and Y 0 = X, called
respectively the intent and the extent of the formal concept (X, Y ). It should be
noticed that both X and Y are closed sets, i.e., X = X00 and Y = Y 00. The set of
all formal concepts can be ordered by inclusion of the extents or, dually, by the
reversed inclusion of the intents. The resulting order, denoted by ≤, gives rise to
the concept lattice of the context (G, M, I). The existence of a supremum and
an infimum enables the use of lattices for classification purposes. Concepts can
be viewed as classes, indeed a concept (X, Y ) is a representation of a maximal
set X of objects that share a maximal set Y of attributes. If another concept
(X1, Y1) is greater than (X, Y ), it contains more objects but it is described by
less attributes.</p>
        <p>
          A clarified context is a context such that for any x, y ∈ G, if x0 = y0, then
x = y and for any a, b ∈ M , if a0 = b0, then a = b. In other words, the sets of
attributes (resp. objects) of two distinct objects (resp. attributes) are distinct.
Moreover, a clarified context is reduced iff it does not contain:
– x ∈ G such that x0 = X0 with X ⊆ G, x 6∈ X
– y ∈ M such that y0 = Y 0 with Y ⊆ M , y 6∈ Y
The reduced context is also called a standard context [
          <xref ref-type="bibr" rid="ref15">15</xref>
          ]. Note that the standard
context of lattice L verifies G = J (L) and M = M(L).
2.3
        </p>
      </sec>
      <sec id="sec-2-3">
        <title>Distributive lattices</title>
        <p>Formally, a lattice L is distributive if for every x, y, z ∈ L, one (or, equivalently,
both) of the following identities holds:
(i) x ∨ (y ∧ z) = (x ∨ y) ∧ (x ∨ z),
(ii) x ∧ (y ∨ z) = (x ∧ y) ∨ (x ∧ z).</p>
        <p>
          Distributive lattices naturally appear in any classification task and as
computation and semantic models; see, e.g., [
          <xref ref-type="bibr" rid="ref12 ref14 ref18 ref20">12,14,18,20</xref>
          ]. This is partially due to the
fact that every distributive lattice can be thought of as a sublattice of a power-set
lattice, i.e., the set P(X) of all subsets of a given set X. It should be noticed
that each sublattice of a distributive lattice is also distributive, and thus
distributivity can be characterized in terms of forbidden sublattices. In particular,
a lattice is distributive iff it contains neither N5 ((⊥, &gt; and a, b, c with b &lt; c))
nor M3 (3 non-comparable elements, ⊥ and &gt;), the two smallest non distributive
lattices, as sublattices.
        </p>
        <p>
          A main result about distributive lattices is the representation theorem of
Birkhoff [
          <xref ref-type="bibr" rid="ref7">7</xref>
          ] which makes use of the notion of order ideals. Let (P, ≤) be a poset.
For X ⊆ P , let ↓ X = {y ∈ P : y ≤ x for some x ∈ X} and ↑ X = {y ∈ P : x ≤
y for some x ∈ X}.
        </p>
        <p>A set X ⊆ P is a (poset ) ideal (resp. filter ) if X =↓ X (resp. X =↑ X). If
X =↓ {x} (resp. X =↑ {x}) for some x ∈ P , then X is said to be a principal
ideal (resp. filter) of P . For principal ideals, we omit brackets, so that ↑ x (resp.
↓ x) stands for ↑ {x} (resp. ↓ {x}).</p>
      </sec>
      <sec id="sec-2-4">
        <title>Birkhoff ’s representation theorem of distributive lattices.</title>
        <p>Let (P, ≤) be a poset and consider the set O(P ) of ideals of P , i.e.,
O(P ) = { [ ↓ x | X ⊆ P }.</p>
        <p>
          x∈X
It is well known that for every poset P , the set O(P ) ordered by inclusion is a
distributive lattice, called the ideal lattice of P [
          <xref ref-type="bibr" rid="ref7">7</xref>
          ]. Furthermore, the poset of
∨-irreducible elements of O(P ) is J (O(P )) = {↓ x | x ∈ P } which is
orderisomorphic to P .
        </p>
        <p>
          This representation is used to provide a distributive lattice Ld with the same
poset of ∨-irreducible elements as a given lattice L [
          <xref ref-type="bibr" rid="ref7">7</xref>
          ]. In this case, there is a
∧-embedding from L into Ld. Every lattice invariant wrt ∨-irreducible poset can
be ∧-embedded in the ideal lattice of its ∨-irreducible poset.
        </p>
        <p>
          From a poset P , it is possible to obtain the context of the ideal lattice as
(P, P, 6≥) [
          <xref ref-type="bibr" rid="ref15">15</xref>
          ]. For a standard context C = (J (L), M(L), ≤), the standard
context of the ideal lattice is (J (L), J (L), 6≥). Also, for every distributive lattice
L, the poset (J (L), ≤L) is isomorphic to the poset (M(L), ≥L) (dual poset of
(M(L), ≤L)). This is why standard contexts of distributive lattices are “squares”
(|J (L)| = |M(L)|), and can be built with the information of only one of these
two posets.
        </p>
        <p>
          Let S∨ be a ∨-semilattice and let x ∈ S∨. Then ↑ x is a lattice (in the finite
case, every ∨-semilattice with ⊥ is a lattice). A semilattice S∨ is said to be
distributive if ↑ x is distributive, for all x ∈ S∨ [
          <xref ref-type="bibr" rid="ref12">12</xref>
          ]. It should be noticed that
it is sufficient to check this property for the minimal elements of S∨. It follows
directly from the fact that a sublattice of a distributive lattice is a distributive
lattice, and if x ≤ y in S∨, then ↑ y is a (distributive) sublattice of ↑ x.
2.5
        </p>
      </sec>
      <sec id="sec-2-5">
        <title>Median algebras, median semilattices and median graphs</title>
        <p>
          As indicated in the introduction, median algebras can encode all parsimonious
(with no unnecessary mutations) phylogenetic trees in case of evolution
ambiguities. Formally, a median algebra is a structure A = (A, m) for a nonempty set A
and a ternary symmetric operation m : A3 → A such that for every x, y, z, t, u ∈
A, m(x, x, y) = x and m(m(x, y, z), t, u) = m(x, m(y, t, u), m(z, t, u)). Such
algebras have been studied by several authors and they were shown to be tightly
related to several ordered structures such as semilattices and distributive lattices,
and to an important class of graphs, the so-called “median graphs” [
          <xref ref-type="bibr" rid="ref19 ref8">8,19</xref>
          ].
        </p>
        <p>
          Sholander [
          <xref ref-type="bibr" rid="ref24">24</xref>
          ] showed that each element a of a median algebra A gives rise
to a median semilattice (A, ∨a) where x ∨a y = m(a, x, y). From this definition
it follows that their principal filters
        </p>
        <p>↑ x := {y ∈ A : y ∨a x = y}
are indeed distributive lattices. Conversely, if a ∨-semilattice S∨ has the property
that for every a, b, c ∈ S∨, a ∧ b ∧ c exists whenever a ∧ b, b ∧ c, c ∧ a exist, then
S∨ is a median semilattice.</p>
        <p>The following characterization of distributive lattices emphasizes the link
between distributive lattices and median algebras.</p>
        <p>Property 1. A lattice L is a distributive lattice iff for all x, y, z ∈ L,
(x ∧ y) ∨ (y ∧ z) ∨ (z ∧ x) = (x ∨ y) ∧ (y ∨ z) ∧ (z ∨ x).
(1)
Accordingly, we can define a median operation on L by m(x, y, z) = (x ∨ y) ∧
(y ∨ z) ∧ (z ∨ x), for every x, y, z ∈ L.</p>
        <p>
          In the case of discrete structures, median algebras can also be considered as a
special kind of graphs. A median graph is a connected graph (i.e., for every pair
of vertices there is a path connecting them) verifying that for any three vertices
a, b, c, there is exactly one vertex x that minimizes the sum of the distances to a, b
and c. It was shown in [
          <xref ref-type="bibr" rid="ref2">2</xref>
          ] that every median semilattice whose intervals are finite
has a covering graph (i.e., undirected Hasse diagram) that is median, and that
every median graph is the covering graph of a median semilattice. For further
details on the connections between median graphs and median semilattice, see
[
          <xref ref-type="bibr" rid="ref13 ref3">3,13</xref>
          ].
        </p>
        <p>
          Summing up, we have the following characterization [
          <xref ref-type="bibr" rid="ref4">4</xref>
          ].
        </p>
        <p>Property 2. A graph G is a median graph iff it is the covering graph of a
∨semilattice S∨ with the following properties:
1. S∨ is distributive, and
2. (TRI) for every x, y, z ∈ S∨ such that x ∧ y, y ∧ z and z ∧ x are defined,
x ∧ y ∧ z is also defined.
2.6</p>
      </sec>
      <sec id="sec-2-6">
        <title>Previous Results</title>
        <p>
          In [
          <xref ref-type="bibr" rid="ref16">16</xref>
          ], we presented an algorithm that takes the reduced context of a lattice
L as input, and outputs in polynomial time the context of a lattice Ld such
that SL = {Ld\⊥} is a distributive ∨-semilattice with the same poset of
∨irreducible elements. This context is obtained by “local” applications of Birkhoff’s
representation theorem on every subcontext corresponding to a sublattice defined
by a filter of atoms (minimal ∨-irreducible elements). Due to the fact that some
elements of the context may appear in several filters, multiple applications may
be necessary until a fix-point is reached. This fix-point is subsumed by the ideal
lattice of the poset of ∨-irreducible elements derived from the context.
        </p>
        <p>
          In some cases, our algorithm outputs a solution smaller than this ideal lattice.
This is indeed the case for M3 or N5, for which the algorithm outputs a non
modified context. Indeed, M3\⊥ is a tree and N5\⊥ is a path, and both are
median graphs. Nevertheless, our algorithm does not guarantee the minimality of
the solution. In fact, we have shown in [
          <xref ref-type="bibr" rid="ref17">17</xref>
          ] that several minimal non isomorphic
solutions may exist.
        </p>
        <p>
          Also, being able to build a distributive ∨-semilattice is a necessary condition
to build a median graph, but it is not sufficient. In [
          <xref ref-type="bibr" rid="ref16 ref17">16,17</xref>
          ] the second condition
of Property 2 was not considered. Here, we take it into account and provide an
improved algorithm that always outputs a median graph for any input lattice.
        </p>
      </sec>
    </sec>
    <sec id="sec-3">
      <title>Main results</title>
      <p>In this section we show, in particular, that if L is a lattice containing a triple
x, y, z such that x ∧ y, x ∧ z, y ∧ z &gt; ⊥ and x ∧ y ∧ z = ⊥ then the only median
semilattice invariant for the poset of ∨-irreducible elements is a lattice, and it is
the ideal lattice of the poset of ∨-irreducible elements of L.</p>
      <p>Proposition 1. Let L be a lattice and suppose that there exist x, y, z ∈ L with
x ∧ y, x ∧ z, y ∧ z &gt; ⊥ and x ∧ y ∧ z = ⊥. Let denote SL = {Ld\⊥}, with Ld
a distributive ∨-semilattice with the same poset of ∨-irreducible elements as L.
Then the semilattice SL does not satisfy the second condition of Property 2.
Proof. By construction (applications of Birkhoff’s representation theorem), Ld
is a lattice such that there is an ∧-embedding f : L → Ld i.e., x ∧ y = z ⇒
f (x) ∧ f (y) = f (z). Hence, if there are x, y, z ∈ L such that x ∧ y, x ∧ z, y ∧ z &gt;
⊥ and x ∧ y ∧ z = ⊥, then f (x) ∧ f (y), f (x) ∧ f (z), f (y) ∧ f (z) exist, but
f (x) ∧ f (y) ∧ f (z) = ⊥ 6∈ SL. tu
As an immediate consequence, we obtain the following corollary.
Corollary 1. If L is a lattice for which there exist x, y, z ∈ L with x ∧ y, x ∧
z, y ∧ z &gt; ⊥ and x ∧ y ∧ z = ⊥, then there is exactly one median semilattice
SL such that (J (L), ≤L) is isomorphic to (J (SL), ≤SL ). This semilattice is the
ideal lattice of (J (L), ≤L).</p>
      <p>Proof. To be a median semilattice, a new element a = x ∧ y ∧ z must be added
to the semilattice SL. There are two possibilities:
– (i.) a = ⊥ and in this case SL is a lattice. For being a median semilattice, it
must be a distributive lattice, and thus the ideal lattice of (J (L), ≤), or
– (ii.) a 6= ⊥ and in this case a is a new atom of SL, and thus a new
∨irreducible element. It is not difficult to check that there is no isomorphism
between (J (L), ≤) and (J (Ld), ≤) tu
If one requires invariance of the poset of ∨-irreducible elements, then the
following lemma provides an algorithm that decides in polynomial time whether the
second condition is satisfied. In other words, whether it must output the ideal
lattice of ∨-irreducible elements or a distributive ∨-semilattice.</p>
      <p>Lemma 1. Let L be a lattice. There exist x, y, z ∈ L such that x, y, z ∈ L with
x ∧ y, x ∧ z, y ∧ z &gt; ⊥ and x ∧ y ∧ z = ⊥ iff there exist ax, ay, az ∈ Atoms(L)
and mx, my, mz ∈ M(L) such that
– ax 6≤ mx, ax ≤ my, ax ≤ mz,
– ay 6≤ my, ay ≤ mx, ay ≤ mz,
– az 6≤ mz, az ≤ mx, az ≤ my.</p>
      <p>Proof. Suppose that there exist x, y, z ∈ L such that x ∧ y, x ∧ z, y ∧ z &gt; ⊥ and
x ∧ y ∧ z = ⊥. Then there exist 3 atoms ax, ay, az such that</p>
      <p>– az ≤ x ∧ y, az 6≤ z (otherwise x ∧ y ∧ z ≥ az &gt; ⊥),
– ay ≤ x ∧ z, ay 6≤ y (otherwise x ∧ y ∧ z ≥ ay &gt; ⊥), and
– ax ≤ y ∧ z, ax 6≤ x (otherwise x ∧ y ∧ z ≥ ax &gt; ⊥).</p>
      <p>Take mi ∈ M ax(M(L)\ ↑ ai) for i ∈ {x, y, z}. Then,
mx is greater than ay and az and not greater than ax,
my is greater than ax and az and not greater than ay, and
mz is greater than ax and ay and not greater than az,
showing that the conditions are necessary.</p>
      <p>To show that the conditions are also sufficient, suppose that there are a1, a2, a3 ∈
Atoms(L) and m1, m2, m3 ∈ M(L) such that
– a1 6≤ m1, a1 ≤ m2, a1 ≤ m3
– a2 6≤ m2, a2 ≤ m1, a2 ≤ m3
– a3 6≤ m3, a3 ≤ m1, a3 ≤ m1</p>
      <p>Let x = a2 ∨ a3, y = a1 ∨ a3, z = a1 ∨ a2. It should be noticed that there
cannot be any comparable pair from {x, y, z} as it would contradict the existence
of m1, m2, m3 ∈ M(L) satisfying the displayed conditions. Hence, x, y and z are
pairwise incomparable w.r.t. ≤. Moreover, x ∧ y &gt; ⊥, x ∧ z &gt; ⊥, y ∧ z &gt; ⊥ and
x ∧ y ∧ z = ⊥. This completes the proof of the lemma. tu</p>
      <p>
        This lemma ensures that it is possible to check whether the second condition
is satisfied in polynomial time from the reduced context of the lattice. Note that
it is a variation (on atoms, i.e., minimal ∨-irreducible elements) of a result on
totally balanced matrices (see for example [
        <xref ref-type="bibr" rid="ref1 ref11">1,11</xref>
        ])
      </p>
      <p>Based on Lemma 1, we can modify our algorithm to Algorithm 1, which now
returns a context and a Boolean. If the Boolean is true, then it is possible to
consider the semilattice obtained by the deletion of ⊥. If the Boolean is false,
then the output context is the one associated with the ideal lattice of (J (L), ≤)
that, together with ⊥, constitutes a median semilattice (which is, in this case, a
lattice).</p>
      <p>Algorithm 1: Construction of context of a median (∨-semi) lattice.</p>
      <p>Data: A context (J (L), M(L), I) of a lattice L
Result: a context (J (Lmed), M(Lmed), I) and a boolean tri
tri ← check_T RI_condition((J (L), M(L), I))
if tri == f alse then</p>
      <p>return C(J (L), J (L), 6≥), f alse
foreach j ∈ J (L), minimal do</p>
      <p>(Pj, ≤) ← ∅
repeat
stability ← true;
foreach j ∈ J (L), minimal do
compute Pj the poset of ∨-irreducible elements in ↑ j
compute Cj = (Pj, Pj, 6≥)
if Pj modified since last iteration then</p>
      <p>stability ← false;
Merge all Cj = (Pj, Pj, 6≥) in a unique context</p>
      <p>Reduce this context
until stability
4</p>
    </sec>
    <sec id="sec-4">
      <title>Final remarks and open problems</title>
      <p>
        In previous works ([
        <xref ref-type="bibr" rid="ref16 ref17">16,17</xref>
        ]), we investigated how to obtain a median semilattice
SL from a concept lattice L with the following properties:
1. L\⊥ can be order-embedded in SL,
2. there is an isomorphism between (J (L), ≤) and (J (SL ∪ {⊥}), ≤), and
3. |SL\L| is minimal.
      </p>
      <p>
        Our algorithm, based on local applications of Birkhoff’s representation
theorem, verifies the first two properties, but may fail to satisfy the third (we have
shown in [
        <xref ref-type="bibr" rid="ref17">17</xref>
        ] that there can exist several minimal solutions).
      </p>
      <p>The first property seems to be natural in applications. In phylogeny
problems, we want to be able to add latent vertices, representing the species not yet
observed, but we do not want to change the relative order of the observed species.
The second property is an extension of the first one. In a context, all elements
can be inferred from irreducible ones. Thus, we decided to keep as invariant the
poset of ∨-irreducible elements, so that the ’skeleton’ of data does not change.
The third property is motivated by the parsimony principle: a solution with less
additional information (concepts) is preferred.</p>
      <p>Fig. 3 proposes two embeddings for the lattice M3. The first one (Fig. 3.b)
is based on a product of two chains of length 3. The second one (Fig. 3.c) is
based on the ideal lattice of J (M3), which is here a Boolean lattice. In this
example, there are more concepts in the product of chains than in the Boolean
lattice (9 versus 8). Nevertheless, in a similar way, we can embed Mx, a lattice
composed by an antichain of x elements, &gt; and ⊥ elements into a Boolean lattice
of dimension x, as well as a product of two chains of length x − 1. The product
of two chains for length x − 1 is a distributive lattice with (x − 1)2 concepts.
The Boolean lattice of dimension x has 2x concepts. If x &gt; 4, there are less
concepts in the product of two chains of length x − 1 than in the Boolean lattice
of dimension x. Nevertheless, the number of irreducible elements is greater in
the product of chains than in the Boolean lattice (and so, the reduced context of
the first has more elements than the context of the last). Without the hypothesis
of the invariance of ∨-irreducible posets, if follows that there may exist order
embeddings with less elements. Then some questions are remaining open:
1. What is the relevance of isomorphism between ∨-irreducible elements for
real-world problems?
2. What is the parameter to minimize: the number of new concepts in the
lattice or the number of elements in the reduced context?
3. How to compute a minimal median semilattice from a concept lattice?</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          1.
          <string-name>
            <surname>Anstee</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Farber</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          :
          <article-title>Characterizations of totally balanced matrices</article-title>
          .
          <source>Journal of Algorithms</source>
          <volume>5</volume>
          (
          <issue>2</issue>
          ),
          <fpage>215</fpage>
          -
          <lpage>230</lpage>
          (
          <year>1984</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          2.
          <string-name>
            <surname>Avann</surname>
            ,
            <given-names>S.P.</given-names>
          </string-name>
          :
          <article-title>Metric ternary distributive semi-lattices</article-title>
          .
          <source>Proceedings of the American Mathematical Society</source>
          <volume>12</volume>
          ,
          <fpage>407</fpage>
          -
          <lpage>414</lpage>
          (
          <year>1961</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          3.
          <string-name>
            <surname>Bandelt</surname>
            ,
            <given-names>H.J.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Hedlíková</surname>
          </string-name>
          , J.:
          <article-title>Median algebras</article-title>
          .
          <source>Discrete mathematics 45(1)</source>
          ,
          <fpage>1</fpage>
          -
          <lpage>30</lpage>
          (
          <year>1983</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          4.
          <string-name>
            <surname>Bandelt</surname>
            ,
            <given-names>H.J.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Forster</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Röhl</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>Median-joining networks for inferring intraspecific phylogenies</article-title>
          .
          <source>Molecular biology and evolution 16</source>
          (
          <issue>1</issue>
          ),
          <fpage>37</fpage>
          -
          <lpage>48</lpage>
          (
          <year>1999</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          5.
          <string-name>
            <surname>Bandelt</surname>
            ,
            <given-names>H.J.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Macaulay</surname>
            ,
            <given-names>V.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Richards</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          :
          <article-title>Median networks: speedy construction and greedy reduction, one simulation, and two case studies from human mtdna</article-title>
          .
          <source>Molecular phylogenetics and evolution 16(1)</source>
          ,
          <fpage>8</fpage>
          -
          <lpage>28</lpage>
          (
          <year>2000</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          6.
          <string-name>
            <surname>Barthélemy</surname>
            ,
            <given-names>J.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Guénoche</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>Trees and proximity representations</article-title>
          .
          <source>WileyInterscience series in discrete mathematics and optimization</source>
          , Wiley (
          <year>1991</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          7.
          <string-name>
            <surname>Birkhoff</surname>
            ,
            <given-names>G.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Frink</surname>
            ,
            <given-names>O.</given-names>
          </string-name>
          :
          <article-title>Representations of lattices by sets</article-title>
          .
          <source>Transactions of the American Mathematical Society</source>
          <volume>64</volume>
          (
          <issue>2</issue>
          ),
          <fpage>299</fpage>
          -
          <lpage>316</lpage>
          (
          <year>1948</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          8.
          <string-name>
            <surname>Birkhoff</surname>
            ,
            <given-names>G.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Kiss</surname>
            ,
            <given-names>S.A.</given-names>
          </string-name>
          :
          <article-title>A ternary operation in distributive lattices</article-title>
          .
          <source>Journal of Symbolic Logic</source>
          <volume>13</volume>
          (
          <issue>1</issue>
          ),
          <fpage>50</fpage>
          -
          <lpage>51</lpage>
          (
          <year>1948</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          9.
          <string-name>
            <surname>Bordalo</surname>
            ,
            <given-names>G.H.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Monjardet</surname>
            ,
            <given-names>B.</given-names>
          </string-name>
          :
          <article-title>The lattice of strict completions of a poset</article-title>
          .
          <source>Electronic Notes in Discrete Mathematics</source>
          <volume>5</volume>
          ,
          <fpage>38</fpage>
          -
          <lpage>41</lpage>
          (
          <year>2000</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref10">
        <mixed-citation>
          10.
          <string-name>
            <surname>Breiman</surname>
            ,
            <given-names>L.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Friedman</surname>
            ,
            <given-names>J.H.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Olshen</surname>
            ,
            <given-names>R.A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Stone</surname>
            ,
            <given-names>C.J.</given-names>
          </string-name>
          : Classification and
          <string-name>
            <given-names>Regression</given-names>
            <surname>Trees</surname>
          </string-name>
          .
          <source>Wadsworth and Brooks</source>
          , Monterey, CA (
          <year>1984</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref11">
        <mixed-citation>
          11.
          <string-name>
            <surname>Brucker</surname>
            ,
            <given-names>F.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Préa</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          :
          <article-title>Totally balanced formal context representation</article-title>
          .
          <source>In: International Conference on Formal Concept Analysis</source>
          . pp.
          <fpage>169</fpage>
          -
          <lpage>182</lpage>
          . Springer (
          <year>2015</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref12">
        <mixed-citation>
          12.
          <string-name>
            <surname>Caspard</surname>
            ,
            <given-names>N.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Leclerc</surname>
            ,
            <given-names>B.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Monjardet</surname>
            ,
            <given-names>B.</given-names>
          </string-name>
          :
          <article-title>Finite ordered sets: concepts, results and uses</article-title>
          . Cambridge University Press (
          <year>2012</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref13">
        <mixed-citation>
          13.
          <string-name>
            <surname>Couceiro</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Foldes</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Meletiou</surname>
          </string-name>
          , G.:
          <article-title>On homomorphisms between products of median algebras</article-title>
          .
          <source>Algebra Universalis</source>
          <volume>78</volume>
          (
          <issue>4</issue>
          ),
          <fpage>545</fpage>
          -
          <lpage>553</lpage>
          (
          <year>2017</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref14">
        <mixed-citation>
          14.
          <string-name>
            <surname>Davey</surname>
            ,
            <given-names>B.A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Priestley</surname>
            ,
            <given-names>H.A.</given-names>
          </string-name>
          :
          <article-title>Introduction to Lattices and Order</article-title>
          . Cambridge university press (
          <year>2002</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref15">
        <mixed-citation>
          15.
          <string-name>
            <surname>Ganter</surname>
            ,
            <given-names>B.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Wille</surname>
          </string-name>
          , R.:
          <source>Formal Concept Analysis: Mathematical Foundations</source>
          . Springer (
          <year>1999</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref16">
        <mixed-citation>
          16.
          <string-name>
            <surname>Gély</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Couceiro</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Napoli</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>Steps towards achieving distributivity in formal concept analysis</article-title>
          .
          <source>In: Proceedings of the Fourteenth International Conference on Concept Lattices and Their Applications</source>
          ,
          <source>CLA</source>
          <year>2018</year>
          , Olomouc, Czech Republic, June 12-14,
          <year>2018</year>
          . pp.
          <fpage>105</fpage>
          -
          <lpage>116</lpage>
          (
          <year>2018</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref17">
        <mixed-citation>
          17.
          <string-name>
            <surname>Gély</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Couceiro</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Napoli</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>Embedding median graphs into minimal distributive join-semi-lattices</article-title>
          . In: New Frontiers in Mining Complex Patterns, eighth edition of the International Workshop NFMCP (Wùzburg, Germany) (
          <year>2019</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref18">
        <mixed-citation>
          18.
          <string-name>
            <surname>Hopcroft</surname>
            ,
            <given-names>J.E.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Motwani</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          , Rotwani, Ullman,
          <string-name>
            <surname>J.D.</surname>
          </string-name>
          :
          <article-title>Introduction to Automata Theory, Languages and Computability</article-title>
          .
          <string-name>
            <surname>Addison-Wesley Longman</surname>
          </string-name>
          Publishing Co., Inc., Boston, MA, USA, 2nd edn. (
          <year>2000</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref19">
        <mixed-citation>
          19.
          <string-name>
            <surname>Isbell</surname>
            ,
            <given-names>J.R.</given-names>
          </string-name>
          :
          <source>Median algebra. Transactions of the American Mathematical Society</source>
          <volume>260</volume>
          (
          <issue>2</issue>
          ),
          <fpage>319</fpage>
          -
          <lpage>362</lpage>
          (
          <year>1980</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref20">
        <mixed-citation>
          20.
          <string-name>
            <surname>Mattern</surname>
            ,
            <given-names>F.</given-names>
          </string-name>
          :
          <article-title>Virtual time and global states of distributed systems</article-title>
          .
          <source>Parallel and Distributed Algorithms</source>
          <volume>1</volume>
          (
          <issue>23</issue>
          ),
          <fpage>215</fpage>
          -
          <lpage>226</lpage>
          (
          <year>1989</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref21">
        <mixed-citation>
          21.
          <string-name>
            <surname>Nation</surname>
            ,
            <given-names>J.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Pogel</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>The lattice of completions of an ordered set</article-title>
          .
          <source>Order</source>
          <volume>14</volume>
          (
          <issue>1</issue>
          ),
          <fpage>1</fpage>
          -
          <lpage>7</lpage>
          (
          <year>1997</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref22">
        <mixed-citation>
          22.
          <string-name>
            <surname>Priss</surname>
            ,
            <given-names>U.</given-names>
          </string-name>
          :
          <article-title>Concept lattices and median networks</article-title>
          .
          <source>In: Proceedings of the Ninth International Conference on Concept Lattices and Their Applications</source>
          , Universidad de Malaga. pp.
          <fpage>351</fpage>
          -
          <lpage>354</lpage>
          (
          <year>2012</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref23">
        <mixed-citation>
          23.
          <string-name>
            <surname>Priss</surname>
            ,
            <given-names>U.</given-names>
          </string-name>
          :
          <article-title>Representing median networks with concept lattices</article-title>
          .
          <source>In: Proceedings of the 20th International Conference on Conceptual Structures</source>
          . pp.
          <fpage>311</fpage>
          -
          <lpage>321</lpage>
          . Springer (
          <year>2013</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref24">
        <mixed-citation>
          24.
          <string-name>
            <surname>Sholander</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          :
          <article-title>Trees, lattices, order, and betweenness</article-title>
          .
          <source>Proceedings of the American Mathematical Society</source>
          <volume>3</volume>
          (
          <issue>3</issue>
          ),
          <fpage>369</fpage>
          -
          <lpage>381</lpage>
          (
          <year>1952</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref25">
        <mixed-citation>
          25.
          <string-name>
            <surname>Vigilant</surname>
            ,
            <given-names>L.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Pennington</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Harpending</surname>
            ,
            <given-names>H.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Kocher</surname>
            ,
            <given-names>T.D.</given-names>
          </string-name>
          , Wilson,
          <string-name>
            <surname>A.C.</surname>
          </string-name>
          :
          <article-title>Mitochondrial dna sequences in single hairs from a southern african population</article-title>
          .
          <source>Proceedings of the National Academy of Sciences</source>
          <volume>86</volume>
          (
          <issue>23</issue>
          ),
          <fpage>9350</fpage>
          -
          <lpage>9354</lpage>
          (
          <year>1989</year>
          )
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>