L2 - Fuzzy Logic System
L2 - Fuzzy Logic System
20 / 69
Membership function with discrete membership
values
A ={(0,0.1),(1,0.30),(2,0.78)……(10,0.1)}
1.0
0.8
Note : X = discrete value
0.6
µ
0.4
0.2
How you measure happiness ??
0 2 4 6 8 10
A = “Happy family”
21 / 69
Membership function with continuous
membership values
1.0
0.8
B (x) = 1
x −50
4
1+
0.6 10
0.4
0.2
0 50 100
B
Age (X)
Note : x = real value
+
=R
B = “Middle aged”
22 / 69
Fuzzy terminologies: Support
• Support: The support of a fuzzy set A is the set of all points x ∈ X
such that µA (x ) > 0, - is a crisp subset of the universe
• Leave off all elements that have a zero membership grade
23 / 69
Fuzzy terminologies: Core
Core: The core of a fuzzy set A is the set of all points x in X such that
µA(x ) = 1
1.0
µ
0.5
24 / 69
Fuzzy terminologies: Normality
1.0
25 / 69
Fuzzy terminologies: Crossover points
26 / 69
Fuzzy terminologies: Fuzzy Singleton
27 / 69
Fuzzy terminologies: α-cut and strong α-cut
Aα = {x | µA (x) ≥ α
}
28 / 69
Fuzzy terminologies: Convexity
Convexity : A fuzzy set A is convex if and only if for any x1 and x2 ∈ X
and any λ ∈ [0, 1]
µA (λx1 + (1 -λ)x2 ) ≥ min(µA(x1 ), µA(x2 ))
Note :
• A is convex if all its α- level sets are convex.
• Convexity (Aα ) =⇒ Aα is composed of a single line segment only.
Membership function is Non-convex
convex Membership function
1.0 1.0
29 / 69
Fuzzy terminologies: Height
Height:
In A fuzzy set A the highest point is defined as the height of that fuzzy set.
31 / 69
Fuzzy terminologies: Bandwidth
Bandwidth :
For a normal and convex fuzzy set, the bandwidth (or width) is defined
as the distance the two unique crossover points:
Bandwidth(A) = | x1 - x2 |
where µA(x1 ) = µA(x2 ) = 0.5
30 / 69
Fuzzy terminologies: Symmetry
Symmetry :
31 / 69
• The fuzzy approach uses a premise that humans don't
represent classes of objects
• The term "fuzzy systems" refers mostly to systems that
are governed by fuzzy IF-THEN rules. The IF part of an
implication is called the antecedent whereas the THEN
is called a consequent
• a fuzzy IF-THEN rule is a scheme for capturing
knowledge that involves imprecision.
• Fuzzy rules => partial matching capability, which
enables an inference to be made from a fuzzy rule even
when the rule's condition is only partially satisfied.
Fuzzy terminologies: Open and Closed
A fuzzy set A is
Open left
If limx →−∞ µA(x) = 1 and limx →+∞ µA(x) = 0
Open right:
If limx →−∞µA(x) = 0 and limx →+∞ µA(x) = 1
Closed
If : limx →−∞ µA(x) = limx →+∞ µA(x) = 0
32 / 69
Fuzzy vs. Probability
Example: India will win the T20 tournament with a chance 60% means
that out of 100 matches, India own 60 matches.
33 / 69
Prediction vs. Forecasting
Forecasting : When you take the information from the past job and
apply it to new job.
34 / 69
Fuzzy Membership
Functions
35 / 69
Fuzzy membership functions
A fuzzy set is completely characterized by its membership function
(sometimes abbreviated as MF and denoted as µ ). So, it would be
important to learn how a membership function can be expressed
(mathematically or otherwise).
Note: A membership function can be on
(a) a discrete universe of discourse and (b)
a continuous universe of discourse.
Example:
1.0 1.0
0.8 0.8
0.6 0.6
µA
µB
0.4 0.4
0.2 0.2
0 2 4 6 8 10 0 10 20 30 40 50
60
36 / 69
Fuzzy membership functions
So, membership function on a discrete universe of course is trivial.
However, a membership function on a continuous universe of
discourse needs a special attention.
Following figures shows a typical examples of membership functions.
µ
µ
x x x
x x
38 / 69
Fuzzy MFs: Trapezoidal
a b c d
39 / 69
Fuzzy MFs: Gaussian
1 x−c
gaussian(x;c,σ) =e − 2 ( σ)2 .
c
0.1 0.1c 0.9c
40 / 69
Fuzzy MFs: Generalized bell
Slope at x = b
2a
Slope at y = − b
xx b
b yy 2a
c-a c c+a
41 / 69
Example: Generalized bell MFs
1.0
-1 0 1
42 / 69
Generalized bell MFs: Different shapes
Changing a Changing b
Changing a
Changing a and b
43 / 69
Fuzzy MFs: Sigmoidal MFs
Sigmoid(x;a,c)= 1
a
−[ x −c ]
1+e
1.0
Slope = a
0.5
44 / 69
Fuzzy MFs : Example
Excellent = Marks ≤ 90
Very good = 75 ≤ Marks ≤ 90
Good = 60 ≤ Marks ≤ 75
Average = 50 ≤ Marks ≤ 60
Poor = 35 ≤ Marks ≤ 50
Bad= Marks ≤ 35
45 / 69
Grading System
1
.8
.6
.4
.2
0
10 20 30 40 50 60 70 80 90
marks
You can decide a standard fuzzy MF for each of the fuzzy garde.
46 / 69