Title: FLEA
1FLEA
- Prof. dr. ir. J. Hellendoorn
2Contents
- Fuzzy modeling
- Fuzzy control
- Fuzzy modeling and fuzzy control
- Takagi-Sugeno control
- Heuristic fuzzy control
- Sliding mode control
3Basic notions in control theory
- The open-loop system (process, plant)
- x f(x,u,t) state equation
- y g(x,u,t) output equation
- where
- x (x1, x2 , , xn) is a state vector
- y (y1, y2 , , yn) is an output vector
- u (u1, u2 , , un) is an input vector
- f, g are nonlinear vector-valued functions
4Linear time invariant systems
- x Ax Bu state equation
- y Cx output equationwhere
- A(nn), B(nm), C(rn) are system matrices
- For the discrete case
- x(k 1) Ax(k) Bu(k)
- y(k) Cx(k)
5A linear system
D
B
?
C
x(t)
x(t)
u(t)
y(t)
A
6Linearized nonlinear system I
- x f(x,u,t)can be linearized around an
equilibrium point xd and its corresponding ud. - x Ad x Bd uwhere
7Linearized nonlinear system II
- Then the behavior of the nonlinear system in the
neighborhood of (xd, ud) can be analyzed by
studying the behavior of the linear system - In particular, if the linear system is
asymptotically stable in a region ? around (xd,
ud), so is the nonlinear system.
8Stabilization nonlinear I
- Find a control law u h(x, t)such that the
closed-loop system x f(x, g(x, t), t)is
asymptotically stable in a region ? around some
desired (setpoint) xd. - That is, starting anywhere in ? we will have x
xd ? 0 as t ? ?
9Stabilization nonlinear II
- If ? is small then the stabilization problem can
be solved by linearization of the nonlinear
system around xd. - If ? is large then linearization will not work.
10Stabilization linear I
- Find a control law u Kxsuch that the
closed-loop system x Ax BKxis
asymptotically stable in a region ? around some
desired (setpoint) xd. - That is, starting anywhere in ? we will have x
xd ? 0 as t ? ?
11Stabilization linear II
- For linear systems, if the system is
asymptotically stable in ?, then it is
asymtotically stable in the large.
12P, PD-controllers
- P-controllers
- u KP e, where e xd x
- find a KP such that e ? 0 as t ? ?
- PD-controllers
- u KP e KD e
- find a Kp and KD such that e ? 0 as t ? ?
13PID-controllers
- PID-controller
- u KP e KD e KI
- find a Kp, KD and KI such that e ? 0 as t ? ?
14Fuzzy models
- Pure fuzzy models
- Takagi-Sugeno models
- Fuzzy approximation of conventional nonlinear
models
15Fuzzy controllers
- Model based
- On pure fuzzy models
- On TS-models
- On fuzzy approximations
- On nonlinear models
- Heuristic controllers
- Fuzzy PID
- Fuzzy controllers for ill-structured systems
16Types of nonlinearities I
- Nonlinearities due to simple analytic functions
such as powers, sinusoids, exponentials of a
single state variable or products of state
variables - Functions that possess convergent
Taylor-expansions at all points and thus can be
approximated by linear expressions in the
neighborhood of any desired xd.
17Types of nonlinearities II
- Piecewise linear approximations which consist of
a stet of linear functions describing the overall
system in different regions of the state space. - The dynamical equations become linear in any
particular region and the controllers for
different regions can be joined at the boundaries.
18Saturation, dead zone, relay
y
saturation
u
dead zone
y
ideal relay
u
19Relay with hysteresis
y
u
20Pure fuzzy models
e
xd
e
p
- x is the water level
- A pump p
- A valve v with a disturbance so that water can
flow out of tank - xd desired water level
- Error e x xd
- Input u (the amount of water pumped in or out
v
21Control problem
- Keep error as close to zero at all times, without
knowing the disturbance. - I.e., find a u such that e(k) ? 0, as k ? ?, for
each initial state.
22The linguistic model I
- Linguistic values for e
- e is NBe x xd lt 0 and big
- e is NSe x xd lt 0 and small
- e is ZEe x xd 0
- e is PSe x xd gt 0 and small
- e is PBe x xd gt 0 and big
23The linguistic model II
- Linguistic values for u
- u is NBu big amount pumped out
- u is NSu small amount pumped out
- u is ZEu no action
- u is PSu small amount pumped in
- u is PBu big amount pumped in
24The linguistic model III
e(k1)
25Rules
- Each matrix element is a linguistic rule of the
form - If e(k) is NBe and u(k) is PBu then e(k1) is ZEe
26General rules
- If e(k) is LEi and u(k) is LUi then e(k1) is LEi
where LEi ? NBe, NSe, ZEe, PSe, PBeand LUi ?
NBu, NSu, ZEu, PSu, PBu
27The linguistic model
- The fuzzy sets representing the linguistic values
of e and u
NB
NS
ZE
PS
PB
1
0
28A linguistic rule
- A linguistic relation on e ? u ? e
- The set of all linguistic rules is the union of
the fuzzy relations Ri presented above.
29Computing with a fuzzy model I
- Given input values for e and u, say LEin and LUin
at k the fuzzy input is - Given the fuzzy relation R corresponding to all
rules and LEin?LUin , the output at k1 is
30Computing with a fuzzy model II
- Where LEout is the value of error at k1.
- Thus the open-loop system is
31The fuzzy controller
- The fuzzy controller is of the formwhere K is
a fuzzy relation on e ? u. - The closed-loop system then is
32The design problem
- For a desired LEdes(k1) find a K such
thatfor each initial LE
33Example
- For our example suppose LEdes(k1) ZEe
- ZEe (k1) (NBe(k) ? ? ) o R
- ZEe (k1) (NSe(k) ? ? ) o R
- ZEe (k1) (ZEe(k) ? ? ) o R
- ZEe (k1) (PSe(k) ? ? ) o R
- ZEe (k1) (PBe(k) ? ? ) o R
34The fuzzy model for ZEe (k1)
e(k1)
35The question marks
- Thus from
- ZEe (k1) (NBe(k) ? PBu(k) ) o R
- ZEe (k1) (NSe(k) ? PSu(k) ) o R
- ZEe (k1) (ZEe(k) ? ZEu(k) ) o R
- ZEe (k1) (PSe(k) ? NSu(k) ) o R
- ZEe (k1) (PBe(k) ? NBu(k) ) o R
36Conditions on K
- Therefore, K must be such that for each K
- NBe(k) o K PBu(k)
- NSe(k) o K PSu(k)
- ZEe (k) o K ZEu(k)
- PSe (k) o K NSu(k)
- PBe (k) o K NBu(k)
37The controller I
- We have to find ? in ZEe(k1) (NBe(k) ? ? ) o
R - But from the model we have that ZEe(k1)
(NBe(k) ? PBu(k)) o R - Since ? LE(k) o K PBu(k)
- We have that K must be such that LE(k) o K
PBu(k)
38The controller II
- Thus, the fuzzy controller is the fuzzy relation
K on e ? u which corresponds to the set of rules - If e(k) is NBe then u(k) is PBu
- If e(k) is NSe then u(k) is PSu
- If e(k) is ZEe then u(k) is ZEu
- If e(k) is PSe then u(k) is NSu
- If e(k) is PBe then u(k) is NBu
39Stability of closed-loop systems I
- The closed-loop system
- can be rewritten as
- where
40Stability of closed-loop systems II
- Let LEdes be the desired error
- Theorem the closed-loop system is stable for any
initial state iff for any n ? N
41Idea of the proof
-
- Hence
- Hence
- If and are normal then
and - Therefore
42Takagi-Sugeno fuzzy models
- A single rule Ri Ri if x1 is A1i and and
xn is Ani then x Ai x Bi u where A1i is
the linguistic value of the state variable x1 in
the i-the rule.
43Computing a single rule I
- For a given input (x10, x20, , xn0) and (u10,
u20, , un0) - Step 1 Compute
44Computing a single rule II
- Step 2 Compute
- Step 3 Compute
45Computing a all rules
- For a given input (x10, x20, , xn0) and (u10,
u20, , un0) - Repeat Step 1 - 3 for each Ri
- Step 4 Compute the global output
46The global open-loop system
- The global open-loop system is
- Problem 1 How to build such a model?
- Identification
- fuzzy approximation of existing nonlinear model
- Problem 2 Asymptotically stable?
47Asymptotically stable
- Theorem The global open-loop system is
asymptotically stable in the large if there
exists a common positive definite matrix P such
that
48The fuzzy controller for T-S
- The (local) controller for each rule is uiKix
- Since Ai x Bi u is a linear system, Ki can be
designed via a conventional linear control
technique (e.g., pole placement) - Thus, the controller for each rule is Ri if
x1 is A1i and and xn is Ani then uj Kj x
49The global controller
- The global controller is then given as
- where mj(x) is computed in exactly the same
matter as for the open-loop system - TS-control is a weighted sum of (local affine)
controllers
50The global closed-loop system
(GC-L)
51Stability I
- When is (GC-L) asymptotically stable in the
large? - Let Aij Ai Bi Kj, i 1,2, j1,2,
- Then
(GC-L)
52Stability II
- Theorem (GC-L) is asymptotically stable in the
large iff there exists a common positive definite
P such that
53Controller design
- Find such Kjs (j 1, 2, ) such that there
exists a common definite P such that
54Fuzzy approximation
- Fuzzy approximation of a nonlinear model
- Consider a nonlinear system
- where f is a vector-valued nonlinear function
(1)
55Local linearization
- When (1) is linearized around xd we obtain
- where xd ?f/?x at x xd and x f is an
approximation error.
(2)
56Controller for linearized system
- Since (2) is linear, the controller becomes
- where Kd is a control matrix stabilizing (2)
around xd f (xd) is an estimate of f(xd)
57Closed-loop system
- The closed-loop system is then given as
- where
- Observe here that xd is an equilibrium point when
(3)
58Asymptotically stable
- (3) is asymptotically stable around xd if Ad
Kd is a Hurwitz matrix(all eigenvalues of Ad
Kd have a negative real part, Relilt0). - The original nonlinear system is stable around xd
if the linearized one is.
59Fuzzy approximation
- The fuzzy approximation around xd
- Ri if x1d is A1i and and xnd is Ani then
x fj Aj(x - xd) u - The global open-loop system is
60The fuzzy controller
- RiC if x1d is A1j and and xnd is Anj then
uj Kj (x - xd) - f (xd) - The closed-loop system (Ri, RiC) then is
- D(x, xd ) compensation for errors of Ai and
KiDi f (xd) - f (xd)
61Local stability (around xd)
- Take into account the robustness ofAi and
Kiwith respect to D(x, xd ) and Di.
62Global closed-loop system
- Global closed-loop system (far from xd)
- Ri if x1d is A1i and and xnd is Ani then
x fj Aj(x - xd) u - RiC if x1d is A1j and and xnd is Anj then
uj Kj (x - xd) - f (xd) - The global closed-loop system
63Heuristic fuzzy controllers
x
e
xd
e
De
De
De
De
t
0
64Time map of output x
65The domains of e and De
- How to choose the domains of e and De?
- Changing the domain of e affects the overshoot
and undershoot characteristics of the controller - Changing the domain of De affects rise time and
settling time - Changing the domain of e and De affects the
system trajectory
66Domain of De is too small
Demax
e
emax
emin
Demin
67Domain of e is too small
Demax
e
emax
emin
Demin
68Domain of De and e are OK
Demax
e
emax
emin
Demin
69Membership distribution
u
e
Equally spaced terms
Wide terms around zero
Narrow terms around zero
Little overshoot slow approach
Much overshoot fast approach
70Undershoot overshoot
x
xd
t
0
71Overlap of membership functions
e
50 overlap, Normal width
66 overlap, Double width
No overlap, Half width
72Undershoot overshoot
x
xd
t
0
73Identifying rules
Improve rise time
Improve overshoot
74Sliding mode fuzzy control
- Given a nonlinear system model including
- Model uncertainties
- Parameter fluctuations
- Disturbances
- Find a robust control law that makes the system
asymptotically stable.
75Figure switching line
switching line
De
K
K
e
sgt0
slt0
slt0
s e le
s0
sgt0
76Sliding mode introduction
- Drawback of sliding mode control
- Leads to chattering of the control variables
- High stress of mechanical and electrical elements
- Therefore, introduction of a boundary layer near
the switching line
77De
boundary layer
K
K
sgt0
e
slt0
slt0
s e le
s0
sgt0
78Boundary layer and fuzzy
79Fuzzy sliding mode
- Fuzzy sliding mode control is an extension of
sliding mode with boundary layer - Control law