User talk:Amtamas

Testing Page.

Process steps: Fuzzify Fuzzy control (Fuzzy Interference System) Defuzzify

fuzzy control (Fuzzy Interference System)

input stage processing stage output stage

input stage The input stage maps sensor or other inputs, such as switches, thumbwheels, and so on, to the appropriate membership functions and truth values.

Processing stage The processing stage invokes each appropriate rule and generates a result for each, then combines the results of the rules.

output stage The output stage converts the combined result back into a specific control output value. The most common shape of membership functions is triangular, although trapezoidal and bell curves are also used, but the shape is generally less important than the number of curves and their placement.

Consider a rule for a thermostat: IF (temperature is "cold") THEN (heater is "high")

Given this definition, here are some example values:

Person   Height    degree of tallness -- Billy    3' 2"     0.00 [I think] Yoke      5' 5"     0.21 Drew     5' 9"     0.38 Erik      5' 10"    0.42 Mark     6' 1"     0.54 Kareem    7' 2"     1.00 [depends on who you ask]

So given this definition, we'd say that the degree of truth of the statement "Drew is TALL" is 0.38.

Logic Operations

Ok, we now know what a statement like

X is LOW means in fuzzy logic. The question now arises, how do we interpret a statement like

X is LOW and Y is HIGH or (not Z is MEDIUM) The standard definitions in fuzzy logic are:

truth (not x)  = 1.0 - truth (x) truth (x and y) = minimum (truth(x), truth(y)) truth (x or y) = maximum (truth(x), truth(y))

which are simple enough. Some researchers in fuzzy logic have explored the use of other interpretations of the AND and OR operations, but the definition for the NOT operation seems to be safe. Note that if you plug just the values zero and one into these definitions, you get the same truth tables as you would expect from conventional Boolean logic.

Some examples - assume the same definition of TALL as above, and in addition, assume that we have a fuzzy subset OLD defined by the membership function:

old (x) = { 0,                     if age(x) < 18 yr. (age(x)-18 yr.)/42 yr., if 18 yr. <= age(x) <= 60 yr. 1,                     if age(x) > 60 yr. } And for compactness, let

a = X is TALL and X is OLD b = X is TALL or X is OLD c = not X is TALL Then we can compute the following values.

height age     X is TALL       X is OLD        a       b       c

3' 2"  65?     0.00            1.00            0.00    1.00    1.00 5' 5"   30      0.21            0.29            0.21    0.29    0.79 5' 9"   27      0.38            0.21            0.21    0.38    0.62 5' 10"  32      0.42            0.33            0.33    0.42    0.58 6' 1"   31      0.54            0.31            0.31    0.54    0.46 7' 2"   45?     1.00            0.64            0.64    1.00    0.00 3' 4"   4       0.00            0.00            0.00    0.00    1.00

=
========================xxxxxxxxxxxxx========================================= ________________    _______________     ________________ I  |               |    |              |    |               | O N  |Crisp-to-Fuzzy |    |  Inference   |    |Fuzzy-to-Crisp | U P  |               |--->|              |--->|               | T U  |    FUZZIFY    |    | max-min, etc |    |   DEFUZZIFY   | P T  |_______________|    |______________|    |_______________| U                                                              T  membership functions     rule base          max, average, centroid, singleton, etc

Classical bivalent sets are in fuzzy set theory usually called crisp sets

=
==============================================================================

Rule Base

The Fuzzy Rule Base is characterized by construction of a set of linguistic rules based on experts knowledge. The expert knowledge is usually in the form of IF-THEN rules, which can be easily implemented by fuzzy conditional statements.

·       Rule 1: IF (sugar conc. = “low”) and (water conc. = “normal”) THEN (add more “sugar”) ·       Rule 2: IF (sugar conc. = “high”) and (water conc. = “normal”) THEN (add more “water”) ·       Rule 3: IF (water conc. = “low”) and (sugar conc. = “normal”) THEN (add more “water”) ·       Rule 4: IF (water conc. = “high”) and (sugar conc. = “normal”) THEN (add more “sugar”) Concise rules to the final volume of the output are simply given below; ·       Rule 5: IF (water conc. = “high”) THEN (add more “sugar”) ·       Rule 6: IF (sugar conc. = “high” THEN (add more “water”) ·        Rule 7: IF (sugar AND water conc. = Normal) THEN Output is Normal