5. lecture fuzzy systems...• the resulting controller can be the described link between inputs and...

30
5. Lecture Fuzzy Systems Fuzzy Control Soft Control (AT 3, RMA)

Upload: others

Post on 24-Jul-2020

0 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

5. Lecture

Fuzzy Systems

Fuzzy Control

Soft Control

(AT 3, RMA)

Page 2: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

120 WS 17/18 Georg Frey

5. Structure of the lecture

1. Introduction Soft Control: Definition and delimitation, basic of 'intelligent'

systems

2. Knowledge representation and knowledge engineering (symbolic AI)

Application: Expert Systems

3. FuzzySystems: dealing with fuzzy knowledge

Application: Fuzzy control

1. Fuzzy-Quantity

2. Fuzzy-Relations, Fuzzy-Inference

3. Fuzzy-System, Fuzzy-Control

4. Connective Systems: Neural Networks

Application: Identification and neural control

5. Genetic algorithms, Simulated annealing, Differential evolution

Application: Optimization

6. Summary & References

Page 3: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

121 WS 17/18 Georg Frey

Contents of the Lecture 5.

1. Fuzzy Systems

1. Fuzzification

2. Defuzzyfying

3. Operation of the overall system

2. Fuzzy Control

1. Rules

2. Control

3. Fuzzy Control

4. Design Process

3. Summary

Page 4: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

122 WS 17/18 Georg Frey

Fuzzy System

• engl.: Fuzzy system

System, that used linguistic rules and with the help of the partial blocks

fuzzification, inference and defuzzyfying, mapped the numeric input variables

to numeric output variables

(VDI/VDE 3550)

Fuzzification Inference Defuzzyfication

Page 5: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

123 WS 17/18 Georg Frey

Fuzzification

• engl.: fuzzification

Conversion of a numeric size in a degree of membership to linguistic

expressions of a linguistic size

(VDI/VDE 3550)

Fuzzification Inference Defuzzyfication

Page 6: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

124 WS 17/18 Georg Frey

Fuzzification

• Transition from a sharp signal value X to a fuzzy signal value X*

• Assignment of the degrees of membership for all linguistic terms of the

corresponding linguistic variable

• For n linguistic terms, there is a n-tuples of degrees of membership

In the fuzzification, a sharp signal is not transferred in a fuzzy-quantity, but in a

vector of sharp degrees of memberships of fuzzy-quantities

1

0

μ

T/°C

50 100 0

very low low very high high medium

T = 58°C T * = (0 0 0.5 0.15 0)

0.5

0.15

Page 7: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

125 WS 17/18 Georg Frey

Example for Fuzzification

• T1 = 28 °C T1*= (0 0,8 0 0 0) The temperature T1 = 28 °C is low

• T2 = 58°C T2*= (0 0 0,5 0,15 0) The temperature T2 = 58 °C is between medium and high, more medium

• T3 = 95°C T3*= (0 0 0 0 1) The temperature T3 = 95 °C is very high

0

μ

T/°C

50 100 0

very low low very high high medium

T2 = 58°C

0.5

0.15

1

T3 = 95°C T1 = 28°C

0.8

Page 8: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

126 WS 17/18 Georg Frey

Defuzzyfication

• Engl.: defuzzyfication

Conversion of a fuzzy-quantity in a numeric output value (e.g. in a control

variable).

(VDI/VDE 3550)

Fuzzification Inference Defuzzyfication

Page 9: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

127 WS 17/18 Georg Frey

Thoughts about Defuzzyfication

• The output fuzzy-quantity represents a activation function

• Question: What exact value best describes the result of the inference?

• Basic Ideas:

Maxima of the function:

Value, that is the maximum in the fuzzy quantity

(Problem: Definition by multiple maxima)

"Middle" of the area

Center or median of the area under the curve

(Problem: complex calculation)

• Methods

Maximum-Defuzzyfication

gravity method

Area median method

• First an example

Page 10: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

128 WS 17/18 Georg Frey

Example: linguistic variables

1

0

μ

T/°C

50 100 0

very low low very high high medium

1

0

μ

W/%

50 100 0

very low low very high high medium

Page 11: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

129 WS 17/18 Georg Frey

Example: rule base and factum

Rule base

• R1: IF T = very low THEN W = very high

• R2: IF T = low THEN W = high

• R3: IF T = medium THEN W = medium

• R4: IF T = high THEN W = low

• R5: IF T = very high THEN W = very low

• Input Variable: T = 15 °C

1

0

μ

T/°C

50 100 0

very low low very high high medium

1

0

μ

W/%

50 100 0

very low low very high high medium

1

0

μ

W/%

50 100 0

very low low very high high medium

0.75

0.25

Fuzzification: T * = (0.75 0.25 0 0 0)

Page 12: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

130 WS 17/18 Georg Frey

Example: Accumulation (MAX)

1

0

μ

W/%

50 100 0

Very Low Low Very High High Medium

1

0

μ

W/%

50 100 0

Very Low Low Very High High Medium

1

0

μ

W/%

50 100 0

Very Low Low Very High High Medium

0.75

0.25

μ

W/%

50 100

Very High High 1

0

0.75

0.25

Page 13: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

131 WS 17/18 Georg Frey

Maximum-Defuzzyfication

• Where is the maximum ?

Mean-of-Maxima (mean value of the

Maxima)

Smallest-of-Maxima (first Maximum)

Largest of maxima (last peak)

μ

W/%

50 100

Very High High 1

0

0.75

0.25

μ

W/%

50 100

Very High High 1

0

0.75

0.25

μ

W/%

50 100

Very High High 1

0

0.75

0.25

μ

W/%

50 100

Very High High 1

0

0.75

0.25

MOM: YD = 93.75 SOM: YD = 87.5 LOM: YD = 100

Evaluation

Simple Calculation

Only rules with a maximum degree of fulfillment go to the result (usually one)

The degree of fulfillment of the rule is not taken into account (for MOM and

triangular-structured ZGF, others partially).

Range boundaries are not always possible (depends on ZGF)

Discontinuous output values

Page 14: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

132 WS 17/18 Georg Frey

Gravity method

• General

= Center of

gravity (COG)

μ

W/%

50 100

Very High High 1

0

0.75

0.25

Evaluation

All the rules are taken into account

Continuous output values

Levels of fulfillment are taken into account

Complex calculation

Range boundaries are not possible ( Advanced gravity method)

dyy

dyyy

yD

COG: YD =

• Simplified

or for Singletons

= Center of singletons

(COS), centroide

μ

W/%

50 100

Very High High 1

0

0.75

0.25

n

i

i

n

i

ii

D

y

yy

y

1

1

COS: YD = 85

Page 15: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

133 WS 17/18 Georg Frey

Area median method

• = Center of

area (COA)

μ

W/%

50 100

Very High High 1

0

0.75

0.25

Evaluation (almost like in gravity method)

All the rules are taken into account

Continuous output values

Levels of fulfillment are taken into account

Complex calculation (more complex than in gravity method)

Range boundaries are not possible

For singletons in output Fuzzy-Quantities unsuitable

D

D

y

y

D dyydyymity

COA: YD =

Page 16: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

134 WS 17/18 Georg Frey

Operation of a Fuzzy-System

1. Fuzzification Determination of the degrees of membership of the sharp input variables to the Input-Fuzzy-Quantities

2. Aggregation (premise analysis) Determination of the levels of fulfillment of the single rule premises (Determination of active rules)

3. Activation Determination of the single Output-Fuzzy-Quantities (for each rule)

4. Accumulation Overlap of the single Output-Fuzzy-Quantities to an overall Output-Fuzzy-Quantity (function of attractiveness)

5. Defuzzyfication Determination of the sharp output values from the function of attractiveness

Page 17: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

135 WS 17/18 Georg Frey

Application: Fuzzy control

• Basics

Properties of a scheme

Properties of a control

Comparison of control (close loop and open loop)

• Fuzzy control

Application of a Fuzzy-System to control

• Design Methodology

Page 18: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

136 WS 17/18 Georg Frey

Block diagram of a control

Process variable

route Actuators

Sensors

Control element

Control output

reference variable w

-

Feedback variable

Comparing

element

Algorithm

Disturbances (incl. EMC, environment, ... )

Disturbances (incl. EMC, environment, ... )

Control

Characteristics

• Sphere of influence, where variables continuously retroact to themself

• Continuous values

• Standardized task: disturbance correction, tuning the reference variable

Example: Balancing of an inverted pendulum

Page 19: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

137 WS 17/18 Georg Frey

Control

Block Diagram

Output variables Control Part

Control Signals Input Variables

route

Actuator feedback

Actuators

Sensors Feedback variables

Disturbances (incl. EMF, environment, ...)

Disturbances (incl. EMF, environment, ...)

Algorithms

Characteristics

• Variables in the loop do NOTcontinously retroact themselves

• Binary values

• No standardized task

Example: Positioning of an inverted pendulum

Page 20: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

138 WS 17/18 Georg Frey

„Always restart, "not standardized bar: usually extensive

Rules can be applied“

„Always same“, standardized: „Controlled variable adjust the reference input“

Specification

Always several loops/mehrschleifig, i.e. several hundred sensors and actuators Complexity

>95% of control loops are one-loop/einschleifig (1 Sensor, 1 Actuator)

Number of signals

Variables in loop effects other variables

Variables in loop retroact themselves

Feedback variables

discrete continous Variables

Boolean Algebra, Automata, Petri Nets

Differential equations

Mathematics

Amplifier loop

Disturbances

Feedback system

No amplifier loop Amplification loop is defined Stability problem

only known in advance and trackable disturbances can be corrected

unknown disturbances can be corrected

Asynchronous binary feedback variables( Events)

Permanently synchronised closed loop

Control Automation

Comparison of Automation and Control

Page 21: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

139 WS 17/18 Georg Frey

Fuzzy-Control

• Fuzzy controller (fuzzy controller) can be used for regulatory as well as for control tasks. Often combinations of the two are found.

• The resulting controller can be the described link between inputs and outputs

Characterstics curve

In general not-linear

Application of a fuzzy system for the control and automation

(Control)

Fuzzy controllers are not novel controller types. They belong to the class of nonlinear curves or

Characterstics diagram controller.

However, there are new design methods and the interpretation of results.

Page 22: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

140 WS 17/18 Georg Frey

m

1

negative-up positive-up

positive-down negative-down

middle-up

180 120 90 0 -90 -120 -180

0

negative- up

middle-

up

negative-

up

positive-

down

positive-

up

-30 30

Fuzzy Control in the example of inverted pendulum

Regel 1:

IF Pendulum angle

positiv-down AND

Angular acceleration negative

AND Wagon position

middle

THEN acceleration should be

negative

Page 23: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

141 WS 17/18 Georg Frey E

Swing up with Fuzzy Controller

Page 24: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

142 WS 17/18 Georg Frey

Static characteristics of fuzzy controllers

Control base:

R1: IF e = NG THEN u = NG

R2: IF e = NU THEN u = NU

R3: IF e = PG DANN u = PG

• Examples with mixed Degree of overlap Input fuzzy quantities

• Max-Min-Inference

• COS-Defuzzification

Page 25: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

143 WS 17/18 Georg Frey

Control and Variables characteristics

Control variale y Variable u

Page 26: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

144 WS 17/18 Georg Frey

Example with two input variables

Page 27: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

145 WS 17/18 Georg Frey

Design parameters of a fuzzy controller

Fuzzification Inference Defuzzification

Control base

y

ZGF ZGF Input variables

Output variables

x

Problem oriented design parameters

Method oriented design parameters

Defuzzification methods

Inference- methods

(see 4. VL)

•Premise evaluation: Operators for AND and OR

(t-Norm und s-Norm) • Activation:

Operator for the closing of the Premise

Conclusion (t-Norm) • Accumulation:

Operator for the summary of

single control output (s-Norm)

Page 28: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

146 WS 17/18 Georg Frey

Design process of a fuzzy controller

Design process

1. Defining the parameters method

2. Defining the parameters problem

1. Define the linguistic variables and the number of terms

2. Defining the membership functions

3. Defining the rules (expertise)

3. Simulation using a model (if possible)

4. Implementation

Depending on the result of 3 (or 4): Optimization through interventions in 2 (or 1)

• Note: Even method parameters usually have not much influence on the behaviour

• method parameters will be partially used by the design tool set

Design process = method for determining the method and parameters of the problem

Page 29: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

147 WS 17/18 Georg Frey

Dynamic fuzzy controller

• Fuzzy controllers are initially static

• Dynamic behaviour can only be produced by external components are

Post-processing of output variables(integration)

pre-processing of input variables (Derivation)

• Example: Fuzzy-PID-Controller

Page 30: 5. Lecture Fuzzy Systems...• The resulting controller can be the described link between inputs and outputs Characterstics curve In general not-linear Application of a fuzzy system

SC

148 WS 17/18 Georg Frey

Summary and learning for 5th Lecture

To know the concept of fuzzy system

Fuzzification

Apply and describe the methods of De-fuzzification

Functionality of Fuzzy sytems

Concept of fuzzy controller with respect to with control and regulation

Design process of fuzzy controller