Sei sulla pagina 1di 65

Fuzzy Sets & Systems

Tandra Pal
tandranit@yahoo.com

National Institute of Technology


Durgapur

1
Information & Complexity
simplification of complex problems (decision,
management, prediction etc.)

Loss of information

allow some degree of uncertainty in its description

The information loss for reducing the complexity of


the system to a manageable level is expressed in
uncertainty

2
Fuzzy
Why ? & When ?

for
UNCERTAINTY Mgmt.
In the Problem

Uncertainty :
In the parameters which define the problem
or
In the situation in which the problem occurs

3
Linguistic Imprecision

tall man
heavy guy
long street
large number
sharp corner
very young

Fuzzy logic works with linguistic terms, which are


inherently imprecise and subject specific
4
When did you come to the seminar?

How is weather today?

How do you teach driving to your friend?

Fuzzy logic models the uncertainty and impreciseness observed in real


world - unavoidable
Handles the concept of partial truth

5
Many decision-making and problem-solving tasks are too complex to be
defined precisely

However, people succeed by using imprecise knowledge

Fuzzy logic resembles human reasoning in its use of approximate information


and uncertainty to generate decisions.

Examples:
Design of washing machine Fuzzy washing machine
Decision regarding purchasing a car

6
Fuzzy logic enables us to
model human reasoning process at a higher level.

model real life situations

use it as a tool for finding solutions to problems.

7
Fuzzy vs. Crisp

fuzzy logic

traditional / classical / boolean logic: {true, false}

8
Crisp logic is concerned with absolutes-true or
false, there is no in-between.

True Membership function of crisp logic

Not hot hot


False

0
80F Temperature

If temperature >= 80F, it is hot (1 or true);


If temperature < 80F, it is not hot (0 or false).

9
Drawbacks of crisp logic

The membership function of crisp logic fails


to distinguish between the members of the same set and also
To detect the little difference among the members of different sets

Temperature = 100F hot


Temperature = 80.1F hot

Temperature = 79.9F not hot


Temperature = 50F not hot

10
Fuzzy vs. Probability
Two Mathematical tools to handle uncertainty

Fuzzy Probability
Fuzzy :
partial or imprecise information
Information is not fully reliable
Imprecision in the language
Example problem :
understanding human speech
recognizing handwritten characters etc.

Probability : random process, i.e., where occurrence of events are


determined by chance

11
FUZZY SET YES
WHITE

Classical set {0,1} Hard 1

Fuzzy set [0,1] Soft

0
BLACK
A = { (A(x), x) : for all x X} NO

A(x) : degree of belonging of x to A or degree of possessing some


imprecise property represented by A
Example : tall man, A = tall and x= a man

Similar Examples: long street, large number,


sharp corner, very young - Gradual transition

Fuzzy set is a Generalization of classical set

Greater flexibility in capturing faithfully various aspects


of incompleteness or imperfection in a situation. 12
Flexibility of fuzzy set theory is associated with
the concept of

is a measure of compatibility of an object with
theconcept represented by fuzzy set.

TALL = 0.3 means


Compatibility of some one with the set ``TALL
NOT the prob. that some one is TALL

i.e., 0.3 is the extent to which the concept ``TALL must be


stretched to fit him As Amount of Stretching
Concept

FUZZINESS IS ANALOGOUS TO ELASTICITY

13
F

0 1

F [X]
Domain = X

Fuzzy sets are membership functions.

14
Example

A = Good football team (20 members)


: degree goodness of a player x.
(x )

If (x=) 0 or 1, no ambiguity in asserting


that x is good or not.

If (x=) 0.5, maximum ambiguity in asserting


that x is good or not.

Uncertainty in
[0, 0.5] and in [0.5, 1]

with maximum at = 0.5.

Average of 20 values of ambiguity
a quantification
of amount of uncertainty, A possesses GLOBALLY

15

Representation of Fuzzy Sets
Membership functions

S Representation of Fuzzy Sets Membership functions

Representation of Fuzzy Sets Membership functions

16
Representation of Fuzzy Sets
Membership functions
S type functions
1.0 1.0

0.5 0.5

(x )
(x )
0.0
0.0
x x

A concept
Not unique
Objective/subjective Estimation
17
1.0

0.5
(x )

0.0

type membership function

1.0
1.0

0.5
0.5

(x ) (x )
0.0 0.0
18
Fuzzy Hedge

DILATION : more or less


CONCENTRATION : very
: Dilation : Concentration.
1.0

More-or-less Tall

Very Tall

Tall
0.5

(x )
0.0
19
Basic Operations
on
Fuzzy Sets

Union, Intersection and Complement


UNION

TALL
1.0
0.8 HANDSOME
0.6

5.0 5.3 5.6 6.0 6.6 7.0

TALL !HANDSOME TALL or HANDSOME

Generalization of !for CRISP Sets


A!B = max{ A (x ), B (x )}x X
21
Intersection

TALL
1.0
0.8 HANDSOME
!
0.6

5.0 5.3 5.6 6.0 6.6 7.0

TALL !HANDSOME TALL AND HANDSOME

Generalization of !for CRISP Sets


A!B (x ) = min{ A (x ), B (x )}x X
22
Complement

A = 1 A (x )x

TALL
NOT TALL
1.0

5.0 5.6 6.0 6.6 7.0

NOT TALL
SHORT

23
Fuzzy T- Norm & S-Norm
(operations on fuzzy sets)

Some examples of TS Pairs:

T(x,y)=min(x,y) ; S(x,y)=max(x,y)

T(x,y)=x.y ; S(x,y)=x+y-x.y

T(x,y)=max(x+y-1,0); S(x,y)=min(x+y,1)

24
Fuzzy Variable

We want the value to switch gradually as Young becomes Middle and Middle
becomes Old as it becomes really.

Fuzzy Sets for the variable age

Degree of
Membership
Young Middle Old
1

0.5

0
25 40 48 55 Age

A person of age 48 is more compatible with old than middle


25
Relations

26
Product set

27
Crisp Relations
Ordered pairs showing connection between two
sets:
(a, b): a is related to b
(2, 3) are related with the relation <

< 1 2
Relations are set themselves :
{(1, 1), (1, 2), (2, 1), (2, 2)} 1
2
Relations can be expressed as matrices.

28
Fuzzy Relations
Example: Color-Ripeness relation for tomatoes

R1(x, y) unripe semi ripe ripe


green 1 0.5 0

yellow 0.3 1 0.4

Red 0 0.2 1

29
Representation
Bipartite Graph

(Crisp) (Fuzzy)

30
Representation
Matrix

B B
y1 y2 y3 y4 y1 y2 y3 y4
x1 x1
x2 x2
x3 x3
x4 x4

(Crisp) (Fuzzy)

31
Representation
Digraph

(Crisp) (Fuzzy)

32
Operations on fuzzy Relations
Sum: A + B = max[aij , bij ]
Example

33
Composition of fuzzy relations
Max-min composition
( x, y ) A B, ( y, z ) B C
S !R ( x, z ) = max[min( R ( x, y ), S ( y, z ))]
y

= [ R ( x, y ) S ( y, z )]
Example y

34
Composition of fuzzy relations

35
Composition of fuzzy relations
Example

S !R (1, ) = max[min(0.1, 0.9), min(0.2, 0.2), min(0.0, 0.8), min(1.0, 0.4)]


= max[0.1, 0.2, 0.0, 0.4] = 0.4

36
Composition of fuzzy relations
Example

S !R (1, ) = max[min(0.1, 0.0), min(0.2,1.0), min(0.0, 0.0), min(1.0, 0.2)]


= max[0.0, 0.2, 0.0, 0.2] = 0.2

37
Composition of fuzzy relations

38
-cut of fuzzy relation

Example

39
-cut of fuzzy relation

40
Decomposition of relation

41
Decomposition of relation

0.9 0.4 0.0


0.0 1.0 0.4
MR =
0.0 0.7 1.0
0.4 0.0 0.0 42
Projection

43
Projection

44
Fuzzy Rules

45
Types of Fuzzy Rules

Mamdani-Assilian Model :
R1 : If x is A1 and y is B1 then z is C1
R2 : If x is A2 and y is B2 then z is C2
Ai, Bi, and Ci are fuzzy sets defined on universes of x and y (input) and z (output)
respectively.

Takagi-Sugeno Model :
R1 : If x is A1 and y is B1 then z = f1(x,y)
R2 : If x is A2 and y is B2 then z = f2(x,y)
fi(x,y) is a function of X and y
For example : fi(x,y) = ai.x + bi.y + ci contd.

46
Types of rules Contd.

Classifier model :
R1 : If x is A1 and y is B1 then pattern class is 1
R2 : If x is A2 and y is B2 then pattern class is 2

What to do with this rules !

Function approximation
Classification

47
Fuzzy Systems

48
Fuzzy System

Crisp Input

Fuzzification Input Membership Functions

Fuzzy Input

Inferencing Rules / Inferences

Fuzzy Output

Defuzzification Output Membership Functions

Crisp Output

49
Fuzzification
Two Inputs (x, y) and one output (z)
Membership functions:
low(t) = 1 - ( t / 10 )
high(t) = t / 10

0.68
Low High

0.32
0
Crisp Inputs X=0.32 Y=0.61 t

Low(x) = 0.68, High(x) = 0.32, Low(y) = 0.39, High(y) = 0.61

50
Rule base
Rule 1: If x is low AND y is low Then z is
high
Rule 2: If x is low AND y is high Then z is
low
Rule 3: If x is high AND y is low Then z is
low
Rule 4: If x is high AND y is high Then z is
high

51
Inference Rule strength

Rule1: low(x)=0.68, low(y)=0.39 =>


high(z)=MIN(0.68,0.39)=0.39

Rule2: low(x)=0.68, high(y)=0.61 =>


low(z)=MIN(0.68,0.61)=0.61

Rule3: high(x)=0.32, low(y)=0.39 =>


low(z)=MIN(0.32,0.39)=0.32

Rule4: high(x)=0.32, high(y)=0.61 =>


high(z)=MIN(0.32,0.61)=0.32

52
Composition
Low(z) = MAX(rule2, rule3) = MAX(0.61, 0.32) = 0.61
High(z) = MAX(rule1, rule4) = MAX(0.39, 0.32) = 0.39

1
Low High

0.61

0.39

0
t
53
Defuzzification
Max

Center of Gravity tf (t )dt


Min
C= Max

1
f (t )dt
Min
Low
Center of Gravity High

0.61

0.39

0
t
Crisp output
54
Composition Rule of Inference

Let Universe X = { 1, 2, 3, 4 }.
A little = {(1,1.0), (2,0.6), (3,0.2), (4,0.0)} in X.

B approximately equal in X Y

1 2 3 4
1 1.0 0.5 0.0 0.0
2 0.5 1.0 0.5 0.0
3 0.0 0.5 1.0 0.5
4 0.0 0.0 0.5 1.0

C(y) = A ! B
= max min {A(x), B(x,y)}
x
= {(1,1.0), (2,0.6), (3,0.5), (4,0.2)} approximately little.

55
Function Approximation

Input X . . Output Y
. .

The system S can be any type of system with numerical input and output

Pattern Classification
Classifiers are functions of special types which do not have numerical inputs but
have Class labels as outputs.Class labels can be coded.

56
System Aim

FUZZY LOGIC CONTROL Replace/Emulate


Human Operator
BASED SYSTEMS

Replace/Emulate
FUZZY EXPERT Human Expertise
SYSTEMS

FUZZY P.R & I.P SYSTEMS Generalization


and Uncertainty
Handling

57
Pattern Recognition System (PRS)

Measurement Feature Decision


Space Space Space

Uncertainties arise from deficiencies of


information available from a situation

Deficiencies may result from incomplete,


imprecise, ill-defined, not fully reliable,
vague, contradictory information in various
stages of a PRS
58
Uncertainty in input Features
Conventional Probabilistic & Deterministic Classifiers:
Features are considered to be quantitative (numerals)
Patterns having imprecise or incomplete information usually
ignored/discarded from the design & test processes

Impreciseness (or ambiguity) may arise from instrumental


error or noise corruption in the experiment so that

Partial information available on a feature measurement F


viz, F is about 500, say or F is between 400 and 500

Expense incurred in extracting the exact value of features may


be high (or may be difficult to decide on actual salient features
to be extracted)

May become convenient to use the linguistic variables and


hedges, to describe feature information (viz., F is very small)
59
It is not appropriate to give exact representation to
uncertain feature. Rather, it is reasonable to represent
these information by fuzzy sets

-- Representing an input pattern as an array of membership


values denoting the degree of possession of certain
properties

-- Representing linguistically phrase input features for


processing

60
Why Fuzzy Image Processing / Analysis ?

A gray tone image possesses ambiguity within pixels


because of the possible multi-valued levels of brightness
in the image. This indeterminacy (both in grayness &
spatially) is due to inherent vagueness rather than
randomness.

Many basic concepts of image analysis (e.g., the


concept of edge, corner, boundary, region, properties,
relation between regions) -- do not lend themselves
well to precise definition.

61
Uncertainty in Image Processing and Vision
Conventional approaches to image analysis &
recognition consist of

Segmenting the image space into meaningful regions,

Extracting their edges and skeletons,


Computing various properties (e.g., area, perimeter,
centroid), features/primitives (e.g., line, corner, curve)
of and relationship among the regions, and finally,

Developing decision rules/grammars for describing


interpreting and / or classifying the image and its
subregions.

In a conventional system, these operations involve crisp


decisions i.e., 1 or 0, yes or no, black or white --- making
regions, features, primitives, properties, relations and
interpretations crisp.

62
Since the regions in an image are not always crisply
defined, uncertainty can arise within every phase
of these tasks.

Any decision made at a particular level will have an


impact on all higher level activities.

A recognition or vision system should have sufficient


provision for representing and manipulating the uncer-
tainties involved at every processing stage, so that the
system retains as much of the information content
of the data as possible.

The ultimate output (results) of the system will then


possess minimal uncertainty (and, unlike conventional
systems, will not be biased / affected much by lower
level decisions.)

63
Thus it is convenient, natural and appropriate to avoid
ourselves committing to a specific hard decision, by
allowing the segments, skeletons or contours to be
fuzzy subsets of the image --- the subsets being
characterized by the possibility or degree to which
each pixel belongs to them.

64
Thank You
65

Potrebbero piacerti anche