Module 4
Module 4
Fuzzy Sets
1
Module 4
• Introduction
• Fuzzy set operations
• Fuzzy relations
• Fuzzy membership functions
• Fuzzification
• Defuzzification
FUZZY LOGIC
Fuzzy logic is the logic underlying approximate, rather than exact, modes of
reasoning.
It contains as special cases not only the classical two-value logic and
multivalue logic systems, but also probabilistic logic.
3
FUZZY LOGIC
Boolean logic uses sharp distinctions.
4
NEED OF FUZZY LOGIC
Based on intuition and judgment.
5
CLASSICAL SETS (CRISP SETS)
{True, False}
{1, 0}
6
OPERATIONS ON CRISP SETS
UNION:
INTERSECTION:
COMPLEMENT:
DIFFERENCE:
7
PROPERTIES OF CRISP SETS
The various properties of crisp sets are as follows:
8
PROPERTIES OF CRISP SETS
9
CHARACTERISTIC FUNCTION FOR SETS
• EXAMPLE:
• Let U = {1, 2, ….10} and A = {1, 3, 5, 7, 9}.
• Then
• A (3) 1 and A (4) 0.
FUZZY SETS
11
FUZZY SETS
• The ‘+’ , ‘/’ and ' ' symbols have not been used with their
usual meanings, these are only representational.
17
Operation on Fuzzy sets
18
Operation on Fuzzy sets
19
PROPERTIES OF FUZZY SETS
20
PROPERTIES OF FUZZY SETS
21
Problem :1
Consider two given fuzzy sets
22
Problem 2
Problem 3
Consider two fuzzy set
A(x)={(x1,0.1),(x2,0.2),(x3,0.3),(x4,0.4)}
B(x)={(x1,0.5),(x2,0.7),(x3,0.8),(x4,0.9)}
24
The Algebraic product
The Algebraic product of two fuzzy sets A(x) and
B(x) for all x ∈ X, is denoted by A(x).B(x) and
defined as follows
A(x).B(x) = {(x, μA(x).μB(x)), x ε X }
Example
A(x) = {(x1,0.1),(x2,0.2),(x3,0.3),(x4,0.4)}
B(x) = {(x1,0.5),(x2,0.7),(x3,0.8),(x4,0.9)}
A(x).B(x) = (x1,0.05),(x2,0.14),(x3,0.24),(x4,0.36)}
25
Algebraic sum of two fuzzy sets
μA+B(x) = μA(x)+μB(x) - μA(x).μB(x)
A(x)={(x1,0.1),(x2,0.2),(x3,0.3),(x4,0.4)}
B(x)={(x1,0.5),(x2,0.7),(x3,0.8),(x4,0.9)}
Now (x)+B(x) =
{(x1,0.55),(x2,0.76),(x3,0.86),(x4,0.94)}
26
Bounded sum
A(x)={(x1,0.1),(x2,0.2),(x3,0.3),(x4,0.4)}
B(x)={(x1,0.5),(x2,0.7),(x3,0.8),(x4,0.9)}
Ans :{(x1,0.6),(x2,0.9),(x3,1.0),(x4,1.0)}
Bounded difference
A(x)={(x1,0.1),(x2,0.2),(x3,0.3),(x4,0.4)}
B(x)={(x1,0.5),(x2,0.7),(x3,0.8),(x4,0.9)}
Ans ::{(x1,0),(x2,0),(x3,0),(x4,0)}
Classical Relation and Fuzzy
Relation
RELATIONS
Relations represent mappings between sets and connectives in logic.
1, if ( x, y) R,
R ( x, y )
0, if ( x, y ) R.
The constrained cartesion product for sets when r=2(AxA) is called
Identity relation
Unconstrained cartesion product for set when r =2 is called universal
relation
Consider set A={2,4,6}
Identity relation ={(2,2)(4,4)(6,6)
Universal relation= {(2,2)(2,4)(2,6),(4,2),(4,4)(4,6),(6,2),(6,4),(6,6)}
SPECIAL RELATIONS
0 0 0 0 1 1 1 1
0 0 0 0 1 1 1 1
O E
0 0 0 0 1 1 1 1
0 0 0 0 1 1 1 1
• Since relations are sets their union, intersection and complements
are defined just as for sets
COMPOSITION OF RELATIONS
• (max-min) T ( x, z ) ( R ( x, y) R ( y, z ))
yY
• (max-product) T ( x, z ) ( R ( x, y) R ( y, z ))
yY
EXAMPLE
• Let X = {x1, x2, x3}, Y = {y1, y2, y3, y4} and Z = {z1, z2}.
• R = { (x1, y1), (x1, y3), (x2, y4)}
• S = { (y1, z2), (y3, z2)}
• The relation matrices are given by
1 0 1 0 0 1
0 0 1
0 0 0
• R= 0 0 0 1
and S= . Then T =
0 1
0 0 0 0 0 0
0 0
T ( x1, z1) max[min(1, 0), min(0, 0), min(1, 0), min(0, 0)] = 0
T ( x1, z 2) max[min(1, 1), min(0, 0), min(1, 1), min(0, 0)] = 1
FUZZY RELATIONS
• Subrelation
RS iff R ( x, y ) S ( x, y )
PROPERTIES OF FUZZY RELATIONS
44
45
CLASSICAL TOLERANCE RELATION
46
FUZZY EQUIVALENCE RELATION
47
FUZZY TOLERANCE RELATION
A binary fuzzy relation that possesses the properties of
reflexivity and symmetry is called fuzzy tolerance relation or
resemblance relation.
48
Problem
• Consider the following two fuzzy sets:
0.3 0.7 1
𝐴= + +
𝑥1 𝑥2 𝑥3
0.4 0.9
𝐵= +
𝑦1 𝑦2
54
Characteristics Of Fuzzy Membership
Support
• The support of a membership function for some fuzzy set A is
defined as that region of the universe that is characterized by
nonzero membership in the set A.
CORE:
SUPPORT:
BOUNDARY:
Characteristics Of Fuzzy Membership
• A normal fuzzy set is one whose membership function has at
least one element x in the universe whose membership value is
unity.
58
CHARACTERISTICS OF FUZZY MEMBERSHIP
A convex fuzzy set is described by a membership function whose
membership values are strictly monotonically increasing, or
strictly monotonically decreasing, or whose membership values
are strictly monotonically increasing then strictly monotonically
decreasing with increasing values for elements in the universe.
59
FUZZIFICATION
Intuition
• It is simply derived from the capacity of human to develop
membership functions through their own innate intelligence
and understanding.
61
Inference
• In inference method we use knowledge to
perform deductive reasoning
• To deduce or infer a conclusion, we have to
use the facts and knowledge on that particular
problem
62
Inference
Let A, B, C be the interior angles of a triangle such that
A ≥ B ≥ C > 0° and A + B + C = 180°
For this purpose we are having or defining 5 types of triangles namely:
R = Approximately Right-Angle Triangle
I = Approximately Isosceles Triangle
E = Approximately Equilateral Triangle
I.R = Isosceles Right-Angle Triangle
T = Other type of Triangle
Now we can infer membership values for all those type of triangles through
63
Inference
• Below given are the membership values for
the 5 types of triangles defined above.
64
Rank Ordering
• In Rank Ordering method preferences are assigned by a single
individual, committee, a poll and other opinion methods can
be used to assign membership values to fuzzy variables. Here
preference is determined by pairwise comparisons and these
are used to determine ordering of the membership.
65
Problem
• Suppose the 10000 people to questionnaire about
the pairwise preference among five cars,
X={Maruti 800, Scorpio, matiz, Santro, Octavia}.
Define a Fuzzy set A on the universe of cars “best
cars”.
April 2007 66
• Solution
67
Problem
• Using the inference approach, find the
membership values for the triangular shapes
I,R,E,IR and T for a triangle with angles 45,55
and 80
68
DEFUZZIFICATION
FUZZIFICATION
• Example 1:
• Suppose in the reading of a voltage, we say it is low voltage
• We need not measure it precisely
• When we measure it precisely it may be 0.3
• That is the membership value of the current voltage in the
fuzzy set representing low voltage is 0.3
• The membership function for “low” may be given by
0, if x 80;
80 x
Low ( x) , if 50 x 80;
x 20
1, if x 50.
EXAMPLES OF FUZZIFICATION
• Example 2:
• We can say that somebody is young
• He may be 37 years
• But when we measure it precisely we say he is 0.92 young
• Example 3:
• In finding the height of a person, we may say that he is tall.
• Actually, his height may be 5 feet 10 inches.
• So, taking the height of tall persons, we may say he is 0.95 tall.
DEFUZZIFICATION
• The set A is a crisp set called the lambda (λ)-cut set of the
fuzzy set A, where A = {x| A ( x) ≥ λ}.
We can reduce this fuzzy set into several λ-cut sets, all of which are
crisp λ = 1,0.9, 0.6,0.3,0+, and 0.
A1 = {a},
A0.9 = {a, b},
A0.6 = {a, b, c},
A0.3 = {a, b, c, d},
A0+ = {a, b, c, d, e}
A0 = X.
λ-CUTS FOR FUZZY RELATIONS
• Taking 1 1 0 0 0 0
0 1 0 0 0
R1 0 0 1 0 0
0 0 0 1 0
0 0 0 0 1
• Taking 0.6 1 1 0 0 0
1 1 0 0 1
R0.6 0 0 1 0 0
0 0 0 1 0
0 1 0 0 1
PROPERTIES OF λ-CUTS OF FUZZY RLATIONS
(i) (R S) R S
(ii) (R S) R S
(iii) ( RC ) ( R )C
Max-membership principle,
Centroid method,
Weighted average method,
Mean-max membership,
Center of sums,
Center of largest area,
First of maxima, last of maxima.
Defuzzification Methods
Consider a fuzzy output comparising two parts, the first part is C1
a triangularshape and C2 is trapezoidal shape . The union of these
two membership function
C = 𝐶1 ∪ 𝐶2
C1
C2
C
FUZZY DECISION
MAX MEMBERSHIP METHOD
Fuzzy set with the largest membership value is selected.
Fuzzy decision: Fn = {P, F. G, VG, E}
Fn = {0.6, 0.4, 0.2, 0.2, 0}
Final decision (FD) = Poor Student
If two decisions have same membership max, use the average of the
two.
P
CENTROID METHOD
This method is also known as center-of-mass, center-of-area, or center-of-
gravity method. It is the most commonly used defuzzification method. The
defuzzified output x* is defined as
P
MEAN MAX MEMBERSHIP METHOD
CENTER OF SUMS
This method employs the algebraic sum of the individual fuzzy subsets instead
of their unions. The calculations here are very fast but the main drawback is
that the intersecting areas are added twice. The defuzzified value x* is given
by
CENTER OF LARGEST AREA
• The method can be adopted when the output consists of at least convex
fuzzy subsets which are not overlapping.
• The output in this case is biased towards a side of one membership
function.
• When output fuzzy set has at least two convex regions then the center-of-
gravity of the convex fuzzy subregion having the largest area is used to
obtain the defuzzified value x*. This value is given by
where is the convex subregion that has the largest area making up
FIRST OF MAXIMA (LAST OF MAXIMA)
The steps used for obtaining crisp values are as follows:
Consider the discrete fuzzy set defined on the
universe X ={a,b,c,d,e} as