WEBVTT
00:20.090 --> 00:27.090
Fuzzy Lyapunov controller computing with words,
this is the lecture 4 of this module 4 on
00:31.529 --> 00:38.529
fuzzy control. As I said in the last class
that given the mamdani type of fuzzy logic
00:42.580 --> 00:49.580
controller, the membership functions are optimized
using genetic algorithms.
00:51.010 --> 00:58.010
But the most important aspect of mamdani type
of controller is to generate a proper rule
01:01.559 --> 01:08.559
base. Here, of course you can also generate
rule base using genetic algorithm but today,
01:13.390 --> 01:20.390
we will be learning how to generate a rule
base using the concept of Lyapunov function.
01:23.009 --> 01:30.009
So this is the topic today, fuzzy Lyapunov
controller computing with words.
01:30.350 --> 01:37.350
Topics to be covered today are classical Lyapunov
synthesis; Fuzzy Lyapunov synthesis; rotational
01:40.369 --> 01:47.369
proof mass actuator system, this is the physical
system on which you will be testing our algorithm;
01:50.060 --> 01:57.060
construction of rule base for RTAC, the short
form is RTAC here, RTAC using fuzzy Lyapunov
01:57.069 --> 02:03.530
synthesis: regulation problem; controller
design for regulation; construction of rule
02:03.530 --> 02:10.530
base for RTAC using fuzzy Lyapunov synthesis:
tracking problem; controller design for tracking;
02:11.420 --> 02:13.140
and finally, simulation results.
02:13.140 --> 02:18.510
Fuzzy Lyapunov synthesis: an introduction-
the classical Lyapunov synthesis method is
02:18.510 --> 02:25.510
extended to the domain of computing with words.
This new approach is used to design fuzzy
02:27.520 --> 02:32.290
controller. Assuming minimal knowledge about
the plant be controlled, the proposed method
02:32.290 --> 02:38.730
enables us to systematically derive the fuzzy
rules that constitute the rule base of the
02:38.730 --> 02:45.730
controller. The objective is in this method,
how do we obtain fuzzy rule base given the
02:51.189 --> 02:58.189
system, some prior in knowledge of the system
or approximate model of the system, how do
03:00.510 --> 03:05.260
we generate a rule base?
This approach is demonstrated by designing
03:05.260 --> 03:12.060
Mamdani-type and Takagi-Sugeno-type fuzzy
controllers for nonlinear plants.
03:12.060 --> 03:15.689
The most difficult aspect in the design of
fuzzy controllers is the construction of the
03:15.689 --> 03:21.730
rule base. Fuzzy Lyapunov synthesis is based
on extending the classical Lyapunov synthesis
03:21.730 --> 03:27.819
method to design of fuzzy controllers. It
enables to systematically derive the fuzzy
03:27.819 --> 03:34.739
rule base. Based on classical Lyapunov synthesis
method, we construct a Lyapunov function candidate
03:34.739 --> 03:41.739
V and then determine the conditions required
to make it a Lyapunov function of the closed
03:41.870 --> 03:46.780
loop system. Since we assume fuzzy knowledge
about the plant to be controlled, the derived
03:46.780 --> 03:50.829
conditions can be stated as fuzzy if then
rules.
03:50.829 --> 03:56.489
So now let us go to the system description.
Consider the following single-input, single-output
03:56.489 --> 04:03.489
system. x dot equal to f x, u, y is h x, u
where f and h are nonlinear functions. This
04:08.370 --> 04:15.370
is n dimensional state space, so f is a n
dimensional vector; and u and y they are the
04:17.459 --> 04:24.459
input and outputs of the system respectively;
x n dimensional system x1, this is x1 x2 until
04:27.770 --> 04:33.730
xn, Rn is the state vector of the system.
The control objective is to stabilize the
04:33.730 --> 04:39.310
system around some operating point x0. Without
loss of generality we may assume x0 equal
04:39.310 --> 04:40.389
to 0.
04:40.389 --> 04:46.840
So Lyapunov stability theory which we have
been talking again and again, I am just revisiting
04:46.840 --> 04:52.270
that, the system x dot equal to f x, u is
Lyapunov stable around the operating point
04:52.270 --> 04:57.860
x equal to 0. If there exists a continuously
differentiable function V x which is known
04:57.860 --> 05:04.440
as Lyapunov function such that the following
requirements are met. V x is positive definite
05:04.440 --> 05:11.180
in the neighborhood of 0 and v dot x is negative
definite in the neighborhood of 0. If we can
05:11.180 --> 05:14.759
ensure that then the system is Lyapunov stable.
05:14.759 --> 05:20.110
So fuzzy Lyapunov synthesis- assume that the
exact system model is unknown but we do have
05:20.110 --> 05:26.419
some partial fuzzy knowledge about the system.
As in classical case we consider a Lyapunov
05:26.419 --> 05:32.180
function candidate V, derive an expression
for its derivative and then obtain the fuzzy
05:32.180 --> 05:39.150
rule base for the control input u, so that
v dot is negative definite. Based on the rule
05:39.150 --> 05:45.669
base, a fuzzy controller u is obtained using
general inference mechanism and defuzzification
05:45.669 --> 05:47.620
method.
05:47.620 --> 05:54.620
What is the objective here is that we prescribe
a Lyapunov function for the system and then
05:56.759 --> 06:03.759
we construct, find the right derivative of
the Lyapunov function, substitute the dynamics
06:05.699 --> 06:12.699
of the system in that and now we create a
rule base in such a way this Lyapunov function
06:15.849 --> 06:22.849
is qualitatively negative definite, not quantitatively.
So what is fuzzy Lyapunov synthesis is we
06:24.690 --> 06:31.690
are using
a qualitative negative definite of v dot.
This is the difference qualitative negative
06:51.050 --> 06:55.180
definiteness of v dot, instead of a quantitative
negative.
06:55.180 --> 07:02.129
The actual Lyapunov function approach to test
the stability of the system is to find quantitavely
07:02.129 --> 07:09.129
v dot is negative definite. But now we are
talking about a concept qualitatively, if
07:10.789 --> 07:15.569
we can make v dot to be negative definite.
07:15.569 --> 07:22.569
FLC structures of the rule base, so normal
we have two kinds of we can formulate any
07:23.150 --> 07:28.879
fuzzy logic controller of mamdani type. We
can have two categories of fuzzy rule base.
07:28.879 --> 07:35.879
The representation 1 is if x1 is A1 and or
x2 is A2 and or xn is An then u is B where
07:40.009 --> 07:47.009
Ai’s and B are linguistic variables large
or small. So x1 x2 and xn they are either
07:48.539 --> 07:53.060
state variables or error in state variables.
07:53.060 --> 08:00.060
Representation 2 is if x1 is A1 and or x2
is A2 and so on or xn is An then u is a definite
08:03.490 --> 08:10.490
function here the B, u is B are the fuzzy
linguistic variable where in the second representation
08:11.389 --> 08:18.389
u is an exact function. u is f(x1 x2 … xn)
where f is a linear function; this can be
08:22.330 --> 08:27.770
also nonlinear function, f can be also linear
function here, normally is a linear function.
08:27.770 --> 08:33.229
So fuzzy Lyapunov synthesis: motivation- what
is the motivation here? In a general fuzzy
08:33.229 --> 08:39.320
logic controller, the control problem is to
design a fuzzy controller using information
08:39.320 --> 08:44.620
based on some physical intuition even if the
exact system dynamics is not known.
08:44.620 --> 08:49.330
But the main problem is constructing the rule
base for the controller. Rule base is obtained
08:49.330 --> 08:56.330
using the notion of classical PD or PID controller
in general for mamdani type of fuzzy logic
08:57.790 --> 09:03.700
controller. But in a fuzzy Lyapunov synthesis
a rule base is obtained using the notion of
09:03.700 --> 09:10.700
Lyapunov stability. So this is the prime motivation.
I can tell you how normally we do a fuzzy
09:11.900 --> 09:18.900
rule base, if this is my general characteristic
of a second order system. So what I would
09:21.860 --> 09:28.860
like, when I describe this response, this
is my t, this is my y, my output. So you see
09:30.450 --> 09:37.200
that if I am here at this zone, so at this
zone I can say error, error at this zone is
09:37.200 --> 09:39.080
very large.
09:39.080 --> 09:45.070
I would like when I am here I should come
very fast to this line, which is my desired
09:45.070 --> 09:52.070
command signal 1.0. What I will say, when
my error is small and the derivative of error,
09:54.840 --> 10:01.840
the rate of change in error is either small
or large whatever it is, when it is small
10:01.950 --> 10:08.950
I would like it to come fast. My controller
must be very large. I can write for this kind
10:11.000 --> 10:18.000
of PD or PID type of controller the rule base
is if e is small in this zone and e dot is
10:26.580 --> 10:33.580
small or large then u is large. By simple
commonsense I can write.
10:36.700 --> 10:43.700
Similarly, if I say e is small here and if
e is small in this zone and e dot is also
10:50.220 --> 10:57.220
small then u is small because I have already
reached almost I am reaching the set point.
11:06.560 --> 11:13.560
But if e is small and e dot is large, so obviously
I must reduce the control action, so that
11:16.410 --> 11:23.410
is, in that case I have to say u is negative
small, instead of positive small. Like that
11:24.810 --> 11:31.640
the normal rule base is done in case of PD
or PID type of controller.
11:31.640 --> 11:38.250
But today we will see a very systematic method
of generating rule base. Actually this entire
11:38.250 --> 11:45.250
class today is to let you know or we will
learn how to generate this rule base systematically
11:46.640 --> 11:53.640
using Lyapunov stability theory. Before that,
I will just explain to you one physical system
11:54.440 --> 12:00.130
on which will be applying this thing, this
is called rotational translational proof mass
12:00.130 --> 12:01.190
actuator.
12:01.190 --> 12:08.190
You can actually see this is my rigid surface
to which a cart is bound using a spring. Inside
12:12.000 --> 12:19.000
the cart there is the pendulum which rotates
by the action of the torque and the pendulum
12:20.410 --> 12:27.410
link length is l and there is an external
disturbance f that is applied on the cart.
12:29.660 --> 12:34.920
See the objective is to control this pendulum
the way we like.
12:34.920 --> 12:41.560
I may like to keep this pendulum at an angle
theta or vertically downward vertically upward,
12:41.560 --> 12:47.120
whatever is the desired thing or it has to
follow certain trajectory, so whatever may
12:47.120 --> 12:54.120
be the requirement this is a typical control
system because it is nonlinear and also it
12:55.860 --> 12:57.770
a bench mark problem.
12:57.770 --> 13:04.040
The RTAC system, consider the following example
rotation translational proof mass actuator
13:04.040 --> 13:11.040
RTAC. The RTAC system combines a translational
oscillator with a rotational proof mass actuator.
13:14.260 --> 13:21.260
This particular portion now oscillates by
the action of the spring. So this called combines
13:21.560 --> 13:27.440
a transitional oscillator. This oscillates
in the x direction with a rotational proof
13:27.440 --> 13:34.440
mass actuator. This is rotation. The oscillator
consists of a cart connected to fixed wall
13:34.620 --> 13:40.190
by a linear spring. The cart is constrained
to move in the x-direction only. The proof
13:40.190 --> 13:46.440
mass actuator is attached to the cart and
is controlled by an applied torque N. F is
13:46.440 --> 13:53.440
disturbance force that perturbs the cart.
F is a disturbance force that gives such a
13:54.600 --> 13:58.940
disturbance input.
13:58.940 --> 14:05.940
The cart position and actual angle is xc and
theta respectively, that is the cart which
14:05.980 --> 14:12.980
you saw here this is xc and this theta already
which have already shown. Mass of the cart
14:15.060 --> 14:22.060
is given 1.36 Kg; proof mass is 0.096 that
is the mass of this cart is M and proof mass
14:26.140 --> 14:33.140
is small m. So small m is 0.096 Kg; distance
of the link length of the pendulum is 0.059
14:38.030 --> 14:45.030
meter; Moment of inertia of the proof mass
is I is 0.00022 Kg meter square; Spring constant
14:46.040 --> 14:50.510
k is given 186.3 Newton per meter.
14:50.510 --> 14:57.510
Now we define some normalized variables which
is zeta is xc root over M plus m upon I plus
15:01.200 --> 15:08.200
mL square; tau is t k upon M plus m; and u
is this is my actual input and M plus m upon
15:14.250 --> 15:21.250
k into 1 minus mL square; K is the spring
constant; and omega is 1 upon k M plus m by
15:24.640 --> 15:29.560
I plus mL square F.
15:29.560 --> 15:36.560
Given that, you see that we can write, we
can derive the dynamics of the RTAC system,
15:38.560 --> 15:45.560
you can easily see that it has four states.
x1 is zeta is actually represented xc normalized;
15:47.990 --> 15:54.990
this is xc dot; the velocity of the cart normalized
which is x2; and theta is the pendulum angle
15:57.860 --> 16:04.860
x3; theta dot is the angular velocity of the
pendulum which is x4; and control variable
16:05.950 --> 16:12.950
is u which is also normalized; n the torque;
and disturbance is w, so this one w is the
16:18.080 --> 16:19.170
disturbance.
16:19.170 --> 16:26.170
If we look at x dot this is the fourth order
system and the expressions are x dot equal
16:28.530 --> 16:35.080
to x2, the advantage is that we have not kept
any parameters associated, this is simplified
16:35.080 --> 16:42.080
x2, you can see x dot is in this, this I can
say, this is simply a function of x, this
16:44.960 --> 16:51.960
is another function of x may be g x, and this
is d x.
16:55.500 --> 17:02.500
You can say this is a function vector with
four dimensions, with function vector with
17:03.130 --> 17:10.130
another four dimensions and another function
vector with four dimensions. You can see that
17:10.679 --> 17:17.559
system is highly nonlinear if silent is defined
as mL upon root over I plus mL square into
17:17.559 --> 17:24.559
M plus m, you can easily derive this equation,
I will not discuss further on this. All that
17:25.039 --> 17:30.279
I am trying to tell you is that RTAC system
has a nonlinear dynamics which has type x
17:30.279 --> 17:37.279
dot is f x plus g x plus g x into u plus d
x into w, where w is the external disturbance;
17:39.179 --> 17:44.009
u is actual control input.
17:44.009 --> 17:48.960
The fuzzy Lyapunov synthesis of RTAC- the
system dynamics now can be written as, as
17:48.960 --> 17:55.960
we said x dot is f x plus g x u plus d x w.
Without knowing f x, g x and d x following
17:56.269 --> 18:01.750
linguistic statements can be formulated. Even
if I do not know what is f x g x d x exactly,
18:01.750 --> 18:07.629
I can still write the state of the system
is described by x1 the cart’s position;
18:07.629 --> 18:14.629
x2 equal to x1 dot; and x3 is actuator’s
angle; and of course x4 is x3 dot. That is
18:15.590 --> 18:22.590
x3 is theta, x4 is theta dot, x1 is xc normalized,
x1 is xc normalized and x2 is x1 dot. This
18:37.450 --> 18:42.610
is another important thing that I can easily
tell you, x4 dot is proportional to the control
18:42.610 --> 18:48.610
input u that you can easily see here.
18:48.610 --> 18:53.980
Because you see that this is the my pendulum
and if I assume that there is no friction
18:53.980 --> 18:59.230
and other things here, then my pendulum, the
acceleration of this pendulum, angular acceleration
18:59.230 --> 19:06.230
obviously is directly proportional to the
torque applied N and since my input u is normalized
19:07.080 --> 19:13.600
value of N and hence I can always say that
x4 dot, the acceleration of the pendulum is
19:13.600 --> 19:20.600
proportional to the control input u.
Similarly, x2 dot the velocity of the cart
19:22.120 --> 19:27.769
is proportional to the negative of x1, you
can easily see that because the spring is
19:27.769 --> 19:34.769
connected so it is like this, spring and this
is the block mass. You can see that x2 dot
19:36.559 --> 19:43.389
the velocity is always, because of spring
action, it will be always in this direction
19:43.389 --> 19:50.389
the velocity. If I move x in this direction,
x2 the position in this direction, the velocity
19:54.179 --> 19:58.639
is in the negative direction. So x2 dot in
this is proportional to minus x1.
19:58.639 --> 20:04.440
The control objective is to find u such that
the system is stable around x equal to 0.
20:04.440 --> 20:10.789
This is the regulation problem. Let V is half
x1 square plus x2 square plus x3 square plus
20:10.789 --> 20:17.789
x4 square be the Lyapunov function candidate.
Then using S-1, the assumption that we have
20:19.330 --> 20:26.330
four states V dot is x1, x1 dot and x1 dot
is x2. Similarly, this is 2x2 x2 dot, so x2
20:30.860 --> 20:37.860
x2 dot plus x3 x3 dot and x3 dot is x4 and
similarly, this is x4 into x4 dot. Before
20:42.470 --> 20:49.470
this is the second step, the first step V
dot if you look at here is x1 x1 dot plus
20:49.929 --> 20:56.929
x2 x2 dot plus x3 x3 dot plus x4 x4 dot, because
we know already that x2 is x1 dot and x4 is
21:03.399 --> 21:06.399
x3 dot, so this second step comes.
21:06.399 --> 21:13.399
Now you see that, we have already said x2
dot is proportional to minus x1. Obviously,
21:21.110 --> 21:26.940
qualitatively if I put x2 dot is minus x1,
these two terms qualitatively cancels off,
21:26.940 --> 21:33.940
where as only these two terms remain, x3 x4
is remained and I know already that x4 dot
21:37.330 --> 21:44.330
is proportional to u, so instead of x4 dot
I put u.
21:44.899 --> 21:50.379
You see that, what is the advantage here is
that I am designing a rule base but while
21:50.379 --> 21:57.379
designing rule base I am not utilizing the
system dynamics. I am finding how to what
21:58.840 --> 22:05.840
V dot is equal to x3 x4 plus x4u. While finding
this equation, I am not using the system dynamics.
22:10.509 --> 22:17.509
This is very important, system dynamics is
not used.
22:21.730 --> 22:28.730
What is used is the simple physics of the
system is that, here we use x2 equal to x1
22:31.269 --> 22:38.269
dot obviously the velocity x2 and x1 is positioned
and similarly, here we use the notion that
22:38.700 --> 22:45.700
the x4 is x3 dot, so x4 is theta dot and x3
is theta, which is very simple and also we
22:47.679 --> 22:51.820
used other rule from the systemic connections.
22:51.820 --> 22:56.740
We know already that the acceleration of the
pendulum is proportional to the input and
22:56.740 --> 23:03.740
x2 dot is proportional to minus x1, just by
constructional feature. Using these two rules,
23:05.690 --> 23:12.690
we found V dot to be qualitatively x3 x4 plus
x4 into u. Now, even if you do not know the
23:16.289 --> 23:23.289
system dynamics, looking at this figure we
can create a rule base for which this V dot
23:24.200 --> 23:28.179
can be qualitatively negative definite.
23:28.179 --> 23:33.690
So classical Lyapunov synthesis have design
of view that will guarantee V dot is negative
23:33.690 --> 23:38.879
definite. Same idea is applicable here but
with the domain of computing with words means,
23:38.879 --> 23:45.879
this is qualitatively not quantitative. What
we are trying to do is we are applying Lyapunov
23:46.610 --> 23:52.809
synthesis to the system dynamics partially
known system dynamics for generation of rule
23:52.809 --> 23:54.620
base.
23:54.620 --> 24:01.289
Now we take the example, when I say so V derived
V dot equal to approximately qualititatively
24:01.289 --> 24:08.289
x3 x4 plus x4 into u. This can be made negative
definite if the rule base is formed as follows.
24:09.679 --> 24:16.679
You see that I will take care that you understand
is because this is what you should learn how
24:17.600 --> 24:24.600
do generate a rule base, you see x3 is negative.
If x3 is negative and x4 is also negative,
24:28.909 --> 24:35.909
that means this quantity is positive. Now
x4 is negative and if u would be come negative
24:37.090 --> 24:43.129
then this whole thing is positive, so no way
you can make the system is stable. Obviously,
24:43.129 --> 24:49.570
the rule base should be u to be positive,
that is the rule.
24:49.570 --> 24:56.570
I repeat if x3 is negative and x4 is negative,
in that case x3 x4 is positive, this implies
25:04.940 --> 25:11.940
x4 into u should be negative to make these
two quantities to be qualitatively negative.
25:22.820 --> 25:29.249
So x4 u should be negative, x4 is already
known as negative, so u has to be positive.
25:29.249 --> 25:36.249
This is first rule. If x3 is negative and
x4 is negative then u is positive. Similarly,
25:36.419 --> 25:43.419
if x3 is positive and x4 is positive. x3 is
positive and x4 is positive means again x3
25:44.409 --> 25:51.409
and x4 is positive in this case. And this
implies again x4 and u should be negative
25:58.970 --> 26:05.970
and since x4 is positive so u has to be negative
which is negative. The second rule is if x3
26:06.279 --> 26:13.279
is positive and x4 is positive then u is negative.
I hope you are able to follow what I am presenting
26:14.179 --> 26:15.590
you.
26:15.590 --> 26:21.889
Now let us see the other possible combination.
If x3 is negative and x4 is positive, in this
26:21.889 --> 26:28.889
case x3 x4 is negative. If x3 x4 is negative
I must ensure that x4 u, since it already
26:42.019 --> 26:49.019
negative this should be 0 is sufficient, if
I make x4 is 0 because x3 x4 is negative is
26:52.490 --> 26:59.070
very good. This is simple because there are
other ways also is x3 x4 is negative I can
26:59.070 --> 27:06.070
say x4 u is also negative much better. But
this is simplest one x4.
27:06.240 --> 27:13.240
x3 is negative and x4 is positive then u is
0, you can also think another possibility,
27:15.090 --> 27:22.090
because x4 is positive u is negative, this
is also possible. Similarly if x3 is positive
27:24.019 --> 27:31.019
and x4 is negative then again x3 x4 in this
case x3 and x4 sorry x3 negative, x3 is positive
27:47.039 --> 27:54.039
and x4 is negative, x3 x4 is negative. So
this implies you can make x4 u is 0 or x4
27:58.899 --> 28:05.899
u again negative. Since x4 is negative so
u is 0 or u is positive, but in this case
28:15.110 --> 28:17.789
we have only considered this 0.
28:17.789 --> 28:24.789
I wish this is the most important part of
this lecture, first of all using partial knowledge
28:26.590 --> 28:33.590
of the system and without taking the help
of system dynamics we first of all found out
28:34.619 --> 28:40.440
the rate derivative of the Lyapunov function
is approximately qualitatively equal to x3
28:40.440 --> 28:47.440
x4 plus x4 u and using this expression we
computed set of rule base such that V dot
28:48.730 --> 28:51.519
can be negative definite.
28:51.519 --> 28:58.519
What we have not until now found out in this
is the parameters negative, what are the parameter
28:59.360 --> 29:06.360
associated with negative. I am assuming this
fuzzy linguistic variable to be Gaussian functions,
29:08.840 --> 29:15.840
which we have taken in this case. Gaussian
function is normally represented by two parameters-
29:16.149 --> 29:23.149
one is mean and another is sigma. If I say
sigma is 1 then these linguistic variables
29:23.369 --> 29:29.929
they are all represented by one parameter
that is the mean and the u is positive or
29:29.929 --> 29:36.779
negative that we have defined here, we have
taken them to be single term.
29:36.779 --> 29:43.779
Standard Gaussian membership functions are
used to defined the linguistic terms in the
29:44.759 --> 29:51.759
rule base as mu positive of x is e to the
power minus x minus x whole square, this is
29:52.950 --> 29:58.929
the parameter that we have to identify. Similarly,
mu negative membership function of negative
29:58.929 --> 30:05.929
of the variable x is e to the power minus
x plus x whole squared. And mu z x is 0 e
30:11.830 --> 30:14.220
to the power minus x square.
30:14.220 --> 30:21.220
So x represents mean, x stands for state variable,
p, n, z denotes positive, negative and zero
30:21.659 --> 30:28.659
respectively. Using the product for AND inference
and center of gravity method for defuzzification
30:29.269 --> 30:35.600
the fuzzy controller is given as we have four
rules. So for four rules the u if you look
30:35.600 --> 30:42.129
at here what I will do is that in this I find
out the membership function of this, the membership
30:42.129 --> 30:49.129
function of this. So this is mu x3 into mu
x4 so that is the membership function for
30:53.669 --> 31:00.669
my control action and this is the fuzzy singleton
which I define
as au, the fuzzy singleton, therefore my control
31:08.619 --> 31:11.149
action is au.
31:11.149 --> 31:18.149
mu negative x3, mu negative x4 into au is
the output of the first rule. Here, again
31:23.619 --> 31:30.619
to let to know I will again explain, here
how we are actually doing this I do not have
31:34.259 --> 31:41.259
to do every thing again you can easily understand,
what is control action from this rule base?
31:41.779 --> 31:48.779
Obviously, I find out what is mu and x3, and
mu and x4 the membership function of this
31:54.399 --> 32:01.399
into u is positive and this is a singleton
and that is why this is au.
32:03.679 --> 32:10.029
au is the singleton value associated with
this control action au, simply multiplied.
32:10.029 --> 32:17.029
This is the output of this controller, similarly
you can easily see this is output of the rule
32:17.399 --> 32:24.399
base, this rule and the second rule output
will be mup x3 into mup x4 into this is negative,
32:33.149 --> 32:39.340
so minus au. That is what we doing here.
32:39.340 --> 32:46.220
So mu and x3, mu and x4 au, mup x3, mup x4
minus au I will not have been considered this
32:46.220 --> 32:51.889
because we are assuming. Thus you see that
this is 0 if I simply say the control action
32:51.889 --> 32:58.889
is 0, because control action is 0 this is
sufficient for me to make this rate derivative
32:59.369 --> 33:06.369
to be negative definite. Simply making that
what advantages I am gaining is that, I am
33:06.419 --> 33:13.419
not reducing the parameters that has to be
optimized or heuristically that has to be
33:13.519 --> 33:20.519
tuned. This is my control action, by using
center of gravity method you just add all
33:20.989 --> 33:25.340
these individual membership functions associated
with control action.
33:25.340 --> 33:32.340
So there are 4 and finally, you get the value
by taking mup x is e to the power minus x
33:35.039 --> 33:39.929
minus x whole square in mu and x is e to the
power minus x plus x whole square, you can
33:39.929 --> 33:46.929
write u to this function. This is your control
law. This is nothing to do because we have
33:49.350 --> 33:56.350
taken Gaussian function. Finally you can simplify
this u, but you also can take any other function
33:56.409 --> 34:01.090
triangular function or whatever function you
want to like, but if you look at this control
34:01.090 --> 34:08.090
action what are the parameters that you do
not know, this one is au, another is ax3,
34:12.500 --> 34:19.500
another is ax4, all other things x3 x4, these
quantities that you are getting feedback from
34:21.310 --> 34:28.310
the system. So these three parameters they
have to be found and we can do any kind of
34:28.490 --> 34:30.919
optimization algorithm.
34:30.919 --> 34:36.640
And particularly we have used genetic algorithm,
particularly univarite marginal distribution
34:36.640 --> 34:43.640
algorithm. We have already described in the
previous classes what univarite marginal distribution
34:47.800 --> 34:54.800
algorithm is.
This has been used to minimize this cost function
34:54.830 --> 35:01.770
and by minimizing that, the optimal parameters
are found to be the mean of the linguistic
35:01.770 --> 35:08.770
variable for x3 is 0.73 and for x4 is 0.25,
this either positive or negative. So this
35:11.580 --> 35:18.580
is the mean and au is control action singleton
is 1.4. This was done, so this is design is
35:21.070 --> 35:27.730
over, now we can simulate the system which
will show the results at the end of the section.
35:27.730 --> 35:34.730
But here, before that I will derive again
another kind of rule base for the same system.
35:38.600 --> 35:45.510
The u instead of earlier case u was simply
a linguistic variable, but now I am assuming
35:45.510 --> 35:52.510
this is a state variable technique, where
u is minus k1x3 minus k2x4. Of course this
35:55.950 --> 36:02.050
is just to simplify but actually I should
have taken all the x1x2 I am not taking, just
36:02.050 --> 36:06.980
to simplify because if I am able to control
using only two variables, I can only expect
36:06.980 --> 36:13.980
that using x1 and x2 I can improve the performance.
So putting expression of u in V dot is already
36:15.310 --> 36:20.180
we have found out this earlier because we
considering same RTAC system.
36:20.180 --> 36:27.180
So for RTAC system giving the physical principles
V dot qualitatively comes out to be x3x4 plus
36:28.220 --> 36:35.220
x4u. Now this V dot can be written as x3x4
and then x4u is this quantity which is minus
36:37.650 --> 36:44.650
k1x3 minus k2x4, and this can be again simplified,
this is 1 minus k1 into x3x4 minus k2x4 whole
36:46.470 --> 36:53.470
square. So how do I now derive the rule base
for this kind of structure?
36:54.290 --> 36:59.660
I just have to make sure that I have to select
k1 and k2 in such a way that this quantity
36:59.660 --> 37:06.660
is negative definite. This is what, if x3
is negative and x4 is negative then u is,
37:08.390 --> 37:15.390
you see that x3 is negative and x4 is negative,
so this quantity is positive. Since x4 is
37:20.000 --> 37:27.000
negative, the x4 square is positive. All that
I have to make sure that 1 minus k has to
37:29.790 --> 37:36.790
be negative as well as k2 is also a positive.
So k2 is positive and 1 minus k1, because
37:39.390 --> 37:46.390
this is positive, this has to be negative,
1 minus k1 is negative means k1 is greater
37:49.020 --> 37:53.680
than 1. This is my first rule.
37:53.680 --> 38:00.680
The second rule is if x3 is positive and x4
is positive, this quantity is positive, this
38:00.960 --> 38:07.960
quantity is positive, to make it again negative
definite, again I will have the same principle
38:08.810 --> 38:15.810
whatever I got here I must be that, k2pp greater
than 0, k1pp is greater than equal to 1. Same
38:17.160 --> 38:23.560
condition, only this nn stands for the rule
base when x3 is negative and x4 is negative
38:23.560 --> 38:27.770
and here pp stands for x3 is positive and
x4 is positive.
38:27.770 --> 38:34.770
In the second rule you saw that, the same
condition came but these are different parameters
38:36.650 --> 38:43.650
you have to remember k1pp. If x3 is positive
and x4 is positive then u is equal to minus
38:45.440 --> 38:52.440
k1pp x3 minus k2pp x4 where I showed you that
this has to be positive and k2 has to be positive.
38:56.410 --> 39:03.410
Now let us go to the third one, x3 is negative
AND x4 is positive THEN u is minus k1np x3
39:05.600 --> 39:12.600
minus k2np x4. How do I find out what is k1
and k2? It is simple; k1np you see that, x3
39:19.970 --> 39:26.810
is negative and x4 is positive here, that
makes this is negative. This is negative means
39:26.810 --> 39:33.810
this has to be positive, 1 minus k1 has to
be positive, so k1 should be less than 1.
39:42.800 --> 39:49.800
That is k1np is less than 1 and here this
has to be again positive quantity k2x4 because
39:53.610 --> 39:58.440
this is negative is already there, this x4
is positive so this is always positive whether
39:58.440 --> 40:05.440
x4 is negative or positive. To make it positive
k2 also has to positive, so this is what k2np
40:06.600 --> 40:09.930
this has to be positive.
40:09.930 --> 40:16.930
Similarly, if x3 is positive and x4 is negative,
again this is negative, this has to be again
40:19.440 --> 40:26.440
positive, and again k1 should be less than
1. So k1pn is less than 1 and k2pn has to
40:35.280 --> 40:41.660
be again here this is positive, so k2 has
to be always positive. You can easily see
40:41.660 --> 40:48.660
that this k2 always in every case is positive,
only in this case, the first one it is positive
40:50.180 --> 40:55.890
and the second that is negative. What you
got an idea that, what should be this value
40:55.890 --> 40:58.550
k1 and k2, at least the magnitude?
40:58.550 --> 41:05.550
Now heuristically you have to tune these values
what should be k1nn k2nn k1pp k2pp k1np k2np
41:10.220 --> 41:16.550
and k1pn and k2pn heuristically, or I can
use the genetic algorithm or we have done
41:16.550 --> 41:20.630
that univarite marginal distribution algorithm
to optimize this parameter.
41:20.630 --> 41:24.570
You see that considering the same membership
function and using product for AND inference
41:24.570 --> 41:31.570
and center of gravity method for defuzzification,
the fuzzy controller is given is like this.
41:33.930 --> 41:40.930
Since mup is this and mun is this, which we
have already done in the previous case, we
41:41.620 --> 41:48.620
can write u as like this, we have a controller
and by simplifying that we have actually ten
41:50.220 --> 41:55.050
parameters to identify.
41:55.050 --> 42:02.050
Two parameters x3x4, the mean for linguistic
variable x3 positive, for x3 positive and
42:08.050 --> 42:15.050
x3 negative the mean is x3 and actually in
case of one case mean is positive and in one
42:20.290 --> 42:26.250
case mean is negative. That is what we are
doing that when it is negative, mean is negative,
42:26.250 --> 42:31.320
so the sign changes that is why you saw that
here.
42:31.320 --> 42:38.320
In this case this is positive x when it is
negative mean is negative, so it is positive
42:39.210 --> 42:46.210
quantity and mean is positive here in case
of positive, so it is negative here. So ax3
42:47.590 --> 42:54.590
is 0.25 here, doing optimization using univarite
marginal distribution ax3 is 0.25 and ax4
42:55.980 --> 43:02.980
is 0.12 and the parameters, the controller
parameters that is k1 and k2 for all the different
43:05.020 --> 43:11.490
fuzzy rules, four rules are there and for
each rule we have two parameters k1 and k2
43:11.490 --> 43:18.490
and we have got these values 1.1, 1.4, 0.6,
0.8, 0.35, 0.2, 0.4, 0.25. These parameters
43:22.370 --> 43:27.720
we derived using univarite marginal distribution
algorithm.
43:27.720 --> 43:34.720
You see that simulation results x1 converges
to 0 with time, what we started with we gave
43:36.170 --> 43:43.170
some initial disturbance and using the initial
disturbance we are showing now, here x1, x1
43:46.670 --> 43:53.670
is the position of
that cart, you give some little disturbance
to the cart finally it should come to the
43:58.540 --> 44:00.960
rest position.
44:00.960 --> 44:07.790
What is the meaning of PD? This is the FLC
controller where we have used the PD type
44:07.790 --> 44:14.790
of rule base that is if x3 is positive and
x4 is positive then u is negative, in that
44:18.040 --> 44:25.040
kind of rule base. This is PD; it is actually
the rule base that we formulated. That is,
44:28.080 --> 44:35.080
we are denoting we are saying this is PD and
this we are saying state feedback because
44:37.240 --> 44:44.240
you see that u is a function of states. By
doing that you see that, we have got the response
44:48.170 --> 44:55.170
that, this is in second unit, after 40 seconds
almost the oscillation comes to an end.
44:59.910 --> 45:06.910
And here x3 is plotted which is the angular
position, that also should come to, because
45:11.780 --> 45:18.780
the cart was disturbed, although the pendulum
was in the beginning initial position, but
45:18.780 --> 45:25.780
it will start oscillating and that oscillation
will gradually slow down and it equals in
45:26.470 --> 45:33.470
same amount of time this is reduced to 0,
both the PD type of rule base and state feedback
45:34.780 --> 45:41.380
type of rule base and this is the control
action and this is control action you see
45:41.380 --> 45:48.380
that the control action is also fairly smooth
both for PD and as well as state feedback.
45:49.830 --> 45:56.830
Saying that what we did is the regulation
that is given the RTAC system we gave some
45:57.210 --> 46:04.210
disturbance and we showed that this controller
is able to stabilize the system. Now the tracking
46:05.600 --> 46:12.600
controller that we would like that our pendulum
should track it as a trajectory. For tracking
46:15.500 --> 46:21.160
a desired trajectory, what we would like to
have is that instead of the Lyapunov function
46:21.160 --> 46:26.810
which we had half x1 square plus x2 square
plus x3 square plus x4 square for regulation
46:26.810 --> 46:33.810
problem, now we will consider e1 square plus
e2 square plus e3 square plus e4 square be
46:34.760 --> 46:41.760
the Lyapunov function where er is desired
state trajectory minus the actual state trajectory.
46:44.040 --> 46:51.040
So xi is the higher state and xid is the corresponding
desired state trajectory.
46:51.930 --> 46:57.160
The control objective is to find a control
action such that the actuator angle will follow
46:57.160 --> 47:04.050
any given desired trajectory. Hence the Lyapunov
function has been changed from x1 square plus
47:04.050 --> 47:10.970
x2 square plus x3 square plus x4 square to
in this case e1 square plus e2 square plus
47:10.970 --> 47:14.800
e3 square plus e4 square. I hope this is clear
to you.
47:14.800 --> 47:21.800
Now in the same manner we can also show ei
dot is xi dot d minus xi dot is same as xi
47:28.480 --> 47:35.480
plus 1 d minus xi plus 1 which is ei plus
1. What is xi plus 1? Because we have the
47:40.450 --> 47:47.450
parameters x1 x2 x3 x4, so when I say xi 1
plus d, when I say xi is this is x1, x1 dot
47:58.370 --> 48:05.370
d is same as x2d. Obviously, because x2 and
x1 the relation is x2 is x1 dot. By that principle
48:12.580 --> 48:19.150
you are able to see that xi dot d is xi plus
1 d which I am writing here and similarly
48:19.150 --> 48:26.150
also I can write x3 dot d is x4 d, x3 because
x3 dot is x4. So obviously x3 dot d is desired
48:38.110 --> 48:42.600
is x4 desired.
48:42.600 --> 48:49.600
For i equal to 1 and 3, that is what I have
done, i equal to 1 and 3 and differentiating
48:50.000 --> 48:57.000
V we had V dot is e1 e2 plus actually this
is e1 e1 dot e2 e2 dot e3 e3 dot e4 e4 dot.
49:09.830 --> 49:16.830
We already know what is e2 is e1 dot and this
is retained and e4 is e3 dot. This is our
49:19.730 --> 49:25.550
actual expression of e1 dot.
49:25.550 --> 49:31.720
Just like this again x2 dot is approximately
minus x1 and x4 dot is approximately u, thus
49:31.720 --> 49:38.720
in the same similar logic we can simplify
this V dot to be qualitatively e3e4 plus because
49:43.940 --> 49:50.940
qualitatively this will cancel out this because
e2 dot would be minus of e1. This will be
49:57.340 --> 50:04.340
cancelling out qualitatively, what is remained
is e3e4 plus e4 and e4 dot we see that x4
50:08.650 --> 50:15.650
dot is directly proportional to u. We can
write that this is e4 and e4 dot is V where
50:23.030 --> 50:30.030
V is x4 dot d minus u.
50:32.290 --> 50:39.290
This is very simple because e4 dot is x4 dot
desired minus x4 dot and since this is x4
50:49.220 --> 50:56.220
dot I put this x4 dot to be u, I can replace
that by u and x4 d minus u I can write V and
51:03.910 --> 51:10.910
that V is x4 dot d minus u.
What we have to do? I can create a rule base
51:12.650 --> 51:19.650
from this Lyapunov function assuming V to
be my control input and from V if I know V
51:22.810 --> 51:28.520
then I know u, actual control action, this
is pseudo control action, my actual control
51:28.520 --> 51:32.780
action would be x4 d minus u.
51:32.780 --> 51:39.780
In general what we learnt is that for regulation
the qualitative equation for right derivative
51:42.930 --> 51:49.930
of Lyapunov function x3x4 plus x4u for tracking
you found out this to be x4V dot is qualitatively
51:52.680 --> 51:59.680
equal to e3e4 plus e4 into V where V is x4
d minus x4 dot d minus u and u is the actual
52:15.710 --> 52:19.180
control action and V is the actual control
action.
52:19.180 --> 52:25.800
This V can be designed the same way as that
u in the regulation problem; I will not be
52:25.800 --> 52:32.800
going in detail because this and this has
the same structure. The rule base either using
52:33.510 --> 52:40.510
the PD type of controller or the state feedback
controller the two rule base will have same
52:41.340 --> 52:48.340
form, only thing that I am computing V. After
I compute V, V will have the same structure
52:50.270 --> 52:57.270
that we earlier derived the same way but given
V, I find out u to be x4 dot desired minus
53:00.520 --> 53:06.730
V. Doing that and also the parameters in the
first case will have three parameters and
53:06.730 --> 53:11.610
in the second case similarly ten parameters
that have to be optimized.
53:11.610 --> 53:18.610
By optimizing these parameters, we get this
is av not au, av is 1.5, ae3 1.23, ae4 is
53:24.010 --> 53:31.010
0.55 and for this tracking controller two
you have these parameters .37, .26 and these
53:34.340 --> 53:41.340
are the parameters for the state feedback
controller for four rules. So k1nn is 1.3
53:43.520 --> 53:50.520
and k1np is .9, k2nn is .6, k2np is .45 and
so on.
53:53.630 --> 54:00.630
Given that, the tracking result is x3 is plotted
against time desired PD and state feedback
54:02.560 --> 54:09.560
give the same result here for the tracking.
Tracking is not plotted because you see that
54:11.080 --> 54:18.080
the rule base is very small that we have taken
and also we have in this state feedback control
54:20.370 --> 54:27.370
are also we have rejected in the state feedback
the input of x1 and x3 the state feedback
54:31.400 --> 54:38.400
for x1 and x2. The tracking here is not right,
some loss here otherwise tracking is properly
54:38.750 --> 54:45.750
and the control action you can see both PD
and state feedback they behave almost similarly.
54:47.260 --> 54:52.860
Finally the summary, in this lecture following
topics have been covered a classical Lyapunov
54:52.860 --> 54:58.680
synthesis method is extended to the domain
of computing with words that means qualitatively
54:58.680 --> 55:05.680
how can we use a rate derivative of the Lyapunov
function in such a way that the rule base
55:05.790 --> 55:12.400
can be generated. This new approach is used
to design two different types of controller
55:12.400 --> 55:18.090
actually, the two different types of rule
base, controller is same fuzzy logic controller
55:18.090 --> 55:20.030
mamdani type.
55:20.030 --> 55:25.740
Rotational proof mass actuator system is presented
for simulation. Assuming minimal knowledge
55:25.740 --> 55:30.980
about the system we have systematically derived
fuzzy rules that constitute the rule base
55:30.980 --> 55:35.360
the controller. Using rule base controller
we have design for both regulation tracking
55:35.360 --> 55:40.260
purposes. Simulation results are presented.
55:40.260 --> 55:47.010
References in this case are some of the related
papers are you can easily see Fuzzy Lyapunov
55:47.010 --> 55:54.010
based approach to design the fuzzy controllers,
Fuzzy sets and system in 1999 by Margaliot
55:54.400 --> 56:01.400
and Langholz and same author also have a paper
on fuzzy control of a Benchmark problem; computing
56:02.590 --> 56:09.590
with words approach, IEEE transaction Fuzzy
Systems, 2004. And also we have a paper some
56:10.060 --> 56:15.770
work on the directional intelligent controls
schemes for a redundant manipulator presented
56:15.770 --> 56:22.770
in a conference held in Pune in 2005. Thank
you very much.
414