copy Fuzzy Logic - An Introduction PART 2.pptx

jaitwalabhinav 38 views 79 slides Jul 16, 2024
Slide 1
Slide 1 of 79
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18
Slide 19
19
Slide 20
20
Slide 21
21
Slide 22
22
Slide 23
23
Slide 24
24
Slide 25
25
Slide 26
26
Slide 27
27
Slide 28
28
Slide 29
29
Slide 30
30
Slide 31
31
Slide 32
32
Slide 33
33
Slide 34
34
Slide 35
35
Slide 36
36
Slide 37
37
Slide 38
38
Slide 39
39
Slide 40
40
Slide 41
41
Slide 42
42
Slide 43
43
Slide 44
44
Slide 45
45
Slide 46
46
Slide 47
47
Slide 48
48
Slide 49
49
Slide 50
50
Slide 51
51
Slide 52
52
Slide 53
53
Slide 54
54
Slide 55
55
Slide 56
56
Slide 57
57
Slide 58
58
Slide 59
59
Slide 60
60
Slide 61
61
Slide 62
62
Slide 63
63
Slide 64
64
Slide 65
65
Slide 66
66
Slide 67
67
Slide 68
68
Slide 69
69
Slide 70
70
Slide 71
71
Slide 72
72
Slide 73
73
Slide 74
74
Slide 75
75
Slide 76
76
Slide 77
77
Slide 78
78
Slide 79
79

About This Presentation

Fuzzy


Slide Content

INTRODUCTION TO FUZZY LOGIC – Part 2 Dr. LINI MATHEW ASSOCIATE PROFESSOR, ELECTRICAL ENGINEERING DEPARTMENT NITTTR, CHANDIGARH

Three variables of interest in power transistors are the amount of current that can be switched, the voltage that can be switched and the cost. The following membership functions for power transistors were developed from hypothetical components catalog: Average current Average voltage ( a) Find the Cartesian Product P = VxI . FUZZY RELATIONS

The Cartesian Product expresses the relationship between V i and I j , where V i and I j are individual elements in the fuzzy set V and I. A fuzzy set is defined for the cost C in rupees, of a transistor (b)Using Fuzzy Cartesian Product, find T = IxC . (c) Using max-min composition find E = PoT (d) Using max-product composition find E = PoT FUZZY RELATIONS

FUZZY RELATIONS P =

FUZZY RELATIONS T =

FUZZY RELATIONS E =

Logic is but a small part of the human capacity to reason. It is the science of reasoning!! Logic for humans is a way quantitatively to develop a reasoning process that can be replicated and manipulated with mathematical precepts. LOGIC

Logic is the study of truth in logical propositions In classical logic, this truth is binary – a proposition is either true or false. In fuzzy logic, all truths are partial or approximate. LOGIC

Speed = 0 Speed = 1 Classical Logic [0.0 - 0.25] [0.25 – 0.50] [0.50 – 0.75] [0.75 – 1.00] Fuzzy Logic LOGIC

A simple proposition P is a linguistic , or declarative, statement contained within a universe of elements, X , that can be identified as being a collection of elements in X, which are strictly true or strictly false. Example : ( i ) A is B Temperature (A) is high (B) ( ii) (A is B) is C Anju (A) is beautiful (B) is very true (C) PROPOSITIONS

A proposition P is a collection of elements, A set, where the truth values for all elements in the set are either all true or all false. The veracity (truth) of an element in the proposition P can be assigned a binary truth value, called T(P ) PROPOSITIONS

For binary (Boolean) classical logic, T(P)is assigned a value of 1 (truth) or 0 (false). If U is the universe of all propositions, T hen T is a mapping of the elements, u, in these propositions (sets) to the binary quantities (0, 1), or T : u ∈ U -→ (0, 1). PROPOSITIONS

Five logical connectives to combine simple propositions on the same universe of discourse These connectives can be used to form new propositions from simple propositions. LOGICAL CONNECTIVES

disjunction ( ∨ ) conjunction ( ∧ ) negation ( − ) implication ( → ) equivalence ( ↔ ) Disjunction P ∨ Q : x ∈ A or x ∈ B ; T(P ∨ Q) =max(T(P), T(Q)). LOGICAL CONNECTIVES

Conjunction P ∧ Q : x ∈ A and x ∈ B; T(P ∧ Q) = min(T(P), T(Q)). Negation If T(P) = 1, then T(P̅) = 0; If T(P) = 0, then T(P̅) = 1. LOGICAL CONNECTIVES

Implication (P → Q) : x ∉ A or x ∈ B; T(P → Q) = T(P̅ ∪ Q). Equivalence (P ↔ Q) : T(P ↔ Q) = 1, for T(P) = T(Q) = 0, f or T(P) ≠ T(Q) LOGICAL CONNECTIVES

Example: F our propositions: 1. if 1 + 1 = 2, then 4 > 0; 2. if 1 + 1 = 3, then 4 > 0; 3. if 1 + 1 = 3, then 4 < 0; 4. if 1 + 1 = 2, then 4 < 0. The first three propositions are all true; the fourth is false. IMPLICATION

In the first two, the conclusion 4 > 0 is true regardless of the truth of the hypothesis; In the third case both propositions are false, but this does not disprove the implication; In the fourth case, a true hypothesis cannot produce a false conclusion IMPLICATION

The compound proposition P → Q is true in all cases except where a true antecedent P appears with a false consequent, Q, A true hypothesis cannot imply a false conclusion . IMPLICATION

Implication is true for all propositions of P and Q except for those propositions that are in both the truth set of P and the false set of Q. IMPLICATION

In set-theoretic form Linguistically equivalent to the statement “P → Q is true” when either “not A” or “B” is true IMPLICATION

LOGICAL CONNECTIVES

P is a proposition described by set A , which is defined on universe X , Q is a proposition described by set B , which is defined on universe Y . The implication operation : IF P , THEN Q P → Q represented as IF A, THEN B IMPLICATION

In set-theoretic terms, defined by the relation R, as: R = (A × B) ∪ ( Ā × Y) ≡ IF A, THEN B IF x ∈ A, where x ∈ X and A ⊂ X THEN y ∈ B, where y ∈ Y and B ⊂ Y, IMPLICATION

Another rule form: IF A, THEN B, ELSE C. or IF A, THEN B and IF Ā, THEN C. In classical logic, this rule has the form (P → Q) ∧ (P̅ → S); P : x ∈ A , A ⊂ X, Q : y ∈ B , B ⊂ Y and S : y ∈ C, C ⊂ Y . IMPLICATION

The set-theoretic equivalent of this is R = (A × B) ∪ (Ā × C) ≡ IF A, THEN B, ELSE C IMPLICATION

A fuzzy logic proposition, P is a statement involving some concept without clearly defined boundaries. Linguistic statements that tend to express subjective ideas and that can be interpreted slightly differently by various individuals typically involve fuzzy propositions . FUZZY LOGIC PROPOSITION

Most natural language is fuzzy, in that it involves vague and imprecise terms. The truth value assigned to P can be any value on the interval [0, 1]. The assignment of the truth value to a proposition is actually a mapping from the interval [0, 1] to the universe U of truth values, T T : u ∈ U → (0, 1 ). FUZZY LOGIC

Fuzzy propositions are assigned to fuzzy sets. A proposition P is assigned to fuzzy set A; then, T he truth value of a proposition, T(P) = µ A (x) where 0 ≤ µ A ≤ 1 FUZZY LOGIC

Disjunction P ∨ Q : x is A or B; T(P ∨ Q) =max(T (P), T (Q)). Conjunction P ∧ Q : x is A and B; T(P ∧ Q) = min(T (P), T (Q )). FUZZY LOGIC - CONNECTIVES

Negation T(P̅) = 1 - T(P ) Implication (P → Q) : x is A then x is B; T(P → Q) = T(P ̅ ∪ Q) = max(T(P̅), T (Q)). If x is A then y is B ie . R = (A x B) ∪(Ā x Y ) µ R ( x,y ) = max[( µ A (x ) ∧ µ B (y)), (1 - µ A (x ))] FUZZY LOGIC - CONNECTIVES

If x is A then y is B , else y is C R = (A x B) ∪(Ā x C) µ R ( x,y ) = max[(µ A (x) ∧ µ B (y)), (( 1 - µ A (x )) ∧ µ C (y))] FUZZY LOGIC - CONNECTIVES

Evaluating a new invention to determine its commercial potential. Two metrics to be used regarding the innovation of the idea. ( i ) uniqueness of the invention, (ii) market size of the invention’s commercial market, FUZZY INFERENCE

Uniqueness of the invention denoted by a universe of novelty scales, X = {1, 2, 3, 4 } Market size of the invention’s commercial market, denoted on a universe of scaled market sizes, Y = {1, 2, 3, 4, 5, 6 } FUZZY INFERENCE

Scores of a new invention Fuzzy set A = medium uniqueness Fuzzy set B = medium market size Fuzzy set C = diffuse market size Determine the implications ( i ) IF A, THEN B (ii) IF A, THEN B, ELSE C FUZZY INFERENCE

IF A, THEN B IF uniqueness is medium THEN market size is medium R = (A x B) ∪(Ā x Y ) µ R ( x,y ) = max[(µ A (x) ∧ µ B (y)), (1 - µ A (x))] FUZZY INFERENCE

FUZZY INFERENCE

FUZZY INFERENCE

FUZZY INFERENCE

FUZZY INFERENCE R = (A x B) ∪(Ā x Y)

IF A, THEN B, ELSE C IF uniqueness is medium THEN market size is medium , ELSE market size is diffuse R = (A x B) ∪(Ā x C ) µ R ( x,y ) = max[(µ A (x) ∧ µ B (y)), ((1 - µ A (x)) ∧ µ C (y))] FUZZY INFERENCE

FUZZY INFERENCE

FUZZY INFERENCE

Approximate Reasoning C onventional antecedent–consequent form, IF x is A, THEN y is B Suppose a new antecedent, A’, is introduced then IF x is A’, THEN y is B’ FUZZY INFERENCE

The consequent B ’ can be derived by means of fuzzy composition. B ’ =A’ ◦ R a nd R = (A x B) ∪(Ā x Y) FUZZY INFERENCE

The same invention example with the relation R which describes the invention’s commercial potential, the new antecedent A’ describes the uniqueness score of ‘almost high uniqueness’. Using max-min composition B’ = A’oR FUZZY RELATIONS

FUZZY RELATIONS B’=   This derived consequent B ’ is fairly diffuse, where there is no strong (or weak) membership value for any of the market size scores. ( ie . No membership value near 0 or 1)

Classical logical compound propositions that are always true, irrespective of the truth values of the individual simple propositions are called tautologies. Tautologies are useful for reasoning, for proving theorems, and for making deductive inferences . If a compound proposition can be expressed in the form of a tautology, the truth value of that compound proposition is known to be true. TAUTOLOGIES

Inference schemes in expert systems often employ tautologies because tautologies are formulae that are true on logical grounds alone. Some common tautologies are as follows:  B  X A  X ;  X  X (A ∧ (A → B)) → B (modus ponens ) ( (modus tollens )   TAUTOLOGIES

Modus Ponens Deduction, is a very common inference scheme used in forward-chaining rule-based expert systems. It is an operation whose task is to find the truth value of a consequent in a production rule, given the truth value of the antecedent in the rule. Modus ponens deduction concludes that given two propositions, P and P → Q, if both of which are true, then the truth of the simple proposition Q is automatically inferred. TAUTOLOGIES

Modus tollens inference, is used in backward-chaining expert systems. In modus tollens, an implication between two propositions is combined with a second proposition and both are used to imply a third proposition. TAUTOLOGIES

Proof of Modus Ponens TAUTOLOGIES

Truth Table of Modus Ponens TAUTOLOGIES

Proof of Modus Tollens TAUTOLOGIES

Truth Table of Modus Tollens TAUTOLOGIES

Contradictions Compound propositions that are always false , regardless of the truth value of the individual simple propositions constituting the compound proposition, are called contradictions. Eg . If A is the set of all prime numbers on the real line universe, X, then the proposition “A i is a multiple of 4” is a contradiction. TAUTOLOGIES

Equivalence Propositions P and Q are equivalent, that is, P ↔ Q, is true only when both P and Q are true or when both P and Q are false . Eg . the propositions P “triangle is equilateral” and Q “triangle is equiangular” are equivalent because they are either both true or both false for some triangle. The statement P ↔ Q is a tautology, if P is identical to Q, that is, if and only if T(P ) = T(Q ). TAUTOLOGIES

N atural language consists of fundamental terms characterized as atoms in literature . A collection of these atoms will form the molecules, or phrases, of our natural language. Atomic terms - examples : slow , medium, young, beautiful LINGUISTIC HEDGES

A collection of atomic terms is called composite terms Examples: very slow horse, young tree, medium-weight female, fairly beautiful painting . Can be modified with adjectives (nouns) or adverbs (verbs) These modifiers are called linguistic hedges LINGUISTIC HEDGES

Examples of linguistic hedges : very, low, slight , more or less, fairly, slightly, almost, barely, mostly, roughly, approximately etc. T he singular meaning of an atomic term is modified, or hedged, from its original interpretation. Modify the membership function for a basic atomic term. LINGUISTIC HEDGES

A basic linguistic atom be α, and when subject to some hedges. LINGUISTIC HEDGES

Linguistic terms are defined as a mapping onto Y = {1 , 2, 3, 4, 5} “Very small” = “small” 2 = LINGUISTIC HEDGES

“ Not Very Small” = 1 – “Very Small” “ Not Very Small and Not Very, Very Large ” LINGUISTIC HEDGES

Consider two universes of discourse, X and Y, and a functional transform (mapping) of the form y = f(x ). In universe X, there is fuzzy set A. The image of fuzzy set A on X under the mapping f is fuzzy set B , ie . through the same mapping, B = f(A ). EXTENSION PRINCIPLE

The membership functions describing A and B will now be defined on the universe of a unit interval [0, 1], and for the fuzzy case it becomes The image of fuzzy set A can be determined through the use of the composition operation, or B=A◦R, or when using the fuzzy vector form, b= a◦R where R is an n×m fuzzy relation matrix . EXTENSION PRINCIPLE

If the input universe comprises the Cartesian product of many universes. Let fuzzy sets A 1 ,A 2 , . . . ,A n be defined on the universes X 1 ,X 2 , . . . , X n . The mapping for these particular input sets can now be defined as B = f(A 1 ,A 2 , . . . ,A n ), where the membership function of the image B is given by ZADEH’S EXTENSION PRINCIPLE

Further generalizing the situation where a fuzzy input set, say A, maps to a fuzzy output through a fuzzy mapping, or B=f(A). The extension principle can be used to find the fuzzy image, B, by the following expression: ZADEH’S EXTENSION PRINCIPLE

Suppose there is a mapping between elements, u, of one universe, U, onto elements, v, of another universe, V, through a function f . Let this mapping be described by f : u → v. Define A to be a fuzzy set on universe U; ZADEH’S EXTENSION PRINCIPLE

For a function f that performs a one-to-one mapping i.e., maps one element in universe U to one element in universe V. ZADEH’S EXTENSION PRINCIPLE

For cases where this functional mapping f maps products of elements from two universes, say U 1 and U 2 , to another universe V, and we define A as a fuzzy set on the Cartesian space U 1 × U 2 , then : ZADEH’S EXTENSION PRINCIPLE

The complexity of the extension principle increases when we consider more than one of the combinations of the input variables, U 1 and U 2 , mapped to the same variable in the output space, V, that is, the mapping is not one-to-one. In this case, we take the maximum membership grades of the combinations mapping to the same output variable , ZADEH’S EXTENSION PRINCIPLE

Let a fuzzy set A be defined on the universe U = {1, 2, 3}. To map elements of A to another universe, V, under the function v = f(u ) = 2u−1 . The elements of V are V = {1, 3, 5}. The fuzzy set A is given as The fuzzy membership function for v = f (u) = 2u − 1 would be EXTENSION PRINCIPLE - EXAMPLES

Integers 1–10 are the elements of two identical but different universes, U 1 = U 2 = {1, 2, 3, . . . , 10}. Two fuzzy numbers A and B are defined on universes U1 and U2, respectively: A = “approximately 2” = B = “approximately 6” = EXTENSION PRINCIPLE - EXAMPLES

The product of (“approximately 2”) × (“approximately 6”) maps to a fuzzy number “approximately 12,” which is a fuzzy set defined on a universe, V, of integers, V = 5, 6, . . . , 18, 21 EXTENSION PRINCIPLE - EXAMPLES

Two fuzzy sets A and B, each defined on its own universe as follows: The membership values for the algebraic product mapping f(A,B ) = A×B (arithmetic product) EXTENSION PRINCIPLE - EXAMPLES

To map ordered pairs from input universes X 1 = {a, b} and X 2 = {1, 2, 3} to an output universe, Y = {x, y, z}. The mapping is given by the crisp relation, R, This relation represents a mapping, and it does not contain membership values. EXTENSION PRINCIPLE - EXAMPLES

A fuzzy set A is defined on universe X 1 and a fuzzy set B on universe X 2 as To determine the membership function of the output, C = f(A,B), whose relational mapping, f , is described by R. EXTENSION PRINCIPLE - EXAMPLES

C = f(A,B), whose relational mapping, f , is described by R. This is done using the extension principle μ C (x) = max[min(0.2, 0.6), min(0.2, 1), min(0.4 , 0.6)] = 0.4 μ C (y) = max[min(0.8, 1)] = 0.8, μ C (z) = max[min(0.8, 0.6), min(0.4, 1)] = 0.6. Hence EXTENSION PRINCIPLE - EXAMPLES

THANK YOU
Tags