You are on page 1of 29

Approximate reasoning

Dr. C.V. Suresh Babu


Professor
Department of IT
Hindustan Institute of Science & Technology

Soft Computing (ITC4256 ) Department of Information Technology 1


Action Plan

• Truth values and tables,


• Fuzzy propositions,
• Formation of rules decomposition of rules,
• Aggregation of fuzzy rules,
• Fuzzy reasoning‐fuzzy inference systems
• Overview of fuzzy expert system‐
• Fuzzy decision making.
• Quiz at the end of session`

Soft Computing (ITC4256 ) Department of Information Technology 2


Truth values and tables
Truth values have been put to quite different uses in philosophy and logic, being characterized, for
example, as:
• primitive abstract objects denoted by sentences in natural and formal languages,
• abstract entities hypostatized as the equivalence classes of sentences,
• what is aimed at in judgements,
• values indicating the degree of truth of sentences,
• entities that can be used to explain the vagueness of concepts,
• values that are preserved in valid inferences,
• values that convey information concerning a given proposition.

Soft Computing (ITC4256 ) Department of Information Technology 3


Fuzzy propositions

• Fuzzy Proposition:
– The proposition whose truth value is [0,1]
– Classification of Fuzzy Proposition
• Unconditional or Conditional
• Unqualified of Qualified
– Focus on how a proposition can take truth value
from fuzzy sets, or membership functions.

Soft Computing (ITC4256 ) Department of Information Technology 4


Fuzzy Proposition
• Unconditional and Unqualified
p :  is F . p :  (i ) is F .
  Variable that takes values v V  : I  V (Variable is a function of set I to V )
F  Fuzzy set on V , fuzzy predicate F  Fuzzy set on V , fuzzy predicate
F (v)  Membership grade of v.
T ( p)  F (v(i ))
T ( p )  F (v )

– Example: p : age(i ) is young.


p : Air temp. is High. age : { A, B, C}  [0,100]
  Air temp.that takes values v  [0o ,120o ] Young : age(i )  [0,1]
T ( p)  Truth value of " temp  75o is High  F (v)" T ( p)  Young( Age(i ))  F (v)

Soft Computing (ITC4256 ) Department of Information Technology 5


Unconditional and Qualified Propositions
• Truth qualified and Probability qualified
p :  is F is S .
or
p : Pr{ is F } is P.
S  Fuzzy quantifier  A fuzzy set on [0,1]
P  Fuzzy probabilit y quantifier  A fuzzy set on [0,1]
Pr{ is F }  Probabilit y of fuzzy events " is F "

– Truth qualified
“Tina is young is very true”
Age(Tina)  26 F (26)  0.87 T ( p)  S ( F (v))  S (0.87)  0.76

Soft Computing (ITC4256 ) Department of Information Technology 6


Unconditional and Qualified Propositions
– Probability qualified

For any given prob. distribution f on V ,


Pr{ is F }   f (v)  F (v)
vV

T ( p )  P (  f (v )  F (v ))
vV

Example :
p : Pr{temp.t is around 75o } is likely.
– Note: T ( p )  P (0.8)  .95
Truth quantifiers = “True, False” with hedges
Probability quantifiers =“Likely, Unlikely” with hedges

Soft Computing (ITC4256 ) Department of Information Technology 7


Conditional and Unqualified Propositions
• Conditional and Unqualified
p : If X is A, then Y is B.
X, Y  Variables whose values are in set X  Y
A, B  Fuzzy set on X and Y
T ( p)  T ((x, y ))  Ι ( A( x), B( y ))  R( x, y )  Fuzzy Implication relation

– Example with Lukaseiwicz implication


A  .1 / x1  .8 / x2  1. / x3 B  .5 / y1  1. / y2
1 1
R(a, b)  min(1,1  a  b)  .7 1
.5 1
T ( p )  1 when X  x1 , and Y  y1
 0.7 when X  x2 , and Y  y1
Soft Computing (ITC4256 ) Department of Information Technology 8
Conditional and Qualified Propositions
• Conditional and Qualified
p : If X is A, then Y is B is S .
T ( p )  S ( R ( x, y ))
or
p : Pr{X is A | Y is B} is P.
T ( p )  P (Pr{X is A | Y is B})
 R( x, y) f ( x, y)
XY
Pr{X is A | Y is B}  X Y

 B( y) f ( y)
yY
Y

Soft Computing (ITC4256 ) Department of Information Technology 9


Fuzzy Quantifiers
• Absolute Quantifiers
– Fuzzy Numbers:
about 10, much more than 100, at least 5
p : There are Q i' s in I such thatV (i ) is F . Example :
" There are about 10(Q ) students(i) in a given class(I ) " There are about 3(Q ) students(i) in a given class(I )
whosefluency in English(V (i )) is high( F )." whosefluency in English(V (i )) is high( F )."
E (i )  F (V (i )) for all i  I I  {Adam, Bob, Cathy, David, Eve}
T ( p )  Q(| E |) High Flu(V (Adams))  High Flu(35)  0
High Flu(V (Bob))  High Flu(20)  0
High Flu(V (Cathy))  High Flu(80)  0.75
High Flu(V (David))  High Flu(95)  1.
High Flu(V (Eve))  High Flu(70)  0.5
E  2.25 T ( p )  Q(2.25)  0.625

Soft Computing (ITC4256 ) Department of Information Technology 10


Fuzzy Quantifiers
– Fuzzy Number with Connectives
p : There are Q i' s in I such thatV1 (i ) is F1 and V2 (i ) is F2 .
" There are about 10(Q ) students(i) in a given class(I )
whosefluency in English(V1 (i )) is high( F1 ) and who(V2 (i )) are young(F2 )."
E1 (i )  F1 (V1 (i )) and E2 (i )  F2 (V2 (i )) for all i  I
T ( p)  Q(| E1  E2 |)  Q( min[F1 (V1 (i )), F2 (V2 (i ))])
iI

Soft Computing (ITC4256 ) Department of Information Technology 11


Fuzzy Quantifiers
• Relative Quantifier
– Example: “almost all”, “about half”, ”most”
• See Fig. 8.5
p : Among i' s in I such thatV1 (i ) is F1 , there are Qi' s in I
such thatV2 (i ) is F2 .
" Among students(i ) in a given class(I ) that are(V (i )) young(F1 ),
there are almost all( Qi' s) whosefluency in English(V2 (i )) is high( F2 ) ."
E1 (i )  F1 (V1 (i )) and E2 (i )  F2 (V2 (i )) for all i  I

E1  E2  min[ F (V (i)), F (V (i))]


1 1 2 2
W  i
 degree of subsethood
E1  F (V (i))
i
1 1

T ( p)  Q(W )

Soft Computing (ITC4256 ) Department of Information Technology 12


Linguistic Hedges
• Modifiers
– “very”, ”more or less”, “fairly”, “extremely”
– Interpretation
H ( F ( x))  H (a), where a  [0,1]
Example :
very or extremely  H (a)  a 2
fairly or more or less  H (a)  a
– Example: Age(John)=26 Young(26)=0.8
Very Young(26)=0.64
Fairly Young(26)=0.89

Soft Computing (ITC4256 ) Department of Information Technology 13


Inference from Conditional Fuzzy Propositions
• Crisp Case
1. Point from point by function
y  f ( x)
y0  f ( x0 ) if x  x0
2. Intervalfrom interval by function
y  f ( x)
B  f ( A) if x  A
3. Intervalfrom point by relation
B  { y  Y | x, y  R}
4. Intervalfrom interval by relation
B  { y  Y | x, y  R, x  A} or χ B  sup min[ χ A ( x), χ R ( x, y )]
x X

Soft Computing (ITC4256 ) Department of Information Technology 14


Inference from Conditional Fuzzy Propositions
• Fuzzy Case
– Compositional Rule of Inference
Given R, the fuzzy relation on X  Y , A' is a fuzzy set on X , then
B ' ( y )  sup min[ A' ( x), R( x, y )]
xX

or
B '  A'  R

– Modus Ponen
p : If X is A, then Y is B. (Rule)
 R( x, y )  Im(A( x), B( y ))  min(1,1  A( x)  B ( y ))
q : X is A' (Fact)
Y is B ' (New Fact)
B ' ( y )  sup min[ A' ( x), R( x, y )]
x X
Soft Computing (ITC4256 ) Department of Information Technology 15
Inference from Conditional Fuzzy Propositions
– Modus Tollen p : If X is A, then Y is B. (Rule)
 R ( x, y )  Im(A( x), B ( y ))  min(1,1  A( x)  B ( y ))
q : Y is B ' (Fact)
X is A' (New Fact)
A' ( y )  sup min[ B' ( y ), R ( x, y )]
yY

Note : A'  A , B'  B in crisp case.

– Hypothetical Syllogism
p : If X is A, then Y is B. (Rule 1)  R1 ( x, y )  Im(A( x), B( y ))
q : If Y is B, then Z is C. (Rule 2)  R2 ( y, z )  Im(B( y ), C ( z ))
If X is A, then Z is C. (Conclusion)  R3 ( x, z )  Im(A( x), C ( z ))
R3 ( x, z )  sup min[ R1 ( x, y ), R2 ( y, z )]
yY

Soft Computing (ITC4256 ) Department of Information Technology 16


Aggregation of fuzzy rules

• The process of obtaining the overall conclusion from the individually mentioned consequents
contributed by each rule in the fuzzy rule this is known as aggregation of rule.
• (1) Conjunctive system of rules
• The rules that are connected by “AND” connectives satisfy the connective system of rules. In this
case, the aggregated output may be found by the fuzzy intersection of all individual rule
consequents.
• (2) Disjunctive system of rules
• The rules that are connected by “OR” connectives satisfies the disjunctive system of rules. In this
case, the aggregated output may be found by the fuzzy union of all individual rule consequents

Soft Computing (ITC4256 ) Department of Information Technology 17


Properties of set of rules

The properties for the sets of rules are


– Completeness,
– Consistency,
– Continuity, and
– Interaction.
(a) Completeness
A set of IF–THEN rules is complete if any combination of input values result in an appropriate output value.
(b) Consistency
A set of IF–THEN rules is inconsistent if there are two rules with the same rules-antecedent but different rule-
consequents.
(c) Continuity
A set of IF–THEN rules is continuous if it does not have neighbouring rules with output fuzzy sets that have empty
intersection.
(d) Interaction
In the interaction property, suppose that is a rule, “IF x is A THEN y is B,” this meaning is represented by a fuzzy relation
R2, then the composition of A and R does not deliver B

Soft Computing (ITC4256 ) Department of Information Technology 18


Fuzzy reasoning‐fuzzy inference systems

• Fuzzy Inference Systems(FIS)


• •Known as fuzzy rule-based systems, fuzzy model, fuzzy expert system, and fuzzy associative
memory.

• •The FIS formulates suitable rules and based upon the rules the decision is made.

• •Mainly based on the concepts of the fuzzy set theory, fuzzy IF–THEN rules, and fuzzy reasoning.

Soft Computing (ITC4256 ) Department of Information Technology 19


Fuzzy Inference Systems (FIS)

Fuzzy Inference Methods


Mamdani Fuzzy Inference Model
-Commonly used
-Introduced by Mamdani and Assilian in 1975
-Uses fuzzy sets as rule consequent
Sugeno or Takagi-Sugeno-Kang method
-Introduced by Sugeno in 1985
-Employs linear functions of input variables as rule consequent
All the existing results on fuzzy systems as universal approximators deal with Mamdani fuzzy sys-
tems only and no result is available for TS fuzzy systems with linear rule consequent.

Soft Computing (ITC4256 ) Department of Information Technology 20


Construction and Working Of FIS

Construction and Working of Inference System


-Consists of a fuzzification interface, a rule base, a database, a decision-making unit, and finally a defuzzification
interface.
The function of each block is as follows:
– a rule base containing a number of fuzzy IF–THEN rules;
– a database which defines the membership functions of the fuzzy sets used in the fuzzy rules;
– a decision-making unit which performs the inference operations on the rules;
– a fuzzification interface which transforms the crisp inputs into degrees of match with linguistic values;
– a defuzzification interface which transforms the fuzzy results of the inference into a crisp output.

Soft Computing (ITC4256 ) Department of Information Technology 21


Working Of FIS

Working of FIS:
Conversion of crisp input to fuzzy by fuzzification
Formation of rule base
(Rule base and database are referred jointly as knowledge base) Defuzzification-Conversion of fuzzy
value to real world values
Exact steps:
1. Compare the input variables with the membership functions on the antecedent part to obtain
the membership values of each linguistic label. (this step is often called fuzzification.)
2. Combine (through a specific t-norm operator, usually multiplication or min) the membership
values on the premise part to get firing strength (weight) of each rule.
3. Generate the qualified consequents (either fuzzy or crisp) or each rule depending on the firing
strength.
4. Aggregate the qualified consequents to produce a crisp output. (This step is called
defuzzification.)

Soft Computing (ITC4256 ) Department of Information Technology 22


Overview of fuzzy expert system

Expert User

Knowledge Explanatory
Aq. Module Interface

Knowledge Inference Data Base


Base Engine (Fact)

Meta KB
Expert System

Soft Computing (ITC4256 ) Department of Information Technology 23


Expert System

– Knowledge Base (Long-Term Memory)


• Fuzzy Production Rules (If-Then)
– Data Base (Short-Term Memory)
• Fact from user or Parameters
– Inference Engine
• Data Driven (Forward Chaining, Modus Ponen)
• Goal Driven (Backward Chaining, Modus Tollen)
– Meta-Knowledge Base
– Explanatory Interface
– Knowledge Acquisition Module

Soft Computing (ITC4256 ) Department of Information Technology 24


Advantages of rule-based expert system

Natural knowledge representation – an expert usually explains the problem-solving procedure with “In
such-and-such situation, I do so-and-so”. represented quite naturally as IF-THEN production rules.

• Uniform structure: production rules have uniform IF-THEN structure. Each rule is an independent
piece of knowledge (self-documented)

• Separation of knowledge from its process


The structure provides an effective separation of the knowledge base from the inference engine. This
makes it possible to develop different applications using the same expert system shell.
• Dealing with incomplete and uncertain knowledge

Capable of representing and reasoning with incomplete and uncertain knowledge

Soft Computing (ITC4256 ) Department of Information Technology 25


Disadvantages of rule-based expert systems

Opaque relations between rules.


Although individual production rules are relatively simple and self-documented, their logical interactions
within large set of rules may be opaque. Rule-based systems make it difficult to observe how individual
rules serve the overall strategy.
• Ineffective search strategy

The inference engine applies an exhaustive search through all the production rules during each cycle with
a large set of rules (over 100 rules) can be slow, and thus large rule-based systems can be unsuitable for
real-time applications
•Inability to learn

In general, rule-based expert systems do not have an ability to learn from experience.
Unlike a human expert, who knows when to “break the rules”, an expert system cannot automatically
modify its knowledge base, or adjust existing rules or add new ones.

Soft Computing (ITC4256 ) Department of Information Technology 26


Fuzzy decision making

By decision-making in a fuzzy environment is meant a decision process in which the goals and/or the
constraints, but not necessarily the system under control, are fuzzy in nature. This means that the
goals and/or the constraints constitute classes of alternatives whose boundaries are not sharply
defined.
Steps for Decision Making
Let us now discuss the steps involved in the decision making process −
Determining the Set of Alternatives − In this step, the alternatives from which the decision has to be
taken must be determined.
Evaluating Alternative − Here, the alternatives must be evaluated so that the decision can be taken
about one of the alternatives.
Comparison between Alternatives − In this step, a comparison between the evaluated alternatives is
done.

Soft Computing (ITC4256 ) Department of Information Technology 27


1. What is the Fuzzy Approximation Theorem(FAT) ?
a) fuzzy system can model any continuous system
B. The conversion of fuzzy logic to probability.
C. A continuous system can model any fuzzy system.
D. Fuzzy patches covering a series of fuzzy rules.
2. Fuzzy logic is usually represented as ___________
a) IF-THEN-ELSE rules
b) IF-THEN rules
c) Both IF-THEN-ELSE rules & IF-THEN rules
d) None of the mentioned
Test Yourself
3. The values of the set membership is represented by ___________
a) Discrete Set
b) Degree of truth
c) Probabilities
d) Both Degree of truth & Probabilities
4. When capturing tacit knowledge, which of the following technologies would not be used?
a) Fuzzy logic systems
b) Expert systems.
c) Case-based reasoning.
d) Virtual reality
5. The inference engine is:
a) A method of organizing expert system knowledge into chunks.
b) A strategy for searching the rule base in an expert system that begins with information entered by the user.
c) The programming environment of an expert system.
d) A strategy used to search through the rule base in an expert system.
Soft Computing (ITC4256 ) Department of Information Technology 28
1. What is the Fuzzy Approximation Theorem(FAT) ?
a) fuzzy system can model any continuous system
B. The conversion of fuzzy logic to probability.
C. A continuous system can model any fuzzy system.
D. Fuzzy patches covering a series of fuzzy rules.
2. Fuzzy logic is usually represented as ___________
a) IF-THEN-ELSE rules
b) IF-THEN rules
c) Both IF-THEN-ELSE rules & IF-THEN rules
d) None of the mentioned
3. The values of the set membership is represented by ___________
a) Discrete Set
Answers
b) Degree of truth
c) Probabilities
d) Both Degree of truth & Probabilities
4. When capturing tacit knowledge, which of the following technologies would not be used?
a) Fuzzy logic systems.
b) Expert systems.
c) Case-based reasoning.
d) Virtual reality.
5. The inference engine is:
a) A method of organizing expert system knowledge into chunks.
b) A strategy for searching the rule base in an expert system that begins with information entered by the user.
c) The programming environment of an expert system.
d) A strategy used to search through the rule base in an expert system.
Soft Computing (ITC4256 ) Department of Information Technology 29

You might also like