Lecture 4
Lecture 4
Lyapunov stability
1
Previously
Over the last 2 lectures we considered qualitative
approaches to investigating nonlinear systems
Looked at drawing phase portraits
Linearising the system and classifying the
critical point
In 436-433 we briefly discussed Lyapunov
stability for (linear) digital systems
A more quantitative approach
There was some reason behind introducing this
concept
Today we will look at stability of nonlinear
continuous time systems using the method of
Lyapunov
2
Nonlinear stability
Types of stability:
x2 zone of
x2 x2
attraction
x1 x1 x1
Asymptotic stability
trajectories approach equilibrium point as t
Stability 'in the sense of Lyapunov'
equilibrium point is stable if all trajectories
starting 'nearby' stay nearby
3
Lyapunov stability analysis
Concept: seek a scalar function of the states V(x)
which is positive definite in a region R around the
equilibrium point: V(x) > 0, except V(0) = 0
The function V is a Lyapunov function if V is
negative semi-definite in R: V (x) 0
The existence of a Lyapunov function is sufficient
to prove stability (in the sense of Lyapunov) in the
region R
If V is negative definite, the equilibrium is
asymptotically stable
For a discrete-time system x(k + 1) = f(x(k)); f(0) = 0 :
V (x(k ) ) > 0, except V (0) = 0
V (x(k ) ) V (f (x(k ) ) V (x(k ) ) 0
4
Example: damped simple pendulum
x1 = x2
g c
x2 = sin x1 2 x2
l ml
The total mechanical energy is a good candidate
Lyapunov function. Consider the equilibrium point
x = [ ] = [0 0]
T
T
6
Pendulum stability, contd
At the boundary of Mc we have
V (x) = 12 ml 2 x22 + mgl (1 cos x1 ) = 2mgl
The solution defines the separatrix:
x2 = 2 g (1 + cos x1 ) / l
Within this region, we have V(x) > 0 (except at x = 0)
and V (x) = cx22
For V (x) 0 we would require x2 0. That is,
g c
x2 = sin x1 2 x2 0
l ml
Within Mc this requires x1 = 0. That is, no solution
except x = 0 remains in the subset of Mc where V (x) 0
Hence solutions starting within the region defined
by the separatrix are asymptotically stable
7
Vector
2.5
field
Vectorand
field andcontours of V
contours of total energy
1.5
0.5
x2(l/g)
-0.5
-1
-1.5
-2
-2.5
-4 -3 -2 -1 0 1 2 3 4
x1
8
Pendulum Lyapunov function
V ( x) = 12 ml 2 x22 + mgl (1 cos x1 )
9
An alternative Lyapunov function
The damped pendulum: x1 = x2
g c
x 2 = sin x1 2 x2
The total mechanical energy is l ml
g
V (x) = 12 ml 2 x22 + mgl (1 cos x1 ) = ml 2 12 x22 + (1 cos x1 )
l
Try a more general quadratic
g
V (x) = 2 x Px + (1 cos x1 )
1 T
l
p11 p12 x1 g
= 2 [x1 x2 ]
1
+ (1 cos x1 )
p12 p22 x2 l
= ( p x + 2 p12 x1 x2 + p x ) + (1 cos x1 )
1 2 g 2
2 11 1 22 2
l
For xTPx to be positive definite
p11 > 0, p22 > 0, p11 p22 p122 > 0 10
An alternative Lyapunov function
V ( x) = ( p x + 2 p12 x1 x2 + p x ) + (1 cos x1 )
1 2 2 g
2 11 1 22 2
l
Rate of change:
g g c
V (x) = p11 x1 + p12 x2 + sin x1 x2 + ( p12 x1 + p22 x2 ) sin x1 2 x2
l l ml
g g
= (1 p22 )x2 sin x1 p12 x1 sin x1
l l
c c 2
+ p11 p12 2 x1 x2 + p12 p22 2 x2
ml ml
Select p11, p12, p22 such that V (x) < 0
c
p22 = 1 (eliminate x2 sin x1 ) p11 = 2 p12 (eliminate x1 x2 )
ml c c
Then, p12 > 0 ( x1 sin x1 > 0, 0 <| x1 |< ) and, p12 < 2 p22 = 2
ml ml
c c
i.e., 0 < p12 < 2 Let p12 = 12 2 , say
ml ml 11
An alternative Lyapunov function
1 1 c
2
2 c g
Then, V (x) = 2 2 2 x1 + 2 x1 x2 + x2 + (1 cos x1 )
2
ml ml l
1 g c 1 c
V (x) = 2 x1 sin x1 2 x22
2 l ml 2 ml
Hence, over R : |x1| <
V ( x) > 0 positive definite
V (x) < 0 negative definite
That is, the origin is asymptotically stable
1.5
x2(l/g)
0
-1.5
attraction -2
-2.5
Lyapunov equation: A P + PA = Q
T
17
Example
Damped nonlinear oscillator: y + 2y + (1 y ) y = 0
State variables: x1 = y, x2 = y
State equations: x1 = x2
x2 = (1 x1 ) x1 2x2
Equilibrium points: x = 0 x2 = 0, x1 = 0 or 1
f 0 1
Linearise: A= =
x 0 1 + 2 x1 2 0
0 1 Stable
E1: (0, 0) A = , ( A ) = j 1 2
1 2 focus
= j
0 1
E2: (1, 0) A= , ( A ) = 1 + 2
Saddle
1 2
18
Region of attraction for E1: (0,0)
In this example, analysis simplified if we use modal
state variables:
0 1 i 1 1 1
A= , i I A = , v = =
(1)
1 2 1 i + 2
1 + j
1 0 Ad
Real modal matrix: T =
Similarity transformation : z = Tx z = z
1 z1 1 0 x1 y
z=T x = =
z
2 / 1/ x
2 ( y
+ y ) /
Nonlinear equations in modal variables :
0 1 1 0 0 0
x = Ax + 2 z = T ATz + 2
z = A d z + 2
x1 / 1/ x1 z1 / 19
0
z = z + 2 = A d z + g(z )
z1 /
Solve Lyapunov equation: A d P + PA d = I P = I / 2
T
V (z ) z1 z2 z1 + z2
V (z ) = z =
z z1 z2 + z12
2
z z
= ( z12 + z22 ) + 1 2
Clearly V < 0 close to the origin. Now find where V = 0
2
z1 z2
V = 0 (z + z )+
2
1
2
2 =0
2 3
z z
z12 = 2
Vthresh = 2
where V = 0
z2 / 1 2 ( z2 )
20
z23
Vthresh =
2 ( z2 )
Now we know that along this line:
Vthresh (z ) Vthresh ( z2 )
Vthresh (z ) = z = z2 = 0
z z2
But we are not at an equilibrium point (or line) so z2 0
Vthresh ( z2 ) z23
= =0
z2 z2 2 ( z2 )
0.5
z2 = (y' + y)/
-0.5
-1
-1.5
-2 -1.5 -1 -0.5 0 0.5 1 1.5 2
z1 = y
22
Contours of dV/dt in phase
plane
V (z ) = 0 contour
= 0.3
V (z ) > 0
Boundary of
actual region of
attraction
(separatrix)
Boundary of
estimated region of
attraction
V (z ) < 0
23
Rate of change of V(z) in phase plane
V (z ) = 0 contours
24
= 0.3
(1, 1.5)
unstable trajectory
(0.5, 1.5)
stable trajectory
Contours of V
in phase plane
25
Summary
The existence of a Lyapunov function proves stability
for a system
However, just because one Lyapunov function doesnt
give stability doesnt mean the system is unstable
For linear systems the exercise is pretty much
academic
For nonlinear systems we can get an estimate of the
basin of attraction of an equilibrium point after
linearisation about the equilibrium point
26