0% found this document useful (0 votes)
72 views

Fuzzy Rule Based Models

The document discusses fuzzy rule-based models and their components. It describes how fuzzy rules can represent knowledge through if-then conditional statements using information granules like fuzzy sets. A fuzzy rule-based system consists of a set of such rules relating input and output variables. The document outlines different types of fuzzy rules, including multi-input multi-output rules, certainty-qualified rules, gradual rules, and functional rules. It also discusses the syntax of fuzzy rules and basic functional modules like the input interface, rule base, and fuzzy inference process used in fuzzy rule-based systems.

Uploaded by

sandelhincr
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
72 views

Fuzzy Rule Based Models

The document discusses fuzzy rule-based models and their components. It describes how fuzzy rules can represent knowledge through if-then conditional statements using information granules like fuzzy sets. A fuzzy rule-based system consists of a set of such rules relating input and output variables. The document outlines different types of fuzzy rules, including multi-input multi-output rules, certainty-qualified rules, gradual rules, and functional rules. It also discusses the syntax of fuzzy rules and basic functional modules like the input interface, rule base, and fuzzy inference process used in fuzzy rule-based systems.

Uploaded by

sandelhincr
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 111

11 Fuzzy Rule-Based

Models

Fuzzy Systems Engineering


Toward Human-Centric Computing
Contents

11.1 Fuzzy rules as a vehicle of knowledge representation


11.2 General categories of fuzzy rules and their semantics
11.3 Syntax of fuzzy rules
11.4 Basic functional modules
11.5 Types of rule-based systems and architectures
11.6 Approximation properties of fuzzy rule-based models
11.7 Development of rule-based systems

Pedrycz and Gomide, FSE 2007


11.8 Parameter estimation procedure for functional
rule-based systems
11.9 Design of rule-based systems: consistency,
completeness and the curse of dimensionality
11.10 Course of dimensionality in rule-based systems
11.11 Development scheme of fuzzy rule-based models

Pedrycz and Gomide, FSE 2007


11.1 Fuzzy rules as a vehicle of
knowledge representation

Pedrycz and Gomide, FSE 2007


Rule ≡ conditional statement

• If 〈 input variable is A 〉 then 〈 output variable is B 〉

– A and B: descriptors of pieces of knowledge

– rule: expresses a relationship between inputs and outputs

• Example

– If 〈 the temperature is high 〉 then 〈 the electricity demand is high 〉

• If and then parts 〈.......〉 formed by information granules

– sets
– rough sets
– fuzzy sets

Pedrycz and Gomide, FSE 2007


Rule-based system/model (FRBS)

• FRBS is a family of rules of the form

If 〈 input variable is Ai 〉 then 〈 output variable is Bi 〉

i = 1, 2,..., c

Ai and Bi are information granules

• More complex rules

If 〈 input variable1 is Ai 〉 and 〈 input variable2 is Bi 〉 and .....


then 〈 output variable is Zi 〉

– multidimensional input space (Cartesian product of inputs)


– individual inputs aggregated by the and connective
– highly parallel, modular granular model

Pedrycz and Gomide, FSE 2007


11.2 General categories of fuzzy
rules and their semantics

Pedrycz and Gomide, FSE 2007


Multi-input multi-output fuzzy rules

• If X1 is A1 and X2 is A2 and ..... and Xn is An


then Y1 is B1 and Y2 is B2 and ..... and Ym is Bm

Xi = variables whose values are fuzzy sets Ai


Yj = variables whose values are fuzzy sets Bj

Ai on Xi, i = 1, 2,...,n

Bj on Yj, j = 1, 2,...,m

• No loss of generality if we assume rules of the form

If X is A and Y is B then Z is C

Pedrycz and Gomide, FSE 2007


Certainty-qualified rules

• If X is A and Y is B then Z is C with certainty µ

µ ∈[0,1]

µ : degree of certainty of the rule

µ = 1 rule is certain

Pedrycz and Gomide, FSE 2007


Gradual rules

• the more X is A the more Y is B

– relationships between changes in X and Y

– captures tendency between information granules

• Examples:

the higher the income, the higher the taxes

the lower the temperature, the higher energy consumption

Pedrycz and Gomide, FSE 2007


Functional fuzzy rules

• If X is Ai then y = f (x,ai)

f:X→Y

x∈Rn

• Rule: confines the function to the support of granule Ai

f : linear or nonlinear (neural nets, etc..)

• Highly modular models

Pedrycz and Gomide, FSE 2007


11.3 Syntax of fuzzy rules

Pedrycz and Gomide, FSE 2007


Backus-Naur form (BNF)

〈 If_then_rule〉 ::= if 〈antecedent〉 then 〈consequent〉{〈certainty〉}


〈gradual_rule 〉 ::= 〈word〉 〈antecedent〉〈word〉 〈consequent〉
〈word〉 ::= 〈more〉 {〈less〉}
〈antecedent〉 ::= 〈expression〉
〈consequent〉 ::= 〈expression〉
〈expression〉 ::= 〈disjunction〉{and 〈disjunction〉}
〈disjunction〉 ::= 〈variable〉{or〈variable〉}
〈variable〉 ::= 〈attribute〉 is 〈value〉
〈certainty〉 ::= 〈none〉{certainty µ∈[0,1]}

Pedrycz and Gomide, FSE 2007


Construction of computable representations

Main steps:

1. specification of the fuzzy variables to be used

2. association of the fuzzy variables using fuzzy sets

3. computational formalization of each rule using fuzzy


relations and definition of aggregation operator to combine
rules together

Pedrycz and Gomide, FSE 2007


11.4 Basic functional
modules of FRBS

Pedrycz and Gomide, FSE 2007


General architecture of FRBS

Fuzzy if-then rules Parameters


(input-output relationship) of the FRBS

Output Interface
Rule Data
Input Interface

Base Base
X Y
Fuzzy
Inference

Process inputs and rules


(approximate reasoning)
Pedrycz and Gomide, FSE 2007
Input interface
• (attribute) of (input) is (value)

the temperature of the motor is high

• Canonical (atomic) form

p: X is A temperature (motor) is high


X A

fuzzy set

Low Medium High

x (°C)
Pedrycz and Gomide, FSE 2007
Multiple fuzzy inputs: conjunctive canonical form

p : X1 is A1 and X2 is A2 and ..... and Xn is An conjunctive canonical form

Xi are fuzzy (linguistic) variables

Ai : fuzzy sets on Xi

i = 1, 2, ..., n

Compound proposition induces a fuzzy relation P on X1×X1×... Xn

n
P( x1 , x2 ,K , xn ) = A1 ( x1 )tA2 ( x2 )t KtAn ( xn ) = T Ai ( xi ) t (T) = t-norm
i =1

p : (X1, X2 , ....., Xn) is P

Pedrycz and Gomide, FSE 2007


Example
• Fuzzy relation associated with (X,Y) is P

• Triangular fuzzy sets A1(x,4,5,6) = A, A2(y,8,10,12) = B

• t-norm: algebraic product

(b) Contours of P
20

y
P
10

0
0 5 x 10

Pedrycz and Gomide, FSE 2007


Multiple fuzzy inputs: disjunctive canonical form

q : X1 is A1 or X2 is A2 or ..... or Xn is An disjunctive canonical form

Xi are fuzzy (linguistic) variables

Ai : fuzzy sets on Xi

i = 1, 2, ..., n

Compound proposition induces a fuzzy relation Q on X1×X1×... Xn

n
Q( x1 , x2 ,K , xn ) = A1 ( x1 ) sA2 ( x2 ) s K sAn ( xn ) = S Ai ( xi ) s (S) = t-conorm
i =1

q : (X1, X2 , ....., Xn) is Q

Pedrycz and Gomide, FSE 2007


Example
• Fuzzy relation associated with (X,Y) is Q

•Triangular fuzzy sets A1(x,4,5,6) = A, A2(y,8,10,12) = B

• t-conorm: probabilistic sum

(d) Contours of Q
20

y
Q

10

0
0 5 x 10

Pedrycz and Gomide, FSE 2007


Rule base

• Fuzzy rule: If X is A then Y is B ≡ relationship between X and Y

• Semantics of the rule is given by a fuzzy relation R on X×Y

• R determined by a relational assignment

R(x,y) = f (A(x),B(y)) ∀(x, y)∈X×Y

f : [0,1]2 → [0,1]

• In general f can be

– fuzzy conjunction: ft
– fuzzy disjunction: fs
– fuzzy implication: fi

Pedrycz and Gomide, FSE 2007


Fuzzy conjunction

Choose a t-norm t and define:

R(x,y) ≡ ft (x,y) = A(x) t B(y) ∀(x,y) ∈ X×Y

Examples:

• t = min

Rc(x,y) ≡ fc (x,y) = min[A(x) t B(y)] (Mamdani)

• t = algebraic product

Rp(x,y) ≡ fp (x,y) = A(x)B(y) (Larsen)

Pedrycz and Gomide, FSE 2007


Example: t = min

Rc(x,y) = min {A(x), B(y)} Rc(x,y) = min {A(x), B(y)}


A(x) = A(x,4,5,6)
∀ (A(x), B(y))∈[0,1]2 B(y) = B(y,4,5,6)

Pedrycz and Gomide, FSE 2007


Example: t = algebraic product

Rp(x,y) =A(x)B(y) Rp(x,y) = A(x)B(y)


A(x) = A(x,4,5,6)
∀ (A(x), B(y))∈[0,1]2 B(y) = B(y,4,5,6)

Pedrycz and Gomide, FSE 2007


Fuzzy disjunction

Choose a t-conorm s and define:

Rs(x,y) ≡ fs (x,y) = A(x) s B(y) ∀(x,y) ∈ X×Y

Examples:

• s = max

Rm(x,y) ≡ fm (x,y) = max[A(x) t B(y)]

• s = Lukasiewicz t-conorm

Rl (x,y) ≡ fl (x,y) = min[1, A(x) + B(y)]

Pedrycz and Gomide, FSE 2007


Example: s = max

Rl (x,y) = max{A(x), B(y)} Rl (x,y) = max {A(x), B(y)}


A(x) = A(x,4,5,6)
∀ (A(x), B(y))∈[0,1]2 B(y) = B(y,4,5,6)

Pedrycz and Gomide, FSE 2007


Example: s = Lukasiewicz

Rc(x,y) = min{1, A(x)+B(y)} Rc(x,y) = min{1, A(x)+B(y)}


A(x) = A(x,4,5,6)
∀ (A(x), B(y))∈[0,1]2 B(y) = B(y,4,5,6)

Pedrycz and Gomide, FSE 2007


Fuzzy implication

• Choose a fuzzy implication fi and define:

Ri(x,y) ≡ fi (x,y) ∀(x,y) ∈ X×Y

• fi : [0,1]2 → [0,1] is a fuzzy implication if:

1. B(y1) ≤ B(y2) ⇒ fi (A(x), B(y1)) ≤ fi (A(x), B(y2)) monotonicity 2nd argument

2. fi (0, B(y)) = 1 dominance of falsity

3. fi (1, B(y)) = B(y) neutrality of truth

Pedrycz and Gomide, FSE 2007


• Further requirements may include:

4. A(x1) ≤ A(x2) ⇒ fi (A(x1), B(y)) ≥ fi (A(x2), B(y)) monotonicity 1st argument

5. fi (A(x1), fi (A(x2), B(y)) = fi (A(x2), fi (A(x1), B(y)) exchange

6. fi (A(x), A(x)) = 1 identity

7. fi (A(x), B(y)) = 1 ⇔ A(x) ≤ B(y) boundary condition

8. fi is a continuous function continuity

Pedrycz and Gomide, FSE 2007


Examples of fuzzy implications
Name Definition Comment

Lukasiewicz fl(A(x), B(y)) = min [1, 1 − A(x) + B(y)]

 1 − A( x) + (λ + 1) B( y ) 
Pseudo-Lukasiewicz f λ ( A( x) , B( y )) = min 1,  λ > -1
 1 + λA( x) 

Pseudo-Lukasiewicz f w ( A( x ) , B ( y )) = min [1, (1 − A( x ) w + B ( y ) w )1 / w ] w> 0

1 if A( x) ≤ B( y )
Gaines f a ( A( x) , B( y )) = 
0 otherwise
 1 if A( x) ≤ B( y )
Gödel f g ( A( x) , B ( y )) = 
B( y) otherwise
 1 if A( x) ≤ B ( y )
 B( y )
Goguen f e ( A( x) , B( y )) = 
otherwise
 A( x)
Kleene
f b ( A( x) , B( y )) = max [1 − A( x) , B ( y )]

Reichenbach f r ( A( x) , B( y )) = 1 − A( x) + A( x) B( y )]

Zadeh f z ( A( x) , B( y )) = max [1 − A( x) , min ( A( x) , B( y ))]

Klir-Yuan f k ( A( x) , B( y )) = 1 − A( x) + A( x) 2 B( y )

Pedrycz and Gomide, FSE 2007


Example: fl = Lukasiewicz

Rl (x,y) = min{1, 1– A(x)+B(y)} Rl (x,y) = min{1, 1– A(x)+B(y)}


A(x) = A(x,4,5,6)
∀ (A(x), B(y))∈[0,1]2 B(y) = B(y,4,5,6)

Pedrycz and Gomide, FSE 2007


Example: fk = Klir–Yuan

Rk (x,y) = 1– A(x)+A(x)2B(y) Rk (x,y) = 1– A(x)+A(x)2B(y)


A(x) = A(x,4,5,6)
∀ (A(x), B(y))∈[0,1]2 B(y) = B(y,4,5,6)

Pedrycz and Gomide, FSE 2007


• Categories of fuzzy implications:

1. s-implications
fis ( A( x), B ( y )) = A ( x) sB ( y ) ∀( x , y ) ∈ X × Y

fb ( A( x), B ( y )) = max[1 − A( x) , B ( y )] Kleene

f g ( A( x), B( y )) = min{1, 1 − A( x) + B ( y )} Lukasiewicz

2. r-implications

fir ( A( x), B ( y )) = sup[c ∈ [0 ,1] | A( x) t c ≤ B( y )] ∀( x , y ) ∈ X × Y

t = min

1 if A( x) ≤ B ( y )
f g ( A( x), B ( y )) =  Gödel
 B( y ) A( x) > B( y )

Pedrycz and Gomide, FSE 2007


Semantics of gradual rules
the more X is A, the more Y is B ⇒ B(y) ≥ A(x) ∀x∈X and ∀y∈Y

B(y)
1.0 1.0

A(x)

BRd
x y

BRd = {y∈Y |B(y) ≥ A(x)} for each x∈X

Pedrycz and Gomide, FSE 2007


Example: Rd = fa = Gaines
1 if B ( y ) ≥ A( x)
Rd ( x, y ) = 
0 otherwise

(a) Gradual rule Rd = fa

0.8

0.6

0.4

0.2

0
1
B(y) 1
0.8 A(x)
0.5 0.6
0.4
0.2
0 0

Rd(x,y) Rd (x,y)
∀ (A(x), B(y))∈[0,1]2 A(x) = A(x,3,5,7)
B(y) = B(y,3,5,7)
Pedrycz and Gomide, FSE 2007
Main types of rule bases

• Fuzzy rule base ≡ {R1, R2,....,RN} ≡ finite family of fuzzy rules

• Fuzzy rule base can assume various formats:

1. fuzzy graph

Ri: If X is Ai then Y is Bi is a fuzzy granule in X×Y, i = 1,...,N

2. fuzzy implication rule base

Ri: If X is Ai then Y is Bi is fuzzy implication, i = 1,...,N

3. functional fuzzy rule base

Ri: If X is Ai then y = fi(x) is a functional fuzzy rule, i = 1,...,N

Pedrycz and Gomide, FSE 2007


Fuzzy graph

• Fuzzy rule base R ≡ collection of rules R1, R2,....,RN

• Each fuzzy rule Ri is a fuzzy granule (point)

• Fuzzy graph ≡ R is a collection of fuzzy granules

• granular approximation of a function


N N
R = U Ri = U ( Ai × Bi )
i =1 i =1

• R = R1 or R2 or....or RN

• general form
N
R( x, y ) = S [ Ai ( x)tBi ( y )]
i=1

Pedrycz and Gomide, FSE 2007


Point

(a) (b)
10 10

8 8

6 6
y P
4 B 4

2 2
Point P in X×Y
0 0
1 B(y) 0 0 2 4 6 8 x 10 P = A×B
(c) A is a singleton in X
1 B is a singleton in Y
A
A(x)

0
0 2 4 6 8 x 10

Pedrycz and Gomide, FSE 2007


Granule

(a) (b)
10 10

8 8
B G
6 6

y
4 4

2 2

0 0 Granule G in X×Y
1 B(y) 0 0 2 4 6 8 x 10

(c)
G = A×B
A is an interval in X
1
A
B is an interval in Y
A(x)

0
0 2 4 6 8 x 10

Pedrycz and Gomide, FSE 2007


Fuzzy granules ≡ fuzzy points

(a) (b) Fuzzy granule R


10 10

8 8 R
6 B 6

y
4 4

2 2

0 0
fuzzy granule R in X×Y
1 0 0 5 x 10
B(y)
(c)
R = A×B
A is a fuzzy set on X
1
A B is a fuzzy set on Y
A(x)

0
0 2 4 6 8 x 10

Pedrycz and Gomide, FSE 2007


Fuzzy rule base as a set fuzzy granules

(b) Fuzzy granules Ri


(a) 10
10
y
y 9

8 R1
8
B1 R2
7
B2
6 6 R3
B3
5 R4
B4
4 4 R5
B5
3
2
2

1
0
1 0 0
B(y)
0 1 2 3 4 5 6 7 8 9 x 10

(c)

A1 A2 A3 A4 A5

Ri = Ai×Bi

0
0 2 4 6 8 x 10

Pedrycz and Gomide, FSE 2007


Graph of a function f and its granular approximation R

(a) function y = f(x) (b)Granular approximation of y = f(x)


12 12

y
y

11

10 10

9
R1
Ri = Ai×Bi
8 8 R2
7

6 R3
6
R4
5
f
4 4 R5 R6
R7
3 R R8
2 2

1
0
0 2 4 6 8 10 x 12 1 2 3 4 5 6 7 8 9 10 11 x 12

f R

Pedrycz and Gomide, FSE 2007


Fuzzy rule base and fuzzy graph
Example 1
(b)Fuzzy rule base as a fuzzy graph (t = min)
10
y
9

7
R = Union Ri
6

0
0 1 2 3 4 5 6 7 8 9 x 10

Ri = Ai×Bi ⇒ Ri(x,y) = min [Ai(x), Bi(y)]

R = ∪ Ri ⇒ R(x,y) = max [Ri(x,y), i = 1,..., N ]


Pedrycz and Gomide, FSE 2007
Fuzzy rule base and fuzzy graph
Example 2
(d) Fuzzy rule base as a fuzzy graph (t = product)
10
y
9

7
R = Union Ri
6

0
0 1 2 3 4 5 6 7 8 9 x 10

Ri = Ai t Bi ⇒ Ri(x,y) = Ai(x) Bi(y)

R = ∪ Ri ⇒ R(x,y) = max [Ri(x,y), i = 1,..., N ]


Pedrycz and Gomide, FSE 2007
Fuzzy implication

• Fuzzy rule base R ≡ collection of rules R1, R2,....,RN

• Each fuzzy rule Ri is a fuzzy implication

• Fuzzy rule base R is a collection of fuzzy relations

• relation R is obtained using intersection


N N N
R = I Ri = I fi = I ( Ai ⇒Bi )
i =1 i =1 i =1

• R = R1 and R2 and....and RN

• general form
N
R = T fi ( Ai ( x) , Bi ( y ))
i=1

Pedrycz and Gomide, FSE 2007


Fuzzy rule as an implication

(a) (b) Lukasiewicz implication R


10 10

8 8

6 B 6
R

y
4 4

2 2

0
1 B(y) 0
0
0 2 4 6 8 x 10 fuzzy rule R in X×Y
(c) R = fl (A,B)
1 Lukasiewicz implication
A
A(x)

0
0 2 4 6 8 x 10

Pedrycz and Gomide, FSE 2007


Fuzzy rule base and fuzzy implication
Example 1a
(b) Fuzzy rule base as Lukasiewicz implication (t = min)
10

y
4

0
0 1 2 3 4 5 6 7 8 9 10
x

Ri = fl (A,B) ⇒ Ri(x,y) = min [1, 1 – Ai(x) + Bi(y)] Lukasiewicz implication

R = ∩ Ri ⇒ R(x,y) = min [Ri(x,y), i = 1,..., 5] min t-norm


Pedrycz and Gomide, FSE 2007
Fuzzy rule base and fuzzy implication
Example 1b
(b) Fuzzy rule base as Lukasiewicz implication (t = min)
10

y
4

0
0 1 2 3 4 5 6 7 8 9 10
x

Ri = fl (A,B) ⇒ Ri(x,y) = min [1, 1 – Ai(x) + Bi(y)] Lukasiewicz implication

R = ∩ Ri ⇒ R(x,y) = R1(x,y) tl R2(x,y) tl .... tl Ri(x,y) Lukasiewicz t-norm


Pedrycz and Gomide, FSE 2007
Fuzzy rule base and fuzzy implication
Example 2a
(b) Fuzzy rule base as Zadeh implication (t = min)
10

y
9

0
0 1 2 3 4 5 6 7 8 9 x 10

Ri = fz (A,B) ⇒ Ri(x,y) = max [1 – Ai(x), min(Ai(x), Bi(y)] Zadeh implication


R = ∩ Ri ⇒ R(x,y) = min [Ri(x,y), i = 1,..., 5] min t-norm

Pedrycz and Gomide, FSE 2007


Fuzzy rule base and fuzzy implication
Example 2b
(d) Fuzzy rule base as Zadeh implication (t = Lukasiewicz)
10

y
9

0
0 1 2 3 4 5 6 7 8 9 x 10

Ri = fz (A,B) ⇒ Ri(x,y) = max [1 – Ai(x), min(Ai(x), Bi(y)] Zadeh implication


R = ∩ Ri ⇒ R(x,y) = R1(x,y) tl R2(x,y) tl .... tl Ri(x,y) Lukasiewicz t-norm

Pedrycz and Gomide, FSE 2007


Data base

• Data base contains definitions of:


– universes
– scaling functions of input and output variables
– granulation of the universes membership functions

• Granulation
– granular constructs in the form of fuzzy points
– granules along different regions of the universes

• Construction of membership functions


– expert knowledge
– learning from data

Pedrycz and Gomide, FSE 2007


Granulation

X X

granular constructs in granules along different


the form of fuzzy points regions of the universes

Pedrycz and Gomide, FSE 2007


Fuzzy inference

• Basic idea of inference

(a)
12

x=a
y

ac
10
y = f (x)
8
y=b

b I

4 b = ProjY (ac ∩ f )
f

2

0
0 2 a 4 6 8 10 12
b = ProjY ( I )
x

Pedrycz and Gomide, FSE 2007


Inference involves operations with sets

(b)
12

x=A
y

10 Ac
y = f (x)
8
B = f (A) ={f (x), x∈A}

B = ProjY (Ac ∩ f )
I
4 B
c
f
2

A
0
0 2 a 4 b 6 8 10 x 12
B = ProjY ( I )

Pedrycz and Gomide, FSE 2007


Inference involving sets and relations

(a)
12

x is A
y

10 Ac
(x,y) is R
8
y is B

6
B
I
4
B = ProjY (Ac ∩ R )
R f
2

A
0
0 2 4 6 8 10 x 12
B = ProjY ( I )

Pedrycz and Gomide, FSE 2007


Fuzzy inference ands operations with fuzzy sets and relations

(b)
12
y

Ac
10

8
X is A (fuzzy set on X)
6 B
I
R
(X,Y) is R (fuzzy relation on X×Y)
Y is B (fuzzy set on Y)
4

f
2

2 4 6 8 10 x 12

B = ProjY (Ac ∩ R )

B ( y ) = sup { A( x )tR ( x , y )}
B = ProjY ( I ) ⇒ x∈X

Pedrycz and Gomide, FSE 2007


Fuzzy inference

• Compositional rule of inference

X is A
(X,Y) is R
Y is B

B = Ao R

X is A
(X,Y) is R
Y is AoR

Pedrycz and Gomide, FSE 2007


Fuzzy inference procedure

procedure FUZZY-INFERENCE (A, R) returns a fuzzy set


input : fuzzy relation: R
fuzzy set: A
local: x, y: elements of X and Y
t: t-norm

for all x and y do


Ac(x,y) ← A(x)
for all x and y do
I(x,y) ← Ac(x,y) t R(x,y)
B(y) ← supx I(x,y)
return B

Pedrycz and Gomide, FSE 2007


Example: compositional rule of inference

Pedrycz and Gomide, FSE 2007


Example: fuzzy inference with fuzzy graph

Pedrycz and Gomide, FSE 2007


11.5 Types of rule-based
systems and architectures

Pedrycz and Gomide, FSE 2007


Linguistic fuzzy models

P: X is A and Y is B input

R1: If X is A1 and Y is B1 then Z is C1


......................
Ri: If X is Ai and Y is Bi then Z is Ci rule base
.......................
RN: If X is AN and Y is BN then Z is CN

Z: Z is C output

• all fuzzy sets A, B, Ai,s and Bi,s are given


• rule and connectives (and, or) with known semantics
• membership function of fuzzy set C = ??

Pedrycz and Gomide, FSE 2007


min-max fuzzy models

Assume

P: X is A and Y is B P(x,y) = min{A(x), B(y)}

Ri: If X is Ai and Y is Bi then Z is Ci Ri(x,y,z) = min{Ai(x), Bi(y), Ci(z)}

i = 1,..., N

Using the compositional rule of inference (t = min)

N
C = P o R = P o U Ri
i =1

C ( z ) = sup{min[ P ( x , y ), max( Ri ( x , y , z ), i = 1,...,N )]}


x ,y

Pedrycz and Gomide, FSE 2007


N N N
C = P o R = P o U Ri = U ( P o Ri ) = U Ci′
i =1 i =1 i =1

Ci′ = P o Ri

Ci′ ( z ) = sup{min[ P ( x , y ), Ri ( x , y , z )]} = sup{ A( x) ∧ B ( y ) ∧ Ai ( x) ∧ Bi ( y ) ∧ Ci ( z )]}


x ,y x ,y
sup[ A( x) ∧ Ai ( x)] = Poss( A, Ai ) = mi
x
sup[ B ( y ) ∧ Bi ( y )] = Poss( B , Bi ) = ni
y
Ci′ ( z ) = mi ∧ ni ∧ Ci ( z )

C ( z ) = max{( mi ∧ ni )Ci ,i = 1,K , N } = max{λi ∧ Ci ( z ), i = 1,K , N }

λi is the degree of activation of i − th rule

Pedrycz and Gomide, FSE 2007


min-max fuzzy model processing

procedure MIN-MAX-MODEL (A,B) returns a fuzzy set


local: fuzzy sets: Ai, Bi, Ci, i =1,.., N
activation degrees: λi

Initialization C = ∅

for i = 1: N do
mi = max (min (A, Ai))
ni = max (min (B, Bi))
λi = min (mi, ni)
if λi ≠ 0 then Ci’ = min (λi , Ci) and C = max(C, Ci’)
return C

Pedrycz and Gomide, FSE 2007


Example: min-max fuzzy model processing

Ai Aj A Bi B Bj Ci Cj
1 1 1
mj
nj Cj’
nj
ni Ci’
mi mi

x y z

Pedrycz and Gomide, FSE 2007


min-max fuzzy model architecture

A1,B1 C1

Poss λ1 Min C1’

Ai,Bi Ci

C
(A,B) Poss λi Min Max
Ci’

AN,BN CN

Poss λN Min CN’

Pedrycz and Gomide, FSE 2007


Special case: numeric inputs

1 if x = xo 1 if y = yo
A( x) =  and B ( y ) = 
0 otherwise 0 otherwise

Numeric output

∫ zC ( z )dz
z= Z centroid defuzzification
∫Z C ( z )dz

N
∑ (mi ∧ ni )vi
z = i =1 weighted average modal values vi
N
∑ (mi ∧ ni )
i =1

Pedrycz and Gomide, FSE 2007


Example
P: X is xo and Y is yo inputs (xo, yo), ∀xo, yo ∈[-2, 2]

R1: If X is A1 and Y is B1 then Z is C1


rules
R2: If X is A2 and Y is B2 then Z is C2

N = 2, centroid defuzzification

(a) Input and output fuzzy sets (b) Input-output mapping


1 A1 A2
Ai(x)

0.5
0.5
0

z
-2 -1.5 -1 -0.5 0 0.5 1 1.5 x 2
0
B2 B2
1

-0.5
Bi(y)

0.5

0 -2
-2 -1.5 -1 -0.5 0 0.5 1 1.5 y 2
y
C1 C2 -1
1
0
Ci(z)

0.5
x -2
1 -1
0
0 1
-2 -1.5 -1 -0.5 0 0.5 1 1.5 z 2 2
2

Pedrycz and Gomide, FSE 2007


min-sum fuzzy models

Assume

P: X is A and Y is B P(x,y) = min{A(x), B(y)}

Ri: If X is Ai and Y is Bi then Z is Ci Ri(x,y,z) = min{Ai(x), Bi(y), Ci(z)}

i = 1,..., N

Using the compositional rule of inference (t = min)

Ci′ ( z ) = sup[ A( x ) ∧ B ( y ) ∧ Ai ( x) ∧ Bi ( y ) ∧ Ci ( z )]
x ,y
Additive fuzzy models
N (Kosko, 1992)
C ( z) = ∑ wiCi′
i =1

Pedrycz and Gomide, FSE 2007


Example: min-sum fuzzy model processing

Ai Aj A Bi B Bj Ci Cj
1 1 1
mj ∑Ci’
nj nj
ni Ci’ Cj’
mi mi

x y z

Pedrycz and Gomide, FSE 2007


min-sum fuzzy model architecture

A1,B1 C1

Poss λ1 Min C1’

Ai,Bi Ci w1

wi C
(A,B) Poss λi Min ∑
Ci’

AN,BN CN
wN

Poss λN Min CN’

Pedrycz and Gomide, FSE 2007


Example
P: X is xo and Y is yo inputs (xo, yo), ∀xo, yo ∈[-2, 2]

R1: If X is A1 and Y is B1 then Z is C1


rules
R2: If X is A2 and Y is B2 then Z is C2

N=2 w1 = w2 = 1, centroid defuzzification

(a) Input and output fuzzy sets (b) Input-output mapping

1 A1 A2
Ai(x)

0.5
0.5
0

z
-2 -1.5 -1 -0.5 0 0.5 1 1.5 x 2
0
1
B2 B2

-0.5
Bi(y)

0.5

0 -2
-2 -1.5 -1 -0.5 0 0.5 1 1.5 y 2
y
C1 C2 -1
1
0
Ci(z)

0.5
x -2
1 -1
0
0 1
-2 -1.5 -1 -0.5 0 0.5 1 1.5 z 2 2
2

Pedrycz and Gomide, FSE 2007


product-sum fuzzy models

1- Product–probabilistic sum (b) Input-output mapping of product-probabilistic sum model

Ci′ ( z ) = mi ni Ci ( z ) 0.5

z
0

-0.5

N
C ( z ) = S p Ci′ ( z ) -2
y

i =1
-1

x -2
1 -1
0
2 1
2

2- Product–sum (d) Input-output mapping of product-sum model

0.5

Ci′ ( z ) = mi ni Ci ( z )
z
0

-0.5

N -2

C ( z ) = ∑ Ci′ ( z )
y
-1

i =1 0

x -2
1 -1
0
2 1
2

Pedrycz and Gomide, FSE 2007


3 - Bounded product-bounded sum

Ci′ ( z ) = mi ⊗ ni ⊗ Ci ( z )
(c) Input-output mapping of bounded product-bounded sum model

1
N

z
C ( z ) = ⊕ Ci′ ( z )
0.5

i =1 0

-0.5

a ⊗ b = max{0 , a + b − 1} -1

-2
y

a ⊕ b = min{1, a + b} -1

0
-2
1 -1 x
a,b ∈ [0 ,1] 2 1
0
2

Pedrycz and Gomide, FSE 2007


Functional fuzzy models

P: X is x and Y is y input

R1: If X is A1 and Y is B1 then z = f1 (x,y)


......................
Ri: If X is Ai and Y is Bi then z = fi (x,y) rule base
.......................
RN: If X is AN and Y is BN then z = fN (x,y)

λi(x,y) = Ai(x) t Bi(y) t = t-norm degree of activation

N λi
z = ∑ wi ( x , y ) fi ( x , y ) , wi =
N output
i =1
∑ λi ( x , y )
i =1

Pedrycz and Gomide, FSE 2007


Functional fuzzy model architecture

A1,B1 f1(x,y)

w1
⊗ ×

Ai,Bi f2(x,y)

wi z
(x,y) ⊗ × ∑

AN,BN fN(x,y)

wN
⊗ ×

Pedrycz and Gomide, FSE 2007


Example 1
P: X is x inputs x ∈ [0, 3]

R1: If X is A1 then z = x
rules
R2: If X is A2 then z = – x + 3

(a) Antecedent fuzzy sets (b) Consequent functions


1.2 3
Ai

A1 A2

y
1 2.5

0.8 2 f2 f1

0.6 1.5

0.4 1

0.2 0.5

0 0
0 0.5 1 1.5 2 2.5 x 3 0 0.5 1 1.5 2 2.5 x 3

Pedrycz and Gomide, FSE 2007


x if x ∈ (0 ,1]

z =  A1 ( x) x + A2 ( x)(− x + 3) if x ∈ [1,2]
− x + 3 if x ∈ [2 ,3)

(b) Output of the functional model


2
y

1.8

1.6

1.4

1.2

1
output
0.8

0.6

0.4

0.2

0
0 0.5 1 1.5 2 2.5 x 3

Pedrycz and Gomide, FSE 2007


Example 2
P: X is x inputs x ∈ [0, 3]

R1: If X is A1 then y = – sin(2x)

R2: If X is A2 then y = – 0.5x rules

R3: If X is A3 then y = sin(3x)


output
(a) Antecedent fuzzy sets (b) output of the func tional fuzzy model
1.2 1.5

y y
A1 A2 A3
1 1

0.8 0.5

0.6 0

0.4 -0.5

0.2 -1

0 -1.5
-5 -4 -3 -2 -1 0 1 2 3 4 x 5 -5 -4 -3 -2 -1 0 1 2 3 4 x 5

Pedrycz and Gomide, FSE 2007


Example 2
P: X is x inputs x ∈ [0, 3]

R1: If X is A1 then y = – 1

R2: If X is A2 then y = x rules

R3: If X is A3 then y = 1
output
(a) Antecedent fuzzy sets (c) output of the functional fuzzy model
1.2 1.5

y
y
A1 A2 A3
1 1

0.8 0.5

0.6 0

0.4 -0.5

0.2 -1

0 -1.5
-5 -4 -3 -2 -1 0 1 2 3 4 x 5 -5 -4 -3 -2 -1 0 1 2 3 4 x 5

Pedrycz and Gomide, FSE 2007


Gradual fuzzy models

Ri: The more X is Ai the more Z is Ci

i = 1,..., N

1 if Ci ( z ) ≥ Ai ( x)
Ri ( x, y ) = 
0 otherwise

N N
C = I (Ci′ ) αi = I Cαi
i =1 i =1

Pedrycz and Gomide, FSE 2007


Gradual fuzzy model architecture

A1 C1

Poss α1 Cα1 C1’

Ai Ci

C
x Poss αi Cα1 Min
Ci’

AN CN

Poss αN Cα1 CN’

Pedrycz and Gomide, FSE 2007


Example: gradual fuzzy model processing

A1 A2 C1 C2
1 1
α1 α1
C1’ C2’
α2 α2
x z

Pedrycz and Gomide, FSE 2007


Example
P: X is x inputs x ∈ [0, 3]

R1: The more X is A1 the more Z is C1


rules
R2: The more X is A1 the more Z is C1

output
4
A1 A2
1

z
0.8
3.5
0.6
Ai

0.4
0.2 3

0
1 1.5 2 2.5 3 3.5 x 4
2.5

C1 C2
1 2
0.8
0.6
Ci

1.5
0.4
0.2
0 1
1 1.5 2 2.5 3 3.5 z 4 1 1.5 2 2.5 3 3.5 x 4

Pedrycz and Gomide, FSE 2007


11.6 Approximation properties
of fuzzy rule-based models

Pedrycz and Gomide, FSE 2007


• FRBS uniformly approximates continuous functions
– any degree of accuracy
– closed and bounded sets

• Universal approximation with (Wang & Mendel, 1992):


– algebraic product t-norm in antecedent
– rule semantics via algebraic product
– rule aggregation via ordinary sum
– Gaussian membership functions
– sup-min compositional rule of inference
– pointwise inputs
– centroid defuzzification

Pedrycz and Gomide, FSE 2007


• Universal approximation when (Kosko, 1992):
– min t-norm in antecedent
– rule aggregation via ordinary sum
– symmetric consequent membership functions
– sup-min compositional rule of inference
– pointwise inputs
– centroid defuzzification

(additive models)

Pedrycz and Gomide, FSE 2007


• Universal approximation with (Castro, 1995):
– arbitrary t-norm in antecedent
– rule semantics: r-implications or conjunctions
– triangular or trapezoidal membership functions
– sup-min compositional rule of inference
– pointwise inputs
– centroid defuzzification

Pedrycz and Gomide, FSE 2007


11.7 Development of rule-based
systems

Pedrycz and Gomide, FSE 2007


Expert-based development

• Knowledge provided by domain experts


– basic concepts and variables
– links between concepts and variables to form rules

• Reflects existing knowledge


– can be readily quantified
– short development time

Pedrycz and Gomide, FSE 2007


Example: fuzzy control

+ e Fuzzy u y
r Process
− Controller

Ri: If Error is Ai and Change of Error is Bi then Control is Ci

Ri: If e is Ai and de is Bi then u is Ci

Pedrycz and Gomide, FSE 2007


Ri: If e is Ai and de is Bi then u is Ci

r
e

t
Change of Error (de) / Error (e) NM NS ZE PS PM
NB PM NB NB NB NM
NM PM NB NS NM NM
NS PM NS Z NS NM
Z PM NS Z NS NM
PS PM PS Z NS NM
PM PM PM PS PM NM
PB PM PM PM PM NM

Pedrycz and Gomide, FSE 2007


Data-driven development

• Given a finite set of input/output pairs


{(xk, yk), k = 1,..., M}
xk = [x1k, x2k,...., xnk] ∈Rn
zk = [xk, yk] ∈Rn+1, k = 1,..., M

• Clustering zk = [xk, yk] ∈Rn+1, k = 1,..., M (e.g. using FCM)


v1, v2,....,vN prototypes/cluster centers
vi ∈ Rn+1, i = 1,..., N

• Idea: fuzzy clusters ≡ fuzzy rules

Pedrycz and Gomide, FSE 2007


Example
R3 R2

v3 v2

R4 R1
v4 v1

Pedrycz and Gomide, FSE 2007


• Projecting the prototypes in the input and output spaces

v1[y], v2[y],....,vN [y] projections of prototypes in Y

v1[x], v2[x],....,vN [x] projections of prototypes in X

• Ri: If X is Ai then Y is Ci, i = 1,..., N

y y y

x x x

Pedrycz and Gomide, FSE 2007


11.8 Parameter estimation for
functional rule-based
systems

Pedrycz and Gomide, FSE 2007


• Functional fuzzy rules

• Ri: If Xi1 is Ai1 and ... and Xin is Ain then z = aio + ai1x1 + ....+ ainxn
i = 1,..., N

• Given input/output data: {(x1, y1), (x2, y2),....,(xM, yM)}

• Let ai = [aio, ai1, ai2,...., ain]T

• Output of functional models


N λi ( xk )
ŷk = ∑ wik fi (x k ,ai ) , wik =
N
i =1
∑ λi ( xk )
i =1
• Output for linear consequents
N
ŷk = Ta , z ik = [1, wik x T T
∑ z ik i k]
i =1

Pedrycz and Gomide, FSE 2007


Let

 a1   a1 

[ ]
a  a 
a= 2 ŷk = z1Tk zT
2k L z Nk  2 
T
 M   M 
a  a 
 N  N

and

 ŷ1   zT T
z12 L z TN1 
 ŷ   11 
T
 z12 zT L zN2T 
y= 2  Z = 22

 M 
 ŷ   M M O M 
 M z T zT L z TNM 
 1M 2M

then y = Za

Pedrycz and Gomide, FSE 2007


Global least squares approach

Mina JG(a) = || y – Za||2

|| y – Za||2 = (y – Za)T (y – Za)

Solution

aopt = Z# y

Z# = (ZT)–1ZT

Pedrycz and Gomide, FSE 2007


Local least squares approach
N
Min a J L (a) = ∑ y − Zi ai 2
i =1

 zT 
 i1 
 T 
z
Zi =  i 2 
 M 
T 
z iM 

Solution

aiopt = Zi# y

Zi# = (ZiT)–1ZiT

Pedrycz and Gomide, FSE 2007


11.9 Design issues of FRBS:
Consistency and
completeness

Pedrycz and Gomide, FSE 2007


Given input/output data: {(x1, y1), (x2, y2),....,(xM, yM)}

consistency
data completeness
accuracy

rules

Issue: quality of the rules

Pedrycz and Gomide, FSE 2007


Completeness of rules

• All data points represented through some fuzzy set


maxi = 1,..., M Ai(xk) > 0 for all k = 1,2,..., M

• Input space completely covered by fuzzy sets


maxi = 1,..., M Ai(xk) > δ for all k = 1,2,..., M

Pedrycz and Gomide, FSE 2007


Consistency of rules

• Rules in conflict
– similar or same conditions
– completely different conclusions

Conditions and Similar Different


Conclusions Conclusions Conclusions

rules are in
Similar Conditions rules are redundant
conflict

different rules;
Different
could be eventually different rules
Conditions
merged

Pedrycz and Gomide, FSE 2007


Ri: If X is Ai then Y is Bi
Rj: If X is Aj then Y is Bj

M
cons(i , j ) = ∑{| Bi ( yk ) − B j ( yk ) | ⇒ | Ai ( xk ) − A j ( xk ) |}
i =1

Alternatively

M
cons(i , j ) = ∑{Poss( Ai ( xk ) , A j ( xk )) ⇒ Poss( Bi ( yk ) , B j ( yk ))}
i =1

⇒ is an implication induced by some t-norm (r-implication)

1 M
cons(i ) = ∑ cons(i , j )
M j =1

Pedrycz and Gomide, FSE 2007


11.10 The curse of dimensionality
in rule-based systems

Pedrycz and Gomide, FSE 2007


• Curse of dimensionality
– number of variables increase
– exponential growth of the number of rules

• Example
– n variables
– each granulated using p fuzzy sets
– number of different rules = pn

• Scalability challenges

Pedrycz and Gomide, FSE 2007


11.11 Development scheme of
fuzzy rule-based models

Pedrycz and Gomide, FSE 2007


• Spiral model of development
– incremental design, implementation and testing
– multidimensional space of fundamental characteristics

Accuracy
Stability

Knowledge
Interpretability Representation

Pedrycz and Gomide, FSE 2007

You might also like