Documente Academic
Documente Profesional
Documente Cultură
0.6
0.4
0.2
0.0
150 160 170 180 190 200 210
Height, cm
Degreeof Fuzzy Sets
Membership
1.0
0.8
0.6 Short Average Tall
0.4
0.2
0.0
150 160 170 180 190 200 210
Dr Deepti Gupta CSE, UIET, Panjab
University, Chandigarh
Fuzzy Sets with Discrete Universes
Fuzzy set C = desirable city to live in
X = {SF, Boston, LA} (discrete and nonordered)
C = {(SF, 0.9), (Boston, 0.8), (LA, 0.6)}
Fuzzy set A = sensible number of children
X = {0, 1, 2, 3, 4, 5, 6} (discrete universe)
A = {(0, .1), (1, .3), (2, .7), (3, 1), (4, .6), (5, .2), (6, .1)}
1
10
X is continuous A A( x) / x
X
x a d x
Trapezoidal MF: trapmf ( x ; a, b , c , d ) max min , 1, , 0
b a d c
2
1 x c
2
Gaussian MF: gaussmf ( x ; a, b , c ) e
1
Generalized bell MF: gbellmf ( x ; a, b , c ) 2b
x c
1
b
Extensions:
Abs. difference
of two sig. MF
Product
of two sig. MF
disp_sig.m
Dr Deepti Gupta CSE, UIET, Panjab
University, Chandigarh
Set SMALL in set X consisting of
natural numbers <= to 12.
Assume: SMALL(1) = 1, SMALL(2) = 1, SMALL(3) =
0.9, SMALL(4) = 0.6, SMALL(5) = 0.4, SMALL(6) =
0.3, SMALL(7) = 0.2, SMALL(8) = 0.1, SMALL(u) = 0
for u >= 9.
Then,
Set SMALL = {{1, 1 }, {2, 1 }, {3, 0.9}, {4, 0.6}, {5,
0.4}, {6, 0.3}, {7, 0.2}, {8, 0.1}, {9, 0 }, {10, 0 }, {11,
0}, {12, 0}}
a fuzzy set defined precisely by associating with
each x , its grade of membership in SMALL.
Dr Deepti Gupta CSE, UIET, Panjab
University, Chandigarh
Universal Space
The universal space for fuzzy sets and fuzzy
relations is defined with three numbers.
The first two numbers specify the start and
end of the universal space, and the third
argument specifies the increment between
elements.
This gives the user more flexibility in choosing
the universal space.
0.4
Very Short Very
VeryTall
Tall
Tall
0.2
0.0
150 160 170 180 190 200 210
Height, cm
Dr Deepti Gupta CSE, UIET, Panjab
University, Chandigarh
Representation of hedges in fuzzy logic
Hedge Mathematical Graphical Representation
Expression
Very [ A (x)] 2
Extremely [ A(x) ] 3
Dr Deepti Gupta CSE, UIET, Panjab
University, Chandigarh
Mathematical
Hedge Graphical Representation
Expression
Somewhat A (x)
2 [A (x )]2
if 0 A 0.5
Indeed
1 2 [1 A (x)]2
if 0.5 < 1
Dr DeeptiAGupta CSE, UIET, Panjab
University, Chandigarh
Fuzzy Operations
Fuzzy set operations are the operations on
fuzzy sets.
The fuzzy set operations are generalization of
crisp set operations.
cardA = 1.8
cardB = 2.05
5 0 0 1 0
10 0 0 1 0
20 0 .8 .8 .1
30 0 1 .5 .2
40 0 1 .2 .4
50 0 1 .1 .6
60 0 1 0 .8
70 0 1 0 1
80 0 1 0 1
then A is empty
Dr Deepti Gupta CSE, UIET, Panjab
University, Chandigarh
Alpha-cut/Strong Alpha-cut
An -cut or -level set of a fuzzy set A X is an ORDINARY SET A X, such that:
A={A(x), xX}.
A Strong -cut or -level set of a fuzzy set A X is an ORDINARY SET A+ X, such
that:
A+={A(x)>, xX}.
All crisp subsets except for the null set are normal. In fuzzy
set theory, the concept of nullness essentially generalises
to subnormality.
Aa = {A(x)a, xX}
Let a =2, and
A = {0.5/a, 0.3/b, 0.2/c, 1/d}
then
Aa = {0.25/a, 0.09/b, 0.04/c, 1/d}
referred to as A and B
Core:
core(A) = {a}
core(B) = {o}
Cardinality:
card(A) = 1+0.3+0.2+0.8+0 = 2.3
card(B) = 0.6+0.9+0.1+0.3+0.2 = 2.1
Union:
A B = {1/a, 0.9/b, 0.2/c, 0.8/d, 0.2/e}
Intersection:
A B = {0.6/a, 0.3/b, 0.1/c, 0.3/d, 0/e}
Aa:
for a=2
Aa = {1/a, 0.09/b, 0.04/c, 0.64/d, 0/e}
a-cut:
A0.2 = {a, b, c, d}
A0.3 = {a, b, d}
A0.8 = {a, d}
A1 = {a}
: the set of all ordinary fuzzy sets that can be defined with the
universal set [0,1].
: is also called a fuzzy power set of [0,1].
maxproduct composition
maxmin composition:
IF x is A
THEN y is B
Rule: 1
IF speed is > 100
THEN stopping_distance is long
Rule: 2
IF speed is < 40
THEN stopping_distance is short
Degree of Degree of
Membership Membership
1.0 1.0
Tall men Heavy men
0.8 0.8
0.6 0.6
0.4 0.4
0.2 0.2
0.0 0.0
160 180 190 200 70 80 100 120
Dr Deepti
Height, cmGupta CSE, UIET, Panjab Weight, kg
University, Chandigarh
The value of the output or a truth membership grade of the rule
consequent can be estimated directly from a corresponding truth
membership grade in the antecedent. This form of fuzzy inference uses a
method called monotonic selection.
Degree of Degree of
Membership Membership
1.0 1.0
Tall men
0.8 0.8 Heavy men
0.6 0.6
0.4 0.4
0.2 0.2
0.0 0.0
160 180 190 200 70 80 100 120
Height, cm Weight, kg
Dr Deepti Gupta CSE, UIET, Panjab
University, Chandigarh
A fuzzy rule can have multiple antecedents, for example:
IF project_duration is long
AND project_staffing is large
AND project_funding is inadequate
THEN risk is high
IF service is excellent
OR food is delicious
THEN tip is generous
RULE 2:
IF TEMP is COOL THEN SPEED is SLOW
RULE 3:
IF TEMP is PLEASANT THEN SPEED is MEDIUM
RULE 4:
IF TEMP is WARM THEN SPEED is FAST
RULE 5:
IF TEMP is HOT THEN SPEED is BLAST
ambient temperatures. 0 Y* N N N N
5 Y Y N N N
where: 10 N Y N N N
17.5 N N Y* N N
Y* : temp value is the ideal 20 N N N Y N
member to the set (A(x)=1)
22.5 N N N Y* N
25 N N N Y N
N : temp value is not a member
of the set (A(x)=0)
27.5 N N N N Y
30 N N N N Y*
Dr Deepti Gupta CSE, UIET, Panjab
University, Chandigarh
Johnnys perception of the speed Rev/sec MINIMAL SLOW MEDIUM FAST BLAST
of the motor is as follows: (RPM)
0 Y* N N N N
10 Y N N N N
where: 20 Y Y N N N
Y : temp value belongs to the set 30 N Y* N N N
(0<A(x)<1) 40 N Y N N N
50 N N Y* N N
Y* : temp value is the ideal 60 N N N Y N
member to the set (A(x)=1) 70 N N N Y* N
80 N N N Y Y
COLD:
for 0 t 10 COLD(t) = t / 10 + 1
COOL:
for 0 t 12.5 COOL(t) = t / 12.5
for 12.5 t 17.5 COOL(t) = t / 5 + 3.5
0.7
0.6 Cool
0.5 Pleasent
0.4
0.3 Warm
0.2 Hot
0.1
0
0 5 10 15 20 25 30
Temperature Degrees C
MINIMAL:
for 0 v 30 MINIMAL(v) = v / 30 + 1
SLOW:
for 10 v 30 SLOW(v) = v / 20 0.5
for 30 v 50 SLOW(v) = v / 20 + 2.5
1
0.8 MINIMAL
Truth Value
0.6 SLOW
MEDIUM
0.4
FAST
0.2 BLAST
0
0 10 20 30 40 50 60 70 80 90 100
Speed
where wi is the degree to which the ith rule matches the input
data.
The advantage of this method is its simplicity.
Many neuro-fuzzy models use this defuzzification method to
reduce the complex of calculations.
Dr Deepti Gupta CSE, UIET, Panjab
University, Chandigarh
1. Fuzzification
Rule: 1 IF x is A3 OR y is B1 THEN z is C1
Rule: 2 IF x is A2 AND y is B2 THEN z is C2
Rule: 3 IF x is A1 THEN z is C3
Take the crisp inputs, x1 and y1 and determine the degree to which these inputs
belong to each of the appropriate fuzzy sets.
c1 c2 c3 c4 c5 c6
e1 E G F VG B G
e2 VG AV B VG AV VG
e3 G AV B VG AV VG
e4 G AV B E B E
e5 G F A G F G
e6 VG VG F G G G
c1 c2 c3 c4 c5 c6
fCS = [2.4 3.2 3.2 2.4 3.2 2.4 ]