Prolog Programming Language

Read Complete Research Material

PROLOG PROGRAMMING LANGUAGE

Prolog Programming Language

Prolog Programming Language

Introduction

Fuzzy Logic Programming integrates fuzzy logic and pure logic programming in order to provide these languages with the ability of dealing with uncertainty and approximate reasoning. There is no common method for this integration, though, most of the works in this field can be grouped in two main streams. See for instance: [9,14,18,2,21,28], for the first line, and [4,5,6,7,25] for the second one. A possible way to go, if we want to grapple with the issue of flexible query answering 4 , is to follow the conceptual approach introduced in [25] where the notion of "approximation" is managed at a syntactic level by means of similarity relations. A similarity relation is an extension of the standard notion of equivalence relation and it can be useful in any context where the concept of equality must be weakened. In [25] a newmodified version of the Linear resolution strategy with Selection function for Definite clauses (SLD resolution) is defined, which is named similarity-based SLD resolution (or weak SLD resolution -WSLD-). This operational mechanism can be seen as a variant of the SLD resolution procedure where the classical unification algorithm has been replaced by the weak unification algorithm formally described in [25] (and reformulated in terms of a transition system in [16]). Informally, Maria Sessa's weak unification algorithm states that two terms f(t1, . . . , tn) and g(s1, . . . , sn) weakly unify if the root symbols f and g are considered similar and each of their arguments ti and si weakly unify. Therefore, the weak unification algorithm does not produce a failure when there is a clash of two syntactical distinct symbols whenever they are similar.

The System

In this paper we present the main features and implementation details of a programming language that we call Bousi~Prolog (BPL for short), with an operational semantics based on the weak SLD resolution principle of [25]. Hence, Bousi~Prolog computes answers as well as approximation degrees. Essentially, the Bousi~Prolog syntax is just the Prolog syntax but enriched with a built-in symbol "~~" used for describing similarity relations by means of similarity equations of the form:

~~ = .

Although, formally, a similarity equation represents an arbitrary fuzzy binary relation, its intuitive reading is that two constants, n-ary function symbols or n-ary predicate symbols are similar with a certain degree. Informally, we use the built-in symbol "~~" as a compressed notation for the symmetric closure of an arbitrary fuzzy binary relation (that is, a similarity equation a ~~ b = a can be understood in both directions: a is similar to b and b is similar to a with degree a). Therefore, a Bousi~Prolog program is a sequence of Prolog facts and rules followed by a sequence of similarity equations.

Results

Simplified rules

In this paper we present the main features and implementation details of a programming language that we call Bousi~Prolog (BPL for short), with an operational semantics based on the weak SLD resolution principle of ...