Unit 3 - Soft Computing

Download as pdf or txt
Download as pdf or txt
You are on page 1of 17

Program : B.

E
Subject Name: Soft Computing
Subject Code: CS-8001
Semester: 8th
Downloaded from be.rgpvnotes.in

UNIT-3 Notes

Introduction
The word "fuzzy" means "vagueness". Fuzziness occurs when the boundary of a piece of
information is not clear-cut. Fuzzy sets have been introduced by Lotfi A. Zadeh (1965) as an
extension of the classical notion of set.
Human thinking and reasoning frequently involve fuzzy information originating from inherently
inexact human concepts. Human can give satisfactory answers, which are probably true.
However our systems are unable to answer many questions. The reason is, most systems are
designed based upon classical set theory and two-valued logic which is unable to cope with
unreliable and incomplete information and give expert opinions. Fuzzy set theory is an
extension of classical set theory where elements have degree of membership.

Fuzzy Set Theory


Fuzzy set theory is an extension of classical set theory where elements have varying degrees of
membership. A logic based on the two truth values, True and False, is sometimes inadequate
when describing human reasoning. Fuzzy logic uses the whole interval between 0 (false) and
1(true) to describe human reasoning. A fuzzy set in any set that allows its members to have
different degree of membership, called membership function, in the interval [0, 1].

Fuzzy Set and Crisp Set


In classical set theory the characteristic function has only values 0(false) and 1(true). Such sets
are crisp set.
Fo fuzz set the ha a te isti fu tio a e defi es as
 The characteristic function for the crisp set is generalized for the Fuzzy sets.
 This generalized characteristic function is called membership function.
Crisp set theory is not capable of representing descriptions and classification in many cases; In
fact, Crisp set does not provide adequate representation for most cases.

Crisp Relation

A crisp relation is used to represents the presence or absence of interaction, association, or


interconnectedness between the elements of more than a set. This crisp relational concept can
be generalized to allow for various degrees or strengths of relation or interaction between
elements.

Page no: 1 Follow us on facebook to get real-time updates from RGPV


Downloaded from be.rgpvnotes.in

Operations on Crisp Relations

Let A and B be two relations defined on X x Y and are represented by relational matrices. The
following operations can be performed on these relations A and B:

Union: A ∪ B (x,y) = max [ A (x,y) , B (x,y) ]

Intersection: A ∩ B , = i [A , ,B , ]

Fuzzy relation

Degrees of association can be represented by grades of the membership in a fuzzy relation in


the same way as degrees of set membership are represented in the fuzzy set. In fact, just as the
crisp set can be viewed as a restricted case of the more general fuzzy set concept, the crisp
relation can be considered to be a restricted case of the fuzzy relations.

Operations on Fuzzy Relations


Ha i g t o fuzz sets A˜ a d B˜, the u i e se of i fo atio U a d a ele e t � of the
universe, the following relations express the union, intersection and complement operation on
fuzzy sets.

. U io /Fuzzy O‘
Let us consider the following ep ese tatio to u de sta d ho the U io /Fuzz O‘ elatio
o ks −
μA˜∪B˜ =μA˜ μB˜∀y∈U
Here ep ese ts the a ope atio .

. I tersectio / Fuzzy AND


Let us o side the follo i g ep ese tatio to u de sta d ho the I te se tio /Fuzz AND
elatio o ks −

Page no: 2 Follow us on facebook to get real-time updates from RGPV


Downloaded from be.rgpvnotes.in

μA˜∩B˜ =μA˜ μB˜∀y∈U


Here ep ese ts the i ope atio .

. Co ple e t/ Fuzzy NOT


Let us o side the follo i g ep ese tatio to u de sta d ho the Co ple e t/Fuzz NOT
elatio o ks −
μA˜= −μA˜(y)y∈U

Fuzzy systems: Crisp logic

Crisp logic (crisp) is the same as Boolean logic (either 0 or 1). Either a statement is true (1) or it
is not (0), meanwhile fuzzy logic captures the degree to which something is true. Consider the
state e t: The ag eed to et at o lo k ut Be as ot pu tual.

 Crisp logic: If Ben showed up precisely at 12, he is punctual; otherwise he is too early or
too late.
 Fuzzy logic: The degree, to which Ben was punctual, can be identified by on how much
earlier or later he showed up (e.g. 0, if he showed up 11:45 or 12:15, 1 at 12:00 and a
linear increase / decrease in between).

Crisp is multiple times in the closely related Fuzzy Set Theory FS, where it has been used to
disti guish Ca to s set theo f o )adeh s set theo .

Page no: 3 Follow us on facebook to get real-time updates from RGPV


Downloaded from be.rgpvnotes.in

Fuzzy Logic
Fuzzy logic is derived from fuzzy set theory dealing with reasoning that is approximate rather
than precisely deduced from classical predicate logic. Fuzzy logic is capable of handling
inherently imprecise concepts. Fuzzy logic allows in linguistic form the set membership values
to i p e ise o epts like slightl , uite a d e .

Membership Function

Definition: a membership function for a fuzzy set A on the universe of discourse X is defined as
µA: X → [ , ], he e ea h ele e t of X is apped to a alue etween 0 and 1. This value,
called membership value or degree of membership, quantifies the grade of membership of the
element in X to the fuzzy set A.

Membership functions allow us to graphically represent a fuzzy set. The x axis represents the
universe of discourse, whereas the y axis represents the degrees of membership in the [0, 1]
interval.

Simple functions are used to build membership functions. Because we are defining fuzzy
concepts, using more complex functions does not add more precision.

Some of the Fuzzy member functions are as follows:

1. Triangular MFs

A triangular MF is specified by three parameters {a, b, c} as follows:

The parameters {a, b, c} (with a < b < c) determine the x coordinates of the three corners of the
underlying triangular MF.
2. Trapezoidal MFs

A trapezoidal MF is specified by four parameters {a, b, c, d} as follows:

Page no: 4 Follow us on facebook to get real-time updates from RGPV


Downloaded from be.rgpvnotes.in

The parameters {a, b, c, d} (with a < b <= c < d) determine the x coordinates of the four corners
of the underlying trapezoidal MF.

3. Gaussian MFs

A Gaussian MF is specified by tow parameters:

A Gaussia MF is dete i ed o plete a d σ; ep ese ts the MFs e t e a d


σ determines the MFs width.

Fuzzy rule base system:

Fuzzy rules are linguistic IF-THEN- constructions that have the general form "IF A THEN B"
where A and B are (collections of) propositions containing linguistic variables. A is called the
premise and B is the consequence of the rule. In effect, the use of linguistic variables and fuzzy
IF-THEN- rules exploits the tolerance for imprecision and uncertainty. In this respect, fuzzy logic
mimics the crucial ability of the human mind to summarize data and focus on decision-relevant
information.

In a more explicit form, if there are I rules each with K premises in a system, the ith rule has the
following form.

In the above equation a represents the crisp inputs to the rule and A and B are linguistic
variables. The operator 1 can be AND or OR or XOR.

Example: If a HIGH flood is expected and the reservoir level is MEDIUM, then water release is
HIGH.

Page no: 5 Follow us on facebook to get real-time updates from RGPV


Downloaded from be.rgpvnotes.in

Several rules constitute a fuzzy rule-based system.

Another example comes from Kosko (1993). Figures 4.1 below illustrates the notion of a simple
fuzzy rule with one input and one output applied to the problem of an air motor speed
controller for air conditioning. Rules are given. Let us say the temperature is 22 degrees. This
temperature is "right" to a degree of 0.6 and "warm" to a degree of 0.2 and it belongs to all
others to a degree of zero. This activates two of the rules shown in Figure 4.2. The rule
responses are combined to give those shown in Figure 4.3 (thick lines).

Fig: 4.1 Fuzzy Rule Base Example

Note 1. Air motor speed controller, Temperature (input) and speed (output) are fuzzy variables
used in the set of rules.
Note 2. Temperature of 22 deg. "fires" two fuzzy rules. The resulting fuzzy value for air motor
speed is "defuzzified .

Page no: 6 Follow us on facebook to get real-time updates from RGPV


Downloaded from be.rgpvnotes.in

Fuzzy Proposition
Fuzz p opositio s a e assig ed to fuzz sets. “uppose a fuzz p opositio P is assig ed to a
fuzz set A , the the t uth alue of the p opositio is p oposed T P = μA he e
μA
Therefore truthness of a proposition P is membership value of x in fuzzy set A.
The logical connectives like disjunction, conjunction, negation and implication are also defined
on fuzzy propositions.

Fuzzy Proposition Formation


Let, a fuzz p opositio P is defi ed o a fuzz set A a d Q is defi ed o fuzz set B the :
1. Conjunction

P / Q : x is A and B

T( P / Q) = Min [ T(P), T(Q)]

2. Negation

T(Pc) = 1 – T(P)

3. Disjunction

P V Q : x in A or B

T (P V Q) = Max [ T(P), T(Q) ]

4. Implication

P → Q : is A the is B

T P → Q = T Pc V Q) = Max [ T(Pc, T(Q)]

If P is a proposition defined on set A on universe of discourse X and Q is another proposition


defi ed o set B o u i e se of dis ou se Y, the the i pli atio P → Q a e ep ese ted
the relation R

R = (A X B) U (Ac X Y) = If A then B and If x ∈ A, where x ∈ X and A ⊂ X then y ∈ B, where y ∈ Y


and B ⊂ Y

Fuzzy Decomposition

Page no: 7 Follow us on facebook to get real-time updates from RGPV


Downloaded from be.rgpvnotes.in

Fuzzy Decomposition can be done using IF-THEN rules. It is a known fact that a human being is
always comfortable making conversations in natural language. The representation of human
k o ledge a e do e ith the help of follo i g atu al la guage e p essio −
IF antecedent THEN consequent
The expression as stated above is referred to as the Fuzzy IF-THEN rule base.

General format: if x is A then y is B

 If pressure is high, then volume is small


Examples:

 If the road is slippery, then driving is dangerous


 Is a tomato is red, then it is ripe
 If the speed is high, then apply the break a little.

Interpretations of Fuzzy IF-THEN Rules


Fuzzy IF-THEN ‘ules a e i te p eted i the follo i g fou fo s−

Assignment Statements
These ki ds of state e ts use = e ual to sig fo the purpose of assignment. They are of the
follo i g fo −
a = hello
climate = summer

Conditional Statements
These ki ds of state e ts use the IF-THEN ule ase fo fo the pu pose of o ditio . The
a e of the follo i g fo −
IF temperature is high THEN Climate is hot
IF food is fresh THEN eat.

Unconditional Statements
The a e of the follo i g fo −
GOTO 10
turn the Fan off

Fuzzy Aggregation:

Having generated the truth of each rule in the rule base, we often have to aggregate them to
evaluate the truth of some derived statement. When aggregating a large number of fuzzy rules
(``clauses'') into a single fuzzy value, we can use the min, the max or a generalized mean
operator. In the case of rare events, the attributes are distributed in such a way that, except at
the extremes, the non-events always out number events. Optimal performance would,
therefore, be achieved when the fuzzy membership functions are non-zero only in the tail-end
of the distributions.
However, in the presence of one or more zeros in the clauses, we found that the minimum and
maximum operators failed because of their dependence on all or none of their arguments

Page no: 8 Follow us on facebook to get real-time updates from RGPV


Downloaded from be.rgpvnotes.in

holding while the generalized means got diluted. Consequently, we use an aggregation
operator defined as:

It can be readily verified that this operator satisfies the requirements of an aggregation operator. It
satisfies the boundary conditions and is monotonic non-decreasing in all its arguments. In addition, since
we sort the arguments in descending order before doing the weighted addition, it is symmetric in its
arguments.

Fuzzy Reasoning:
Follo i g a e the diffe e t odes of app o i ate easo i g −
Categorical Reasoning
In this mode of approximate reasoning, the antecedents, containing no fuzzy quantifiers and
fuzzy probabilities, are assumed to be in canonical form.

Qualitative Reasoning
In this mode of approximate reasoning, the antecedents and consequents have fuzzy linguistic
variables; the input-output relationship of a system is expressed as a collection of fuzzy IF-THEN
rules. This reasoning is mainly used in control system analysis.

Syllogistic Reasoning
In this mode of approximation reasoning, antecedents with fuzzy quantifiers are related to
i fe e e ules. This is e p essed as −
= “ A′s a e B′s
y = “ C′s a e D′s
------------------------
z = “ E′s a e F′s

 S1 and S2 are given fuzzy quantifiers.


Here A,B,C,D,E,F are fuzzy predicates.

 S3 is the fuzzy quantifier which has to be decided.

Dispositional Reasoning
In this mode of approximation reasoning, the antecedents are dispositions that may contain the
fuzz ua tifie usuall . The ua tifie Usuall li ks togethe the dispositio al a d s llogisti
reasoning; hence it pays an important role.

For example, the projection rule of inference in dispositional reasoning can be given as follows

usually ( (L,M) is R ) ⇒ usuall L is [‘ ↓ L]
He e [‘ ↓ L] is the p oje tio of fuzz elatio ‘ o L

Page no: 9 Follow us on facebook to get real-time updates from RGPV


Downloaded from be.rgpvnotes.in

Fuzzy Inference System


Fuzzy Inference System is the key unit of a fuzzy logic system having decision making as its
pi a o k. It uses the IF…THEN ules alo g ith o e to s O‘ o AND fo d a i g
essential decision rules.

 The output from FIS is always a fuzzy set irrespective of its input which can be fuzzy or
Characteristics of Fuzzy Inference System

 It is necessary to have fuzzy output when it is used as a controller.


crisp.

 A defuzzification unit would be there with FIS to convert fuzzy variables into crisp
variables.

Knowledge Base

Data Base Rule Base

Input (Crisp) Fuzzification Defuzzification Output (Crisp)


Interface Unit Interface Unit

Decision Making Unit

Fig 4.2: Block Diagram of FIS


Functional Blocks of FIS
The follo i g fi e fu tio al lo ks ill help ou u de sta d the o st u tio of FI“ −
Rule Base − It o tai s fuzz IF-THEN rules.
Database − It defi es the e e ship fu tions of fuzzy sets used in fuzzy rules.
Decision-making Unit − It pe fo s ope atio o ules.
Fuzzification Interface Unit − It o e ts the isp ua tities i to fuzz ua tities.
Defuzzification Interface Unit − It o e ts the fuzz ua tities i to isp ua tities. Follo i g is
a block diagram of fuzzy interference system.

Working of FIS
The o ki g of the FI“ o sists of the follo i g steps −

Page no: 10 Follow us on facebook to get real-time updates from RGPV


Downloaded from be.rgpvnotes.in

 A fuzzification unit supports the application of numerous fuzzification methods, and


converts the crisp input into fuzzy input.
A knowledge base - collection of rule base and database is formed upon the conversion


of crisp input into fuzzy input.
The defuzzification unit fuzzy input is finally converted into crisp output.

Fuzzy Decision Making


It is an activity which includes the steps to be taken for choosing a suitable alternative from
those that are needed for realizing a certain goal.

Steps for Decision Making

Let us now discuss the steps involved in the decisio aki g p o ess −

 Determining the Set of Alternatives − I this step, the alte ati es f o hi h the
decision has to be taken must be determined.
 Evaluating Alternative − He e, the alte ati es ust e e aluated so that the de isio
can be taken about one of the alternatives.
 Comparison between Alternatives − I this step, a o pa iso et ee the e aluated
alternatives is done.

Types of Decision
1. Individual Decision Making

In this type of decision making, only a single person is responsible for taking decisions. The
de isio aki g odel i this ki d a e ha a te ized as −

 Set of possible actions


 Set of goals Gi(i∈Xn);
 Set of Constraints Cj(j∈Xm)

The goals and constraints stated above are expressed in terms of fuzzy sets.

Now consider a set A. Then, the goal and constraints for this set are given by –

Gi(a)= composition[Gi(a)] = G1i(Gi(a)) with G1i

Cj(a)= composition[Cj(a)] = C1j(Cj(a)) with C1j for a∈A


The fuzz de isio i the a o e ase is gi e −

FD=min[i∈XinnfGi(a),j∈XinmfCj(a)]

Page no: 11 Follow us on facebook to get real-time updates from RGPV


Downloaded from be.rgpvnotes.in

2. Multi-person Decision Making

Decision making in this case includes several persons so that the expert knowledge from various
persons is utilized to make decisions.

Cal ulatio fo this a e gi e as follo s −

Number of persons preferring xi to xj = N(xi,xj)

Total number of decision makers = n Then, SC(xi,xj)=N(xi,xj)n

3. Multi-objective Decision Making

Multi-objective decision making occurs when there are several objectives to be realized. There
are following two issues in this type of de isio aki g −

 To acquire proper information related to the satisfaction of the objectives by various


alternatives.
 To weigh the relative importance of each objective.

Mathe ati all e a defi e a u i e se of alte ati es as −

A=[a1,a2,...,ai,...,an]

A d the set of o je ti es as O=[o1,o2,...,oi,...,on]

4. Multi-attribute Decision Making

Multi-attribute decision making takes place when the evaluation of alternatives can be carried
out based on several attributes of the object. The attributes can be numerical data, linguistic
data and qualitative data.

Mathematically, the multi-attribute evaluation is carried out on the basis of linear equation as
follo s −

Y=A1X1+A2X2+...+AiXi+...+ArXr

Applications of Fuzzy Logic

Page no: 12 Follow us on facebook to get real-time updates from RGPV


Downloaded from be.rgpvnotes.in

1. Aerospace

In aerospace, fuzz logi is used i the follo i g a eas −

 Altitude control of spacecraft


 Satellite altitude control
 Flow and mixture regulation in aircraft deicing vehicles
2. Automotive

I auto oti e, fuzz logi is used i the follo i g a eas −

 Trainable fuzzy systems for idle speed control


 Shift scheduling method for automatic transmission
 Intelligent highway systems
 Traffic control
 Improving efficiency of automatic transmissions
3. Business

I usi ess, fuzz logi is used i the follo i g a eas −

 Decision-making support systems


 Personnel evaluation in a large company
4. Defense

I defe se, fuzz logi is used i the follo i g a eas −

 Underwater target recognition


 Automatic target recognition of thermal infrared images
 Naval decision support aids
 Control of a hypervelocity interceptor
 Fuzzy set modeling of NATO decision making
5. Electronics

I ele t o i s, fuzz logi is used i the follo i g a eas −

 Control of automatic exposure in video cameras


 Humidity in a clean room
 Air conditioning systems
 Washing machine timing
 Microwave ovens
 Vacuum cleaners
6. Finance

I the fi a e field, fuzz logi is used i the follo i g a eas −

Page no: 13 Follow us on facebook to get real-time updates from RGPV


Downloaded from be.rgpvnotes.in

 Banknote transfer control


 Fund management
 Stock market predictions
7. Industrial Sector

In industrial, fuzzy logic is used in following areas −

 Cement kiln controls heat exchanger control


 Activated sludge wastewater treatment process control
 Water purification plant control
 Quantitative pattern analysis for industrial quality assurance
 Control of constraint satisfaction problems in structural design
 Control of water purification plants
8. Manufacturing

I the a ufa tu i g i dust , fuzz logi is used i follo i g a eas −

 Optimization of cheese production


 Optimization of milk production
9. Marine

In the marine field, fuzzy logic is used i the follo i g a eas −

 Autopilot for ships


 Optimal route selection
 Control of autonomous underwater vehicles
 Ship steering
10. Medical

I the edi al field, fuzz logi is used i the follo i g a eas −

 Medical diagnostic support system


 Control of arterial pressure during anesthesia
 Multivariable control of anesthesia
 Modeling of neuropath logical findings in Alzheimer's patients
 Radiology diagnoses
 Fuzzy inference diagnosis of diabetes and prostate cancer
11. Securities

In securities, fuzzy logic is used i follo i g a eas −

 Decision systems for securities trading


 Various security appliances

Page no: 14 Follow us on facebook to get real-time updates from RGPV


Downloaded from be.rgpvnotes.in

12. Transportation

I t a spo tatio , fuzz logi is used i the follo i g a eas −

 Automatic underground train operation


 Train schedule control
 Railway acceleration
 Braking and stopping
13. Pattern Recognition and Classification

I Patte ‘e og itio a d Classifi atio , fuzz logi is used i the follo i g a eas −

 Fuzzy logic based speech recognition


 Fuzzy logic based
 Handwriting recognition
 Fuzzy logic based facial characteristic analysis
 Command analysis
 Fuzzy image search
14. Psychology

I Ps holog , fuzz logi is used i follo i g a eas −

 Fuzzy logic based analysis of human behavior


 Criminal investigation and prevention based on fuzzy logic reasoning

Page no: 15 Follow us on facebook to get real-time updates from RGPV


We hope you find these notes useful.
You can get previous year question papers at
https://qp.rgpvnotes.in .

If you have any queries or you want to submit your


study notes please write us at
[email protected]

You might also like