# Fuzzy

Document Sample

```					Fuzzy Sets and Control
Fuzzy Set Definition
The definition of a fuzzy set is given by the membership function

F : U  0,1
~

elements of the universe of discourse U, can belong to the fuzzy set with
any value between 0 and 1.

The degree of membership of an element u

0   F (u )  1
~

when the universe of discourse U, is discrete and finite, it is given for a
fuzzy set A by
 A ( x1 )        A ( x2 )             A ( xi )
A     ~
     ~
       ~

~          x1               x2         i          xi
Fuzzy Set Operations
The union of two fuzzy sets      C  A B                    is defined by
~       ~       ~

 C ( x)  max   A ( x), B ( x) 
                   
~                              ~            ~   

The intersection of two fuzzy sets                  C  AB              is defined by
~        ~       ~

 C ( x)  min   A ( x), B ( x) 
                   
~                          ~            ~   

The complement of fuzzy set A,               C               is defined by

 C ( x)  1   A ( x)
~                            ~
Properties of Set Operations

Most of the properties that hold for classical sets (e.g., commutativity, associativity and idempotence) hold
also for fuzzy sets except for following two properties:

Law of contradiction                       A A  
~    ~

the intersection of a fuzzy set and its complement results in a fuzzy set with membership values of up to ½
and thus does not equal the empty set (as in the case of classical sets)

Law of excluded middle                   A A U
~    ~
Intelligent Control
• An intelligent control system is one in which a physical system or a
mathematical model of it is being controlled by a combination of a
knowledge-base, approximate (humanlike) reasoning, and/or a
learning process structured in a hierarchical fashion.

• Under this simple definition, any control system which involves fuzzy
logic, neural networks, expert learning schemes, genetic algorithms,
genetic programming or any combination of these would be
designated as intelligent control.
Fuzzy Control
•   A fuzzy controller consists of three operations:

(1) fuzzification,
(2) inference engine, and
(3) defuzzification.

•   A common definition of a fuzzy control system is that it is a system which emulates a human
expert. In this situation, the knowledge of the human operator would be put in the form of a set of
fuzzy linguistic rules.

•   The human operator observes quantities by observing the inputs, i.e., reading a meter or
measuring a chart, and performs a definite action (e.g., pushes a knob, turns on a switch, closes a
gate, or replaces a fuse) thus leading to a crisp action

•   The human operator can be replaced by a combination of a fuzzy rule-based system (FRBS) and
a block called defuzzifier. The input sensory (crisp or numerical) data are fed into FRBS where
physical quantities are represented or compressed into linguistic variables with appropriate
membership functions.

•   These linguistic variables are then used in the antecedents (IF-Part) of a set of fuzzy rules within
an inference engine to result in a new set of fuzzy linguistic variables or consequent (THEN-Part).
Variables are combined and changed to a crisp (numerical) output.
Fuzzy Control Architecture

System

Defuzzifier
Fuzzifier

Engine
Rule

real                                             real
numbers                                          numbers

member                         Fuzzy                           fuzzy
ship                                                           sets
values                         Controller
Simple Rules – if antecedent then consequent
Ex: fuzzyControlForDec

neg   ( x)dx
consequent- cuts
tts fuzzy set and
computes its area
fuzzifier – accepts                                                                    and moment
real number                       if x  neg then y  pos        x   neg   ( x)dx
inpuit and outputs
its membership

if x  pos then y  neg

defuzzifier –
common                                                                                accumulates the
domain input, x                                                                       areas and moments
and outputs the
centroid
if x  zero then y  zero
Simple Rule Controller

fuzzyControlForDec
provides the
negative feedback
to stabilize the
integrator
Composite Rules –
if antecedent1 and antecedent2 then consequent
Example: fuzzControlFor2To1
AndFn
outputs
minimum
of inputs

x
if   pos and   pos then F  neg

common
domain                          if   zero and   zero then F  zero
input, x

v

common             if   neg and   neg then F  pos
domain
input, v
CompositeRule Controller

fuzzyControlFor2To
1 provides the
control to settle the
spring at zero
Linear Time Invariant Models

 x                y  C  x

 A x
[u ]      B u 

 x   A x    B u 
[ y ]  C  x 
Inverted Pendulum Fuzzy Control

Linearized inverted
pendulum on a cart

fuzzyControlFor2To1
provides the control to
keep the stick stable
Modeling the Inverted Pendulum
Source: http://www.engin.umich.edu/group/ctm/examples/pend/invpen.html
Moment of Inertia: http://hyperphysics.phy-astr.gsu.edu/hbase/mi2.html#rlin

M        mass of the cart                       0.5 kg

m        mass of the pendulum                   0.5 kg

b        friction of the cart                   0.1 N/m/sec

l        length to pendulum center of mass      0.3 m

I        inertia of the pendulum                0.006 kg*m^2

F        force applied to the cart

x        cart position coordinate

theta    pendulum angle from vertical
Inverted Pendulum – Swing Up Non-linear Model
source: http://www.control.lth.se/publications/fulldocs/ast_fur96.pdf
Original Model
0
d

dt
d
J      mgl sin   mlu cos 
dt
J =inertia of rod
detect when angle
m=mass of rod                                                                    detect when
reaches turn-off
g =gravity of rod              level   turnoff                                pendulum stops
rising
l =half length of rod
u =horizontal force

Dimensionless model
d
dt

detect when             reset theta to 0

d                                          pendulum stops          when reach 2*pi
  sin   gain( ,  ) cos           rising
dt
gain( ,  )  k if      turnoff    0
 0, otherwise

starting from hanging configuration, rod can be made to reach inverted configuration with
sufficient force acting until horizontal line is reached

```
DOCUMENT INFO
Shared By:
Categories:
Tags:
Stats:
 views: 22 posted: 11/29/2011 language: English pages: 15
How are you planning on using Docstoc?