fuzzy rules & fuzzy reasoning - universitas negeri...
TRANSCRIPT
Fuzzy Rules & Fuzzy Reasoning
Jyh-Shing Roger Jang et al., Neuro-Fuzzy and Soft Computing: A Computational Approach to Learning and Machine Intelligence, First Edition, Prentice Hall, 1997
Pengampu: Fatchul Arifin
Referensi:
Sistem Cerdas : PTK – Pasca Sarjana - UNY
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
22
– Orthogonality
A term set T = t1,…, tn of a linguistic variable x on the universe X is orthogonal if:
Where the ti’s are convex & normal fuzzy sets defined on X.
n
1iit Xx ,1)x(
Fuzzy if-then rules (3.3) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
23
General format:
– If x is A then y is B (where A & B are linguistic values defined by fuzzy sets on universes of discourse X & Y).
• “x is A” is called the antecedent or premise• “y is B” is called the consequence or conclusion
– Examples:
• If pressure is high, then volume is small.• If the road is slippery, then driving is dangerous.• If a tomato is red, then it is ripe.• If the speed is high, then apply the brake a little.
Fuzzy if-then rules (3.3) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
24
– Meaning of fuzzy if-then-rules (A B)
• It is a relation between two variables x & y; therefore it is a binary fuzzy relation R defined on X * Y
• There are two ways to interpret A B:
– A coupled with B– A entails B
if A is coupled with B then:
or.normoperat-T a is * where
)y,x/()y(*)x(B*ABAR
~Y*X
B
~
A
Fuzzy if-then rules (3.3) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
25
If A entails B then:
R = A B = A B ( material implication)
R = A B = A (A B) (propositional calculus)
R = A B = ( A B) B (extended propositional calculus)
1c0),y(c*)x(;csup)y,x( B
~
AR
Fuzzy if-then rules (3.3) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
26
Two ways to interpret “If x is A then y is B”:
A
B
A entails By
x
A coupled with B
A
B
x
y
Fuzzy if-then rules (3.3) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
27
• Note that R can be viewed as a fuzzy set with a two-dimensional MF
R(x, y) = f(A(x), B(y)) = f(a, b)
With a = A(x), b = B(y) and f called the fuzzy implication function provides the membership value of (x, y)
Fuzzy if-then rules (3.3) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
28
– Case of “A coupled with B”
(minimum operator proposed by Mamdani, 1975)
(product proposed by Larsen, 1980)
(bounded product operator)
YX
BAm yxyxBAR*
),/()()(*
)y,x/()y( )x(B*ARY*X
BAp
)y,x/()1)y()x((0
)y,x/()y()x(B*AR
BAY*X
Y*XBAbp
Fuzzy if-then rules (3.3) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
29
– Case of “A coupled with B” (cont.)
(Drastic operator)
)10,3,4;()( and )10,3,4;()(for otherwise if 0
1a if 1b if
.̂ab)f(a, :
),/()(.̂)(*
BA
*
ybellyxbellxExample
ba
bwhere
yxyxBARYX
BAdp
Fuzzy if-then rules (3.3) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
30
A coupled with B
Fuzzy if-then rules (3.3) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
31
– Case of “A entails B”
(Zadeh’s arithmetic rule by using bounded sum operator for union)
(Zadeh’s max-min rule)
)ba1(1)b,a(f :where
)y,x/()y()x(1(1BAR
a
Y*XBAa
)ba()a1()b,a(f :where
)y,x/())y()x(())x(1()BA(AR
m
Y*XBAAmm
Fuzzy if-then rules (3.3) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
32
– Case of “A entails B” (cont.)
(Boolean fuzzy implication with max for union)
(Goguen’s fuzzy implication with algebraic product for T-norm)
b)a1()b,a(f :where
)y,x/()y())x(1(BAR
s
Y*XBAs
otherwise a/bba if 1
b~a :where
)y,x/())y(~)x((RY*X
BA
Fuzzy if-then rules (3.3) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
33
A entails B
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
34
Fuzzy Reasoning (3.4)
Definition
– Known also as approximate reasoning
– It is an inference procedure that derives conclusions from a set of fuzzy if-then-rules & known facts
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
35
Fuzzy Reasoning (3.4) (cont.)
Compositional rule of inference
– Idea of composition (cylindrical extension & projection)
• Computation of b given a & f is the goal of the composition
– Image of a point is a point
– Image of an interval is an interval
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
36
Derivation of y = b from x = a and y = f(x):
a and b: pointsy = f(x) : a curve
x
y
a
b
y = f(x)
a
b
y
x
a and b: intervalsy = f(x) : an interval-valued
function
y = f(x)
Fuzzy Reasoning (3.4) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
37
– The extension principle is a special case of the compositional rule of inference
• F is a fuzzy relation on X*Y, A is a fuzzy set of X & the goal is to determine the resulting fuzzy set B
– Construct a cylindrical extension c(A) with base A
– Determine c(A) F (using minimum operator)
– Project c(A) F onto the y-axis which provides B
Fuzzy Reasoning (3.4) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
38
a is a fuzzy set and y = f(x) is a fuzzy relation:
cri.m
Fuzzy Reasoning (3.4) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
39
Given A, A B, infer B
A = “today is sunny”A B: day = sunny then sky = blueinfer: “sky is blue”
• illustration
Premise 1 (fact): x is APremise 2 (rule): if x is A then y is B
Consequence: y is B
Fuzzy Reasoning (3.4) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
40
Approximation
A’ = “ today is more or less sunny”B’ = “ sky is more or less blue”
• iIlustration
Premise 1 (fact): x is A’Premise 2 (rule): if x is A then y is B
Consequence: y is B’
(approximate reasoning or fuzzy reasoning!)
Fuzzy Reasoning (3.4) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
41
Definition of fuzzy reasoning
Let A, A’ and B be fuzzy sets of X, X, and Y, respectively. Assume that the fuzzy implication A B is expressed as a fuzzy relation R on X*Y. Then the fuzzy set B induced by “x is A’ ” and the fuzzy rule “if x is A then y is B’ is defined by:
Single rule with single antecedentRule : if x is A then y is BFact: x is A’Conclusion: y is B’ (B’(y) = [x (A’(x) A(x)] B(y))
)y,x(),x(minmax)y( R'Ax
'B
Fuzzy Reasoning (3.4) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
42
A
X
w
A’ B
Y
x is A’
B’
Y
A’
Xy is B’
Fuzzy Reasoning (3.4) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
43
– Single rule with multiple antecedentsPremise 1 (fact): x is A’ and y is B’Premise 2 (rule): if x is A and y is B then z is C
Conclusion: z is C’
Premise 2: A*B C
)z()w(w
)z()y()y()x()x(
)z()y()x()y()x(
)z()y()x()y()x()z(
)CB*A()'B'*A('C
)z,y,x/()z()y()x(C*)B*A()C,B,A(R
C21
C
2w
B'By
1w
A'Ax
CBA'B'Ay,x
CBA'B'Ay,x'C
2premise1premise
CBZ*Y*X
Amamdani
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
44
A BT-norm
X Y
w
A’ B’ C2
Z
C’
ZX Y
A’ B’
x is A’ y is B’ z is C’
w1
w2
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
45
– Multiple rules with multiple antecedents
Premise 1 (fact): x is A’ and y is B’Premise 2 (rule 1): if x is A1 and y is B1 then z is C1
Premise 3 (rule 2): If x is A2 and y is B2 then z is C2
Consequence (conclusion): z is C’
R1 = A1 * B1 C1
R2 = A2 * B2 C2
Since the max-min composition operator o is distributive over the union operator, it follows:
C’ = (A’ * B’) o (R1 R2) = [(A’ * B’) o R1] [(A’ * B’) o R2] = C’1 C’2Where C’1 & C’2 are the inferred fuzzy set for rules 1 & 2 respectively
Fuzzy Reasoning (3.4) (cont.)
Dr. Djamel Bouchaffra CSE 513 Soft Computing, Ch. 3: Fuzzy rules & fuzzy reasoning
46
A1 B1
A2 B2
T-norm
X
X
Y
Y
w1
w2
A’
A’ B’
B’ C1
C2
Z
Z
C’
ZX Y
A’ B’
x is A’ y is B’ z is C’