Fuzzy Sets and Systems Lecture 6 - profs.basu.ac.ir · PDF fileFuzzy Sets and Systems Lecture...

Post on 13-Feb-2018

212 views 0 download

transcript

Fuzzy Sets and Systems

Lecture 6(Fuzzy Inference Systems)

Bu- Ali Sina UniversityComputer Engineering Dep.

Spring 2010

Outline

Fuzzy inference system�Fuzzifiers�Defuzzifiers

Fuzzy Systems with Fuzzifier and Defuzzifier (Fuzzy inference)

RV⊂nn RUUU ⊂××= L1

Fuzzy Rule BaseFuzzy Rule Base

Fuzzy InferenceFuzzy InferenceEngineEngine

x in U y in V

FuzzifierFuzzifier DefuzzifierDefuzzifier

Fuzzy Sets in U Fuzzy Sets in V

Fuzzy inference systems

Fuzzifiers (construction of fuzzy sets)With experts knowledge (Direct and indirect

methods)

– Direct methods: Experts give answers to questions thatexplicitly pertain to the constructed membership function.

– Indirect methods: Experts answer simpler questions, easier toanswer, which pertain to the constructed membership functiononly implicitly.

Direct method with one expert and multiple experts

An expert is expected to assign to each given element x ɛX a membership grade A(x) that, according to his or heropinion, best captures the meaning of the linguistic termrepresented by the fuzzy set A.

When a direct method is extended from one expert tomultiple experts, the opinions of individual experts mustbe appropriately aggregated. One of the most commonmethods is based on a probabilistic interpretation ofmembership functions.

Or where

Indirect methods with one and multiple experts

Let xl, x2, . . . , xn, be elements of the universal set X for whichwe want to estimate the grades of membership in A.our problem is to determine the values ai = A (x,) for all i ɛ N.Instead of asking the expert to estimate values ai directly, weask him or her to compare elements x1, x2, . . . , xn, in pairsaccording to their relative weights of belonging to A.

The pairwise comparisons is

And with simplication we have

Construction from sample dataLagrange interpolationLeast square curve fittingConstruction by neural networkConstruction by genetic algorithm

In each of the discussed methods, we assume thatn sample data:

Lagrange curve fitting

ExampleFor this data samples:

We have

Least square curve fittingin this method we chose f

where E is minimized:

One of the best choice isthe bell function:

Therefore the membershipfunction is:

Another choice is thetrapezoidal function:

Example

By NNIn general, constructions by neural networks are

based on learning patterns from sample data.

Defuzzifiers� Defuzzifier :

� Defined as a mapping from fuzzy set B' in V R tocrisp point y* V.

� Conceptually, the defuzzifier is to specify a point in Vthat best represents the fuzzy set B'.

� This is similar to the mean value of a random variable.

� Since the B' is constructed in some special ways,A number of choices there are in determining thisrepresenting point.

⊂∈

Defuzzify: calculate a single-valued output estimate(the “best representative” point within the aggregate).

Defuzzification

Defuzzifiers

� Mean of maximum (MOM)

� Center of area (COA)

� The height method

Mean of maximum (MOM)Calculates the average of those output values

that have the highest possibility degrees

25 500

0.91

X*

Maximum Defuzzification Technique

This method gives the output with the highest membership function.

for all x in X)()( * xx AA µµ ≥

Defuzzification

Center of area (COA)Calculate the center-of-gravity (the weighted

sum of the results)

DefuzzificationCentre of gravity (COG):Centre of gravity (COG):

4.675.05.05.05.02.02.02.02.01.01.01.0

5.0)100908070(2.0)60504030(1.0)20100(=

++++++++++×++++×++++×++

=COG

1.0

0.0

0.2

0.4

0.6

0.8

0 20 30 40 5010 70 80 90 10060Z

Degree ofMembership

67.4

Center of Gravity Defuzzifier

The height methodConvert the consequent membership function

Ci into crisp consequent y = ci

wi is the degree to which the ithrule matches the input data

a b

0.5

0.9

Approximate Reasoning

Outline

Approximate Reasoning

� Fuzzy expert systems

� Fuzzy Implication

� Selection of fuzzy implication

� Multi-conditional approximate reasoning

Expert systemExpert system:

– Knowledge base• Is represented by a set of fuzzy rules.• They have the form “if A then B”, where A and B are fuzzy sets.

– Database• is to store data for each specific task of the expert system.

– Inference engine• Operates on a series of rules and makes fuzzy inferences in two

approaches:– Data-driven (modus ponens).

» Data are supplied to the expert system, to evaluate relevantproduction rules and draw all possible conclusions.

– Goal-driven (modus tollens).» Data specified in the IF clauses of production rules are searches that will

lead to the objective;» these data are found either in the knowledge base, in the THEN clauses

of other production rules, or by querying the user.

Fuzzy expert system� The inference engine may use knowledge regarding the

fuzzy production rules in the knowledge base.

� This type of knowledge, is named meta knowledge.� The meta knowledge unit contains rules about the use

of production rules in the knowledge base.

The knowledge acquisition module, which is included only insome expert systems, makes it possible to update theknowledge base or meta knowledge base through interactionwith relevant human experts.

Approximate Reasoning

Reasoning based on fuzzy productionrules, which is usually referred to as

approximate reasoning.

Fuzzy Implication

• Implication is essential for approximate reasoning.• A fuzzy implication, is a function of the form:

which for any possible truth values a, b of given fuzzy propositions p , q,defines the truth value, y(a, b), of the conditional proposition "if p, then q."

This function should be an extension of the classical implication, p → q,from (0,1) to the [0,1] of truth values in fuzzy logic.

IF A THEN B• In Boolean logic: A ⇒ B

if A is true then B is true

• In fuzzy logic: A ⇒ Bif A is true to some degree then B is true tosome degree.

0.5A => 0.5B (partial premise implies partially)

Fuzzy Implication

Implication OperatorsAs with intersection, union and complement we can defineimplication functions on fuzzy sets.

We can generate an implication function I by assuming:

BABA ∪→ = µµ

),1(),(]1,0[, baSbaIba −=∈∀

Classical implication

S Implications (obtained from 11-2)

Implication

I=max(1-a,b)

1. IF 1+1=2, THEN 4>0 I=Max(1-1,1)=Max(0,1)=12. IF 1+1=3, THEN 4>0 I=Max(1-0,1)= Max(1,1)=13. IF 1+1=3, THEN 4<0 I=Max(1-0,0)= Max(1,0)=14. IF 1+1=2, THEN 4<0 I=Max(1-1,0)= Max(0,0)=0

In the forth case, a true hypothesis cannot producea false conclusion.

R implications (obtained from 11-4)

QL implications (Obtained from 11-7)

Combined implications

�The most popular implication operator in fuzzy control is:I(a,b)=min(a,b)

�Of course, this is really a relation of intersection rather than implication

�However it is the relation suggested by Zadeh and used in allthe earliest fuzzy control models (esp Mandami et al)

�It has some significant advantage in minimising thecomputational complexity if fuzzy inference.

Mandami Implication

Axioms of fuzzy implication

Fuzzy implication

Selection of fuzzy implicationFuzzy inference:

Let us begin with the generalized modus ponens. According to this fuzzyinference rule, given a fuzzy proposition and a fact "X is A'," we concludethat "Y is B’ ” by the compositional rule of inference

If we assume A=A’ and B=B’:

Any fuzzy implication suitable for approximate reasoning based on thegeneralized modus ponens should satisfy this relation for arbitrary fuzzysets A and B.

The following fuzzy implications satisfy the relation for any t-norm i:

fuzzy implications suitable for approximate reasoning based upon thegeneralized modus tollens should satisfy the equation

For the generalized hypothetical syllogism, thefollowing equation must be satisfied:

Multiconditional approximate reasoningThe general schema of multiconditional approximate reasoning has

the form:

This kind of reasoning is typical in fuzzy logic controllers

The most common way to determine B' is referred to as a method ofinterpolation. It consists of the following two steps:

Mamdani Implication