You are on page 1of 40

INTELLIGENT SYSTEMS (EK406)

Lecture#6
Fuzzy Relations & Compositions

Dr Mahmud Iwan S

SCHOOL OF ENGINEERING
UCSI UNIVERSITY
~EK406 DrMIS~
Outlines

Introduction
Fuzzy Relations
Fuzzy Compositions

~EK406 DrMIS~
Introduction

Basic Concept
Mathematically, a relation implies the presence of an
association between elements of different sets (at least
two fuzzy sets).

Binary relation is a relation between two sets.


Tertiary relation is a relation between three sets.
n-ary relation is a relation between n elements

We discuss only binary relations.

~EK406 DrMIS~
Introduction

Basic Concept

On what basis do we associate various elements in a


relation?

The relation may be due to a common property, a


quality, a reference, a condition or a rule such as:
is greater than, is a member of, is a friend of etc.

~EK406 DrMIS~
Introduction

Classical Relation
Relations are basic notion in engineering and
science which is essentially the discovery of relation
between observations and variables.
Classical relations are structure that represent the
presence or absence of correlation or interaction
among various sets.
Two degrees of relationship in a crisp relations:
Completely related
Not related

~EK406 DrMIS~
Introduction

Classical Relation
The strength of this relationship is measured by
characteristic function as follows:

1, ( x, y ) XxY
XxY ( x , y ) =
0, ( x, y ) XxY
=1, is associated with complete relationship
=0, is associated with no relationship

~EK406 DrMIS~
Introduction

Classical Relation
A binary relation is a classical relation between two sets X
and Y denoted by R(X,Y).

A binary fuzzy relation can be expressed such as by:

By listing the set of all ordered pairs

Matrix relation R

~EK406 DrMIS~
Introduction

Classical Relation
Example
Let ={Adam, Bernhard, Charles} and ={Diana, Eva,
Francisca}, then the relation married to on is for
example:

{(Adam, Eva), (Bernhard, Francisca), (Charles, Diana)}

By listing the set of all ordered pairs

~EK406 DrMIS~
Introduction

Classical Relation
Example of classical relation representation:
Let X={Adam, Bernhard, Charles} and Y={Diana, Eva,
Francisca}, then the relation married to on is for
example D E F

A 0 1 0


B 0 0 1
R=
C
1 0 0
Matrix relation

~EK406 DrMIS~
Fuzzy Relations

Basic Concept
Fuzzy relation is based on the philosophy that
everything is related to some extend or unrelated.
Unlike crisp relations, the strength of the relation
between ordered pair of two universes is not
measured with the characteristic function, but rather
with a membership function expression expressing
various degree of strength of the relation on the unit
interval [0,1].
Crisp relations and fuzzy relations can be defined in
terms of subsets.

~EK406 DrMIS~
Fuzzy Relations

Example 1
Let X={x1,x2}={NYC, TKO} and Y= ={y1,y2}={TPE, HKG, BJI}.
Let R represent the relation very close.

Crisp relation
y1 y2 y3
x1 0 0 0
x2 1 1 1 ?
~EK406 DrMIS~
Fuzzy Relations

~EK406 DrMIS~
Fuzzy Relations

~EK406 DrMIS~
Fuzzy Relations
Example 1
Let X={x1,x2}={NYC, TKO} and Y= ={y1,y2}={TPE, HKG, BJI}.
Let R represent the relation very close.
Fuzzy relation
y1 y2 y3
x1 0.3 0.1 0.1
x2 1 0.7 0.8

How to represent a fuzzy relation?


~EK406 DrMIS~
Fuzzy Relations

Fuzzy relation representation

A binary fuzzy relation is a fuzzy relation between two sets


X and Y denoted by R(X,Y).

A binary fuzzy relation can be expressed such as by:

listing the set of all ordered pairs


matrix relation R

~EK406 DrMIS~
Fuzzy Relations

Fuzzy relation representation


We can list all pairs of the relation explicitly as

R = {((x , y ), R (x , y ))}
or
R (x i , y i )
R= For discrete
( x i , y i )XY (x i , y i )

R (x i , y i ) For continuous
R=
X Y
(x i , y i )
~EK406 DrMIS~
Fuzzy Relations

Example 1
Let X={x1,x2}={NYC, TKO} and Y= ={y1,y2}={TPE, HKG, BJI}.
Let R represent the relation very close.

Fuzzy relation
y1 y2 y3
R( X , Y ) = .... ? by listing ordered pair
x1 0.3 0.1 0.1
x2 1 0.7 .8

~EK406 DrMIS~
Fuzzy Relations

Example 1
Let X={x1,x2}={NYC, TKO} and Y= ={y1,y2}={TPE, HKG, BJI}.
Let R represent the relation very close.

0.3 0.1 0.1


R( X , Y ) = + +
NYC , TPE NYC , HKG NYC , BJI
1 0.7 0.8
+ + +
TKO, TPE TKO, HKG TKO, BJI
~EK406 DrMIS~
Fuzzy Relations

Fuzzy relation representation


Let X={x1,x2,, xn} and Y={y1,y2 ,, ym}

R ( x1 , y1 ) R ( x1 , y 2 ) L R ( x1 , y m )
( x , y ) ( x , y )
L R ( x2 , y m )
R 2 1 R 2 2
R( X , Y ) =
M M O M
R ( xn , y1 ) R ( xn , y 2 ) L R ( xn , y m )
Matrix Relation

~EK406 DrMIS~
Fuzzy Relations

Example 2
Let X={x1,x2}={NYC, TKO} and Y= ={y1,y2}={TPE, HKG, BJI}.
Let R represent the relation very close.

Fuzzy relation
y1 y2 y3
x1 0.3 0.1 0.1 R( X , Y ) = .... ? by matrix relation R

x2 1 0.7 .8

~EK406 DrMIS~
Fuzzy Relations

Some special relations


The identity fuzzy relation, RI, is a special type of relation
which has 1 in all diagonal elements and 0 in off-diagonal
elements:
1 0 L 0
0
1 L 0
RI =
M M O M
0 0 L 1

~EK406 DrMIS~
Fuzzy Relations

Some special relations


The universe relation, RE, is a special type of relation
which has degree of membership 1 in everywhere:

1 1 L 1
1
1 L 1
RE =
M M O M
1 1 L 1

~EK406 DrMIS~
Fuzzy Relations

Some special relations


The null relation, R0, is a special type of relation which
has degree of membership 0 in everywhere:

0 0 L 0
0
0 L 0
RE =
M M O M
0 0 L 0

~EK406 DrMIS~
Fuzzy Relations

Some special relations

The Cartesian Product between fuzzy sets A and B will


result in a fuzzy relation R,
R : AxB [0,1]
Where the fuzzy relation R has membership function:

R ( x, y ) = AxB ( x, y ) = min( A ( x), B ( y ) )

~EK406 DrMIS~
Fuzzy Relations

Example 3:
Consider two fuzzy sets A and B given below, determine the
Cartesian product between these sets.

0.2 0.9 0.3 0.5 1


A= + B= + +
x1 x2 y1 y 2 y3

~EK406 DrMIS~
Fuzzy Relations
Exercise: (T.J. Ross, page 60)
Suppose we have two fuzzy sets, T defined on a universe of
three discrete temperature, X={x1,x2,x3), and P defined on a
universe of two discrete pressures, Y={y1,y1}. Let say, T
represent ambient temperature and P the near optimum
pressure and the Cartesian Product might represent the
efficient condition of operation. Find the efficient condition ?

0.2 0.5 1 0.3 0.9


T= + + P= +
x1 x2 x3 y1 y2
~EK406 DrMIS~
Fuzzy Compositions

Introduction
Let R be a relation that relates, or maps elements from
universe X to universe Y, and let S be another relation that
relates elements from universe Y to universe Z.

Is it possible to find the relation T that relates the same


element in universe X to the elements in universe Z?

~EK406 DrMIS~
Fuzzy Compositions
X Y Y Z

x1 y1 y1
x2 y2 y2 z1

x3 y3 y3 z2
y4 y4

R S

T??

~EK406 DrMIS~
Fuzzy Compositions

X Z

x1 y1 y1
x2 y2 y2 z1

x3 y3 y3 z2
y4 y4

T??

~EK406 DrMIS~
Fuzzy Compositions
Composition is very important for differencing procedure
used in linguistic description and is particularly useful in
fuzzy control and expert system as we shall discuss in next
classes.
There are several type compositions as
Max-min composition (most common in application)
Min-max composition
Max-product composition
Max-average composition
The computation of fuzzy composition is like a matrix
multiplication with replacement as:
for example max-min composition, sum is replaced by
max and product is replaced by min operator.
~EK406 DrMIS~
Fuzzy Compositions

Max-
Max-min Composition
Suppose we have two fuzzy relations R1(x,y) and R2(y,z)
defined over the Cartesian product.

The max-min composition of R1 and R2 is a new relation


R1R2 defined on XxZ as

[
R1 ( x, y ) R2 ( y, z ) ]

y
R1 o R2
X Z
( x, z )

~EK406 DrMIS~
Fuzzy Compositions

Max-
Max-min Composition

Therefore, we see that the grade of membership of each


(x,z) pair in the new relation is

R o R ( x, z ) = [ R ( x, y ) R ( y, z )]
1 2 1 2
y

~EK406 DrMIS~
Fuzzy Compositions

Min-
Min-max Composition
Suppose we have two fuzzy relations R1(x,y) and R2(y,z)
defined over the Cartesian product.

The min-max composition of R1 and R2 is a new relation


R1R2 defined on XxZ as

[
R1 ( x, y ) R2 ( y, z ) ]

y
R1 R2
X Z
( x, z )

~EK406 DrMIS~
Fuzzy Compositions

Max-
Max-product Composition
Suppose we have two fuzzy relations R1(x,y) and R2(y,z)
defined over the Cartesian product.

The max-product composition of R1 and R2 is a new


relation R1R2 defined on XxZ as

[
R1 ( x, y ) R2 ( y, z ) ]

y
R1 R2
X Z
( x, z )
~EK406 DrMIS~
Fuzzy Compositions

Max-
Max-product Composition

Therefore, we see that the grade of membership of each


(x,z) pair in the new relation is

R R ( x, z ) = [ R ( x, y ) R ( y, z )]
1 2 1 2
y

~EK406 DrMIS~
Fuzzy Compositions
Max-
Max-average Composition
Suppose we have two fuzzy relations R1(x,y) and R2(y,z)
defined over the Cartesian product.

The max-average composition of R1 and R2 is a new


relation R1<+>R2 defined on XxZ as

1
(
R1 ( x, y ) + R2 ( y, z ) )
R1 + R2
y 2

X Z
( x, z )
~EK406 DrMIS~
Fuzzy Compositions

Max-
Max-average Composition

Therefore, we see that the grade of membership of each


(y,z) pair in the new relation is

1
( )
R1 + R 2 (x , z ) R1 ( x , y) + R 2 ( y, z)

y 2

~EK406 DrMIS~
Fuzzy Compositions
Example 4
Let X={Peter, Mary, John} represents students who plan to take four
courses (Z) offered based on their preferences for Y={y1,y2,y3,y4}={theory,
application, hardware, programming}.
Z={Fuzzy Theory, Fuzzy Control, Neural Network, Expert System}.
Assume the students interests is represented by the fuzzy relation P(X,Y).
The properties of the course are indicated by the fuzzy relation Q(Y,Z}.
Use max-min composition to make decision.

0.2 1 0.8 0.1 1 0 .5 0.6 0.1


0.2 1 0.8 0.8
P(X, Y) = 1 0.1 0 0.5
Q(Y, Z) =
0.5 0.9 0.5 1 0 0.3 0.7 0
0.1 0.5 0.8 1

~EK406 DrMIS~
Fuzzy Compositions

Example 5

1.0 0.3 0.9 0.0 1.0 1.0 0.9


0.3 1.0 0.8 1.0 1.0
0.0 0.5
R1 = R2 =
0.9 0.8 1.0 0.8
0.3 0.1 0.0
0.0 1.0 0.8 1.0 0.2 0.3 0.1

Find the max-min composition!

~EK406 DrMIS~
Fuzzy Compositions
Exercise
0.9 0.0 0.3 0.4
0.2 1.0 0.8 0.0
0.1 0.2 0.0 1.0 0.7
R = 0.8
R 1 = 0.3 0.5 0.0 0.2 1.0 2 0.0 0.7 1.0
0.8 0.0 1.0 0.4 0.3 0.4 0.2 0.3 0.0

0.0 1.0 0.0 0.8
Find the max-min composition, max-product composition, max-
average composition.

~end~
~EK406 DrMIS~

You might also like