fuzzy logic dave saad cs498. origin proposed as a mathematical model similar to traditional set...

15
Fuzzy Logic Dave Saad CS498

Post on 22-Dec-2015

223 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Fuzzy Logic Dave Saad CS498. Origin Proposed as a mathematical model similar to traditional set theory but with the possibility of partial set membership

Fuzzy Logic

Dave SaadCS498

Page 2: Fuzzy Logic Dave Saad CS498. Origin Proposed as a mathematical model similar to traditional set theory but with the possibility of partial set membership
Page 3: Fuzzy Logic Dave Saad CS498. Origin Proposed as a mathematical model similar to traditional set theory but with the possibility of partial set membership
Page 4: Fuzzy Logic Dave Saad CS498. Origin Proposed as a mathematical model similar to traditional set theory but with the possibility of partial set membership

OriginProposed as a mathematical model similar to traditional set theory but with the possibility of partial set membership by Lotfi A. Zadeh in 1965.Allows for ambiguity or “fuzzy” boundaries of set membership as opposed to “crisp” membership of “in” or “out” of a set

Useful when given inputs are subjective.

Page 5: Fuzzy Logic Dave Saad CS498. Origin Proposed as a mathematical model similar to traditional set theory but with the possibility of partial set membership

Initially Rejected by Math and Science CommunitiesWhile initially rejected in the western world, the idea of embracing ambiguity in a control system was quickly adopted by Japanese Industry and successfully turned into many varied products from rice cookers to subway train controllers.

American Industry followed slowly.

Page 6: Fuzzy Logic Dave Saad CS498. Origin Proposed as a mathematical model similar to traditional set theory but with the possibility of partial set membership

Fuzzy Logic▸ Based on Linguistic Rules of Inference

Modus PonensModus Tollens

▸ Rules of logic developed by ancient Greeks that became the basis of (Aristotelean) western philosophy.

▸ Eastern philosophical thought is more amenable to ambiguity which may explain the early adoption of Fuzzy Logic

Page 7: Fuzzy Logic Dave Saad CS498. Origin Proposed as a mathematical model similar to traditional set theory but with the possibility of partial set membership

Modus Ponens

A conditional Statement and its antecedent:

If P then Q

P is TRUE

Therefore Q is also TRUE

The consequent (Q) is inferred to be TRUE from the truth value of the antecedent (P)

Page 8: Fuzzy Logic Dave Saad CS498. Origin Proposed as a mathematical model similar to traditional set theory but with the possibility of partial set membership

Modus Tollens

A conditional Statement and its antecedent:

If P then QNOT P (or P is FALSE)Therefore Q is also FALSE

The consequent (Q) is inferred to be FALSE from the truth value of the antecedent (P)

Page 9: Fuzzy Logic Dave Saad CS498. Origin Proposed as a mathematical model similar to traditional set theory but with the possibility of partial set membership

Logical Operators▸ NOT (negation

Defined as 1-A

▸ AND (intersection)

Defined as MIN(A,B)

▸ OR (union)

Defined as MAX(A,B)

Other operators are possible but rarely used

Page 10: Fuzzy Logic Dave Saad CS498. Origin Proposed as a mathematical model similar to traditional set theory but with the possibility of partial set membership

Partial Membership

V

ZNS

Page 11: Fuzzy Logic Dave Saad CS498. Origin Proposed as a mathematical model similar to traditional set theory but with the possibility of partial set membership

Rules of Inference

These rules are often based on human instinct and experience.

•If Temperature is COLD then fan speed is STOP

•If Temperature is COOL then fan speed is SLOW

•If Temperature is JUST RIGHT then fan speed is MEDIUM

•If Temperature is WARM then fan speed is FAST

•If Temperature is HOT then fan speed is TORNADO

Page 12: Fuzzy Logic Dave Saad CS498. Origin Proposed as a mathematical model similar to traditional set theory but with the possibility of partial set membership

Execute the Rules

•Rules all fire all the time

•Rules all fire in parallel

•All rules fire to some degree

•Most rules fire to zero degree

•The result is a union of fuzzy results from each rule

Page 13: Fuzzy Logic Dave Saad CS498. Origin Proposed as a mathematical model similar to traditional set theory but with the possibility of partial set membership

Defuzzify The Result Set•Centroid or area under the output set curve

•Computationally intensive

•Mean of Maximum

•Max-membership (height method)

•Weighted Average

•This produces results very close to the COA method and is less computationally intensive

Page 14: Fuzzy Logic Dave Saad CS498. Origin Proposed as a mathematical model similar to traditional set theory but with the possibility of partial set membership

DefuzzificationThe best method is problem dependent..

Four criteria against which to measure the methods:

1. Continuity. A small change in input should produce a small change in the output

2. Disambiguity. Output should resolve to a unique value.

3. Plausibility. Crisp output value should have a high degree of membership.

4. Computational Simplicity. Integrals are hard to do on a 8-bit microcontroller.

Page 15: Fuzzy Logic Dave Saad CS498. Origin Proposed as a mathematical model similar to traditional set theory but with the possibility of partial set membership

Summary

1. Fuzzification of inputs

2. Choose linguistic variables and terms and associated fuzzy sets

3. Build rules of inference

4. Defuzzification