Search News A new AKIRA sub project was born! Thanks to our coworker Dimitri! Fuzzy Logic There is a precise date in which we can set fuzzy logic born. It is thepublication of the article Fuzzy Sets written by Lofti A. Zadeh on theInformation and Control Journal in the 1965."fuzzy" term state for not clear, smoothed and vague. In this sensethat could seem in contradiction with the classical meaning of logic.But this isn't true. In fact fuzzy logic is a superset of Boolean logicwith its own detailed and rigorous algebra.Just as there is a strong relationship between Boolean logic and theconcept of a subset, there is a similar strong relationship betweenfuzzy logic and fuzzy subset theory. In classical set theory, a subset U of a set S can be defined as amapping from the elements of S to the elements of the set {0, 1},   U: S --> {0, 1} This mapping may be represented as a set of ordered pairs, with exactlyone ordered pair present for each element of S. The first element ofthe ordered pair is an element of the set S, and the second element is anelement of the set {0, 1}.  The value zero is used to representnon-membership, and the value one is used to represent membership. The truth or falsity of the statement    x is in U is determined by finding the ordered pair whose first element is x.The statement is true if the second element of the ordered pair is 1, andthe statement is false if it is 0. Similarly, a fuzzy subset F of a set S can be defined as a set ofordered pairs, each with the first element from S, and the second element fromthe interval [0,1], with exactly one ordered pair present for eachelement of S. This defines a mapping between elements of the set S andvalues in the interval [0,1].  The value zero is used to representcomplete non-membership, the value one is used to represent completemembership, and values in between are used to represent intermediateDEGREES OF MEMBERSHIP.  The set S is referred to as the UNIVERSE OFDISCOURSE for the fuzzy subset F.  Frequently, the mapping is describedas a function, the MEMBERSHIP FUNCTION of F. The degree to which the statement    x is in F is true is determined by finding the ordered pair whose first elementis x.  The DEGREE OF TRUTH of the statement is the second element of theordered pair. In practice, the terms "membership function" and fuzzy subset get usedinterchangeably. That's a lot of mathematical baggage, so here's an example.  Let'stalk about people and "tallness".  In this case the set S (theuniverse of discourse) is the set of people.  Let's define a fuzzysubset TALL, which will answer the question "to what degree is personx tall?" Zadeh describes TALL as a LINGUISTIC VARIABLE, whichrepresents our cognitive category of "tallness". To each person in theuniverse of discourse, we have to assign a degree of membership in thefuzzy subset TALL.  The easiest way to do this is with a membershipfunction based on the person's height.    tall(x) = { 0,                     if height(x) < 5 ft.,               (height(x)-5ft.)/2ft., if 5 ft. <= height (x) <= 7 ft.,               1,                     if height(x) > 7 ft. } A graph of this looks like: 1.0 +                   +-------------------   |                     /   |                   /0.5 +              /   |                /   |              /0.0 +---------------+-----+-------------------                 |         |                5.0     7.0                height, ft. -> Given this definition, here are some example values: Person    Height    degree of tallness--------------------------------------Billy     3' 2"     0.00 [I think]Yoke      5' 5"     0.21Drew      5' 9"     0.38Erik      5' 10"    0.42Mark      6' 1"     0.54Kareem    7' 2"     1.00 [depends on who you ask] Expressions like "A is X" can be interpreted as degrees of truth,e.g., "Drew is TALL" = 0.38. Note: Membership functions used in most applications almost never haveas simple a shape as tall(x). At minimum, they tend to be trianglespointing up, and they can be much more complex than that.  Also, the discussion characterizes membership functions as if they always are based on a single criterion, but this isn't always the case, although it is quitecommon.  One could, for example, want to have the membership functionfor TALL depend on both a person's height and their age (he's tall for hisage). This is perfectly legitimate, and occasionally used in practice.It's referred to as a two-dimensional membership function, or a "fuzzyrelation".  It's also possible to have even more criteria, or to havethe membership function depend on elements from two completely differentuniverses of discourse. In AKIRA fuzzy logic is provided through FLIP++ (see Links). FLIP++ isa powerful fuzzy engine able to construct complex fuzzy set and fuzzyrules. It also integrates inference methods to obtain crisp values ofunknown variables basing the calculus on known variables values and onrules correlating each of them with the others.