Navigation
  • Home
  • Fuzzy Logic Programs
  • Multi-Adjoint Lattices
  • Syntax
  • Procedural Semantics
  • Prolog Code Generation
  • How to Use FLOPER
    • Starting
    • Managing Projects
    • Loaging Fuzzy Programs
    • Using Lattices
    • Executing Scripts
    • Running Programs
    • Execution Tree
    • Declarative Traces
  • Bibliography
  • Downloads
Interesting Links
  • fuzzyXPath Project
  • FLUS Tool
  • DEC-Tau
  • Similarities in FLOPER
Home

A brief introduction to Multi-Adjoint Logic Programming

Logic Programming [1] has been widely used for problem solving and knowledge representation in the past. Nevertheless, traditional LP languages do not incorporate techniques or constructs to treat explicitly with uncertainty and approximated reasoning. To overcome this situation, during the last decades several fuzzy logic programming systems have been developed where the classical inference mechanism of SLD-Resolution has been replaced with a fuzzy variant able to handle partial truth and to reason with uncertainty. Most of these systems implement the fuzzy resolution principle introduced by Lee in [2], such as languages Prolog-Elf [3] and Fril [4].

Following this line, in the original version of [5], a fuzzy logic program is conceived as a set of weighted formulas, where the truth degree of each clause is explicitly annotated. The task of computing and propagating truth degrees relies on an extension of the resolution principle, whereas the (syntactic) unification mechanism remains untouched. Continuing this trail, one of the most modern, flexible and evolved fuzzy dialects of Prolog which follow this scheme, is the one presented in [6]. Informally speaking, in the multi-adjoint logic framework, a program can be seen as a set of rules each one annotated by a truth degree, and a goal is a query to the system, i.e., a set of atoms linked with connectives called aggregators. A state is a pair <Q,s> where Q is a goal and s is a substitution (initially, the identity substitution). States are evaluated in two separate computational phases. During the operational one, admissible steps (a generalization of the classical modus ponens inference rule) are systematically applied by a backward reasoning procedure in a similar way to classical resolution steps in pure logic programming, thus returning a computed substitution together with an expression where all atoms have been exploited. This last expression is then interpreted under a given lattice during what we call the interpretive phase, hence returning a pair <truth_degree; substitution> which is the fuzzy counterpart of the classical notion of computed answer traditionally used in LP.

In what follows, we present a short summary of the main features of our language (we refer the reader to [6] for a complete formulation). We work with a first order language, L, containing variables, function symbols, predicate symbols, constants, quantifiers, ∀ and ∃,and several (arbitrary) connectives to increase language expressiveness. In our fuzzy setting, we use implication connectives ( ←1, ←2, . . . , ←m) and also other connectives which are grouped under the name of aggregators or aggregation operators. They are used to combine/propagate truth values through the rules. The general definition of aggregation operators subsumes conjunctive operators (denoted by &1, &2, . . . , &k ), disjunctive operators ( ∨1,∨2, . . . , ∨j ), and average and hybrid operators (usually denoted by @1, @2, . . . , @n). Although the connectives &i, ∨i and @i are binary operators, we usually generalize them as functions with an arbitrary number of arguments. In the following, we often write @(x1, . . . , xn) instead of @(x1, @(x2, . . . , @(xn-1, xn) . . .)). By definition, the truth function for an n-ary aggregation operator [[@]] : Ln → L is required to be monotone and fulfills [[@]](T,...,T) = T , [[@]]( ⊥,...,⊥ ) = ⊥ . Additionally, our language L contains the values of a multi-adjoint lattice, { L, ≤ , ←1, &1, . . . , ←n, &n } , equipped with a collection of adjoint pairs { ←i, &i } , where each &i is a conjunctor intended to the evaluation of modus ponens. In general, the set of truth values L may be the carrier of any complete bounded lattice but, for simplicity, in this version of the FLOPER system we shall select L as the set of real numbers in the interval [0, 1].

A rule is a formula A ←i B, where A is an atomic formula (usually called the head) and B (which is called the body) is a formula built from atomic formulas (B1, . . . , Bn), truth values of L and conjunctions, disjunctions and aggregations. Rules with an empty body are called facts. A goal is a body submitted as a query to the system. Variables in a rule are assumed to be governed by universal quantifiers. Roughly speaking, a multi-adjoint logic program is a set of pairs <R;a> , where R is a rule and a is a truth degree (a value of L) expressing the confidence which the user of the system has in the truth of the rule R. Often, we will write 'R with a' instead of <R;a> . As an example, consider the following program P (composed by five rules) and ([0, 1], ≤) the lattice where ≤ is the usual order on real numbers.

p(X) <prod q(X,Y) &godel r(Y) with 0.8.
q(a,Y) <prod s(Y) with 0.7.
q(b,Y) <luka r(Y) with 0.8.
r(_) with 0.6.
s(b) with 0.9.

Figure 1: Example of a Fuzzy-prolog program (download)

 

y(peter) with 0.4.
y(mary) with 0.8.
h(peter) with 0.9.
h(mary) with 0.3.
e(peter) with 0.5.
e(mary) with 0.95.
c(X) <prod (h(X) |prod e(X)) &prod y(X) with 1.
Program "Credit" (download)

The labels prod, godel and luka mean for Product logic, Gödel intuitionistic logic and Lukasiewicz logic, respectively. That is, [[&prod]](x, y) = x · y, [[&godel]](x, y) = min(x, y), and [[&luka]](x, y) = max(0, x +y - 1). In [7] we show a simple derivation for the program P and the goal p(X) &godel r(a), obtaining the final fuzzy computed answer <0.48;{X/a}> which tell us that the previous query can be derived from program P with truth degree 0.48 when variable X is a.

Click on the links below in order to obtain a more detailled description of the syntax and procedural semantics of the language:

  • Syntax of multi-adjoint logic programs.
  • Procedural Semantics of multi-adjoint logic programs.

The following links provides MALP programs as examples

  • RULEML'10 example
  • ICAI'10 example
  • IWANN'11 example
  • FM'11 example