FUZZY LOGIC AND APPROXIMATE
9.4 Fuzzy Languages
For the formal inference, denote
R(x)=
X,
R(x, y)= E, and R(y)=X
0EApplying the max-min composition for computing
RCy)
=X
0E
yieldsR(y)=max min{l!A (x), l!k(x,y)}
={(l,1), (2, .6), (3, .5), (4, .2)}
A possible interpretation of the inference may be the following:
x is little
x andy are approximately equal y is more or less little
A direct application of approximate reasoning is the fuzzy algorithm (an ordered sequence of instructions in which some of the instructions may contain labels of fuzzy sets) and the fuzzy flow chart. We shall consider both in more detail in chapter 10. Here, however, we shall briefly describe fuzzy (formal) languages.
The latter corresponds essentially to fuzzy logic and approximate reasoning , as described in sections 9.2 and 9.3. The former will be described in more detail after the kind of representation in PRUF has been described and some more def- initions introduced .
In definition8-2,the relational assignment equation was defined. In PRUF, a possibility distribution1txis assigned via the
possiblility assignment equation (PAE):1tx ==
F
to the fuzzy set
F.
The PAE corresponds to a proposition of the form "NisP'
whereNis the name of a variable, a fuzzy set, a proposition, or an object. For simplicity, the PAE will be written as in chapter 8 as
Example 9-9
LetN be the proposition "Peter is old"; thenN (the variable) is called "Peter,"
XE [0, 100] is the linguistic variable "Age," "old" is, for instance, a term of the term set of "Age," and
Peter is old~1t Age( Peter)=old where ~ stands for "translates into."
There are two special types of possibility distributions that will be needed later.
Definition 9-8
The possibility distributions1t[with
1t[(u)=1 for UEU
is called the unity possibility distribution 1t[,and with 1t-t(v)=v for vE[O,I]
is defined the unitary possibility distribution function [Zadeh 1981a, p. 10].
In chapter 6 (definition 6-4), the projection of a binary fuzzy relation was defined. This definition holds not only for binary relations and numerical values of the related variables but also for linguistic variables.
Different fuzzy relations in a product space UI x UsX .•. XU;can have iden- tical projections on Ui, x ...X Uik•Given a fuzzy relation
R
qin Ui; x . . .X Ui"there exists, however, a unique relation
R
qLthat contains all other relations whose projection on Ui,x . . .X Ui,isR
q•R
qLis then called the cylindrical extension ofR
q; the latter is the basis ofR
qL(see definitions 6-4, 6-5).In PRUF, the operation "particularization" is also important: "By the particularization of a fuzzy relation or a possibility distribution which is associated with a variable
X
==(Xt. . . . ,Xn),is meant the effect of specification of the possibility distributions of one or more subvariables (terms) of
X.
Particularization in PRUF J1!ay be viewed !ls the result of forming the conjunction of a proposition of the form "X}sF," wh:,re X is an n-aryvariable withpartic~larizin.$propositions of the form"X,=
G,"where X, is a sub- variable (term) of X andFand G, respectively, are fuzzy sets inVIx V2X •••U;and Vi,X .. . XVi" respectively" [Zadeh 1981a, p. 13].Definition9-9[Zadeh 1981a, p. 13]
Let itx == it(X1 • • •Xn) =
F
and~x==rt..(Xij • • •,_Xi» =f;
be possibility distributions induced by the propositions "X is F' and "X, is G," respectively. The particu- larizationof itx byi;
=G
is denoted byitx(itxs=G)
and is defined as the inter- section ofF
andG,
that is,itAfts =
G)
=Fn G'
where
G'
is the cylindrical extension ofG.
Example9-10
Consider the proposition "Porsche is an attractive car," where attractiveness of a car as a function of mileage and top speed is defined in the following table.
Top speed Mileage
Attractive cars (mph) (mpg) 11
60 30 .4
60 35 .5
60 40 .6
70 30 .7
85 25 .7
90 25 .8
95 25 .9
100 20 1.0
lID 15 1.0
Aparticularizing proposition is "Porsche is a fast car," in which "fast" is defined in the following table:
Fast cars
Top speed (mph)
60 70 85 90 95 100 110
.4 .6 .7 .8 .9 .95
1.0
"Porsche is an attractive car" can equivalently be written as "Porsche is a fast car," that is, "Top speed (Porsche) is high" and "mileage (Porsche) is high."
Using definition 9-9, the particularized relation attractive (1tspeed = Fast) can readily be computed, as shown in the next table:
Attra ctive cars Top speed Mileage J.l
60 30 .4
60 35 .4
60 40 .4
70 30 .6
85 25 .7
90 25 .8
95 25 .9
100 20 0.95
110 15 1
Translation Rules in PRUF. The following types of fuzzy expressions will be considered:
I. Fuzzy propositions such as "All students are young," "X is much larger than Y," and "If Hans is healthy then Biggi is happy."
2. Fuzzy descriptors such as tall men, rich people, small integers, most, several, or few.
3. Fuzzy questions.
Fuzzy questions are reformulated in such a way that additional translation rules for questions are unnecessary. Questions such as "HowAisB?"will be expressed in the form"B is?A," whereBis the body of the question and"?A" indicates the form of an admissible answer, which can be a possibility distribution (indicated
as1t); a truth value (indicated as r): a probability value (indicated as A.); or a possibility value (indicated as (0).
The question "How tall is Paul?" to which a possibility distribution is expected as an answer, is phrased "Paul is 'Itt" (rather than "How tall is Paul ?1t). "Is it true that Katrin is pretty?" would then be expressed as "Katrin is pretty ?t" and
"Where is the car ?w" as "The car is ?w."
PRUF is an intentional language, that is, an expression in PRUF is supposed to convey the intended rather than the literal meaning of the corresponding expression in a natural language. Transformations of expressions are also intended to be meaning-preserving. Translation rules are applied singly or in combination to yield an expression,E,in PRUF that is a translation of a given expression,e, in a natural language.
The most important basic categories of translation rules in PRUF are Type I
TypeII Type III Type IV
Rules pertaining to modification Rules pertaining to composition Rules pertaining to quantification Rules pertaining to qualification
Examples of propositions to which these rules apply are the following [Zadeh 1981a, p. 29]:
Type I X is very small.
X is much larger than Y.
Eleanor was very upset.
The man with the blond hair is very tall.
TypeII X is small andYis large. (conjunctive composition) X is small orYis large. (disjunctive composition) IfX is small, then Yis large. (conditional composition)
IfX is small, then
f
is large else (conditional and conjunctive Yis very large. lcomposition)Type III Most Swedes are tall.
Many men are much taller than most men.
Most tall men are very intelligent.
Type IV Abe is young is not very true. (truth qualification) Abe is young is quite probable. (probability qualification) Abe is young is almost impossible. (possibility qualification)
Rules of Type I
Type I rules concern the modification of fuzzy sets representing propositions by means of hedges or modifiers (see definition 9-3).
If the proposition
P==Nis
i
translates into the possibility assignment equation
1t(Xt . .. . .xn) -
-F
then the translation of the modified proposition P+ ==NismFis
1t(Xt . .. . .xn) -- F+
where
i+
is a modification ofi
by the modifierm. As mentioned in chapter 9.1, the modifier "very" is defined to be the squaring operation, "more or less" the dilation, and so on.Example 9-11
Letp be the proposition "Hans is old," where "old" may be the fuzzy set defined in example 9-1. The translation ofp+=="Hans is very old," assuming "very" to be modeled by squaring, would then be
1tAge(Hans)
=
(0Id)2= {(u,
fl( Old)2(u))lu
E[0, 100]) whereUE[O,50]
UE(50, 100]
Rules of Type II
Rules of type II translate compound statements of the type p=q*r
where
*
denotes a logical connective-for example, and (conjunction) or (dis- junction), if ... then (implication), and so on. Here, essentially the definitions of connectives defined in section 9.1 and 9.2 are used in PRUF.Ifthe statements q and r are
q ==M is F~1t(x\, ,Xn)
=
Fr==N is G~1t(ij , ,Yn)=G then
(M is F)and(N is G)~1t(XI ,...,Xn, ij,...,Yn) = F x G where
F
xG
={«u,v),IltxG(U' v))luEU,vEV}and
IltXG(U, v)=min{IlF(u), Ildv)}
"IfMis
i,
then N isG"
~1t(x\,...,Xn,YI, ...,Yn)=if.
EBGf.
whereFf.
andGf.
are thecylindrical extensions of
F
andG
and EB is the bounded sum defined in defini- tion 3-9, Hence1lfL.$GI.(u, v)=min{I,Ilt(u)+Ildv)}
Example9-12 [Zadeh 198Ia, pp. 32-33]
Assume thatU
=
v=
1, 2, 3 andM==X,N==Y,andF
==small == {(l, 1), (2, .6), (3, .I)}G
==1arg e == {(l, .1), (2, .6), (3,I)}Then X is small and Yis large~
1t(x,y)= {[(I, 1), .1], [(1,2), .6], [(1,3), 1], [(2, 1), .1], [(2, 2), .6], [(2,3), .6], [(3, 1), .1], [(3,2),.1], [(3, 3), .I]}
X is small orYis large~
1t(x,y) = {[(1, 1), 1], [(1, 2), 1], [(1, 3), 1], [(2, 1),.6], [(2,2), .6], [(2,3), 1], [(3,1),.1], [(3,2), .6], [(3,3), .1]}
If X is small, thenYis large~
1t(x,y) = {[(I , 1), 1], [(1, 2), .6], [(1, 3), 1], [(2, 1), .5], [(2, 2), I], [(2,3), 1], [(3, 1), 1], [(3,2), 1], [(3,3), I]}
Translation rules of type II can, of course, also be applied to propositions con- taining linguistic variables. In some applications, it is convenient to represent fuzzy relations as tables (such as those shown in section 6. I). These tables can also be processed in PRUF.
Rules of TypeIII
Type III translation rules pertain to the translation of propositions of the form p==QN are F
whereNmay also be a fuzzy set and Qis a so-called quantifier, for example, a term such as most, many, few, some, and so on. Examples are
Most children are cheerful.
Few lazy boys are successful.
Some men are much richer than most men.
A quantifier, Q, is in general a fuzzy set of which the universe is either the set of integers, the unit interval, or the real line.
Some quantifiers, such as most, many, and so on, refer to propositions of sets that may either be crisp or fuzzy. In this case, the definition of a quantifier makes use of the cardinality or the relative cardinality, as defined in definition2-5 .
In PRUF, the notation prop(FIG)is used to express the proportion ofFin
G
where
( -j -) count(in
G)
linGI
propF G
= - = -
count
G IGI
where "count" corresponds to the above-mentioned cardinality. The quantifier
"most" may then be a fuzzy set
Q
={[prop(Fj
G),!lmos((u, v)]luEi;
vEG}Example 9-13
The quantifier "several" could, for instance, be represented by
Q
==several== {(3, .3), (4, .6), (5,1), (6, .8), (7, .6), (8,.3)}Rules of Type IV
In PRUF, the concept of truth serves to make statements about the relative truth of a propositionp with respect to another reference proposition (and not with respect to reality!) . Truth is taken to be a linguistic variable, as defined in section 9.1.
Truth is then interpreted as the consistency of propositionp with propositionq.If p==N is F-HCp=
F.-
q==N is G~1tq=G
then the consistency ofpwith qis given as
cons{N is FIN is G} == poss{N is FIN is G}
=sup{min(llt(u),Il a(u))}
ueU
Example 9-14 Let
p==Nis a small integer q==Nis not a small integer where
small integer == {(O,1),
0,
1),(2, .8), (3, .6), (4, .5), (5, .4), (6, .2)}Then
cons{p
I
q} =sup{[O, 0, .2, .4, .5, .4, .2]}= .5
More in line with fuzzy set theory is the consideration of the truth of a propo- sition as a fuzzy number. Therefore Zadeh defines in the context of PRUF truth as follows:
Definition 9-10 [Zadeh 198Ia, p. 42]
Letpbe a proposition of the form "Nis
F,"
and letrbe a reference proposition, r ==NisG,
whereF
andG
are subsets ofU.Then the truth, r, ofp relative to r is defined as the compatibility of r with p, that is,r ==Tr(N is FIN is
G)
==comp(N is GIN is F)==Ilt(G)
=={('t,Ilt(G)~'tE[0, I]}
with
Il t(G)= infW t(u),Il a(u)},UEU
te[O ,I)
The rule for truth qualification in PRUF can now be stated as follows [Zadeh 1981a, p. 44] : Let p be a proposition of the form
p== N is
F
and let qbe a truth-qualified version ofp expressed as
q==N is
F
is rwhere r is a linguistic truth value. q is semantically equivalent to the reference proposition, that is,
N is
F
is 't~N isG
where
F, G,
andr are related by't=~F(G)
In analogy to truth qualification, translation rules for probability qualification and possibility qualification have been developed in PRUF.
Example 9-15 Let
v =
No=
{O, 1, 2, .. . }, NE No p= N is smallr=N is approximately 4 where
small = {(O, 1),(l, 1), (2, .8), (3, .6), (4,.4), (5, .2)}
approximately 4= {(l,.1), (2, .2), (3, .5), (4, 1), (5, .5), (6, .2),(7, .1)}
Then
't=Tr(N is smalllN is approximately 4)
=comp(N is approximately 41N is small)
= {(~small(u),~4(u»luEV}
={(O, .2), (.2, .5),(.4, 1),(.6, .5), (.8, .2),
0,
.1)}9.5 Support Logic Programming and Fril