Tut8-Lyapunov Functions
Tut8-Lyapunov Functions
Introduction
In this tutorial we will discuss Lyapunov functions: Lyapunov devised another technique
that can potentially show that an equilibrium is stable - the construction of what is now
called a Lyapunov function. An advantage of this method is that it can sometimes prove
stability of a nonhyperbolic equilibrium; a disadvantage is that there is no straightforward
construction of Lyapunov functions.
Lyapunov functions
Lyapunov functions are nonnegative functions that decrease in time along the orbits of a
dynamical system.
The function L is a weak Lyapunov function if the strong inequality is replaced by a weak
inequality, L(ϕt (x)) ≤ L(x).
If L ∈ C1 , the strong condition is equivalent to the condition dL dt < 0: If (1) is satisfied,
dL L(ϕt (x))−L(x)
then for any x ∈ U, dt ≡ limt→0 t < 0, and conversely, if dL
dt < 0 then at every
L(ϕt (x))−L(x)
point limt→0 t < 0 so necessarily, since L is continuous, then the first condition
follows.
Using the chain rule:
dL
0> = ∇L · ẋ = ∇L · f (x)
dt
so in the smooth case, the condition that L is a Lyapunov function is that its gradient
vector points in a direction opposed to that of the vector field f.
Some intuition: Assume an unstable fixed point x∗ = 0 has a trajectory leading out from
it in the infinitesimal region around 0 - a trajectory with x0 infinitesimally close to 0, that
satisfies in some region ||ϕt (x0 )|| > ||x0 ||. Therefore, a function L that satisfies L(0) = 0
and L(x 6= 0) > 0 cannot satisfy L(ϕt (x)) < L(x) on this trajectory - this can be visualized
in R2 .
Assume L is a strong Lyapunov function for an R2 flow. Recall the gradient of L at
x is always directed in the direction of the greatest increase in L. In R2 , this allows for
1
some graphical intuition as to what is the Lyapunov function: L̇ < 0 implies that the angle
between the gradient vector and the velocity vector is larger than 90◦ . It is fairly intuitive,
at least in R2 , that if this is the case everywhere along a phase trajectory then since L itself
is increasing away from the origin (which is the fixed point), then the trajectory will tend
towards the origin, i.e. the origin is a stable fixed point, see Fig. 1, Fig. 2.
Indeed, this can be proved for the general case Rn :
2
and the function L(y, z) = (y2 + z2 )/2. Then x∗ = (0, 0) is a fixed point, f (0, 0) = 0, and
indeed L(x∗ ) = 0. Also, L > 0 for x 6= (0, 0). Finally, the negative condition is satisfied:
∇L · f = yz + z(−y − 2z) = −2z2 ≤ 0. Therefore x∗ = (0, 0) is a stable fixed point.
Proof of stability: Consider a flow ϕt (x) defined by the function f (x) : Rn → Rn , and a
weak Lyapunov function L. Assume without loss of generality x∗ = 0.
We want to prove that for any ε > 0 there exists a δ > 0 such that if x0 < δ then
ϕt (x0 ) < ε for all times t > 0.
Choose ε > 0 such that the ball of radius ε around the origin is in U. Then, let’s define
m = min||x||=ε L(x). The constant m exists since ||x|| = ε is compact. Since L is positive
definite, m > 0.
From continuity of L and L(0) = 0, there exists some 0 < δ < ε such that for any
||x|| < δ , L(x) < m. Choose an initial condition ||x0 || < δ . Since L(ϕt (x)) is decreasing,
L(ϕt (x0 )) < m. We claim this implies ϕt (x0 ) < ε:
Assume by contradiction that there exists a time t1 such that ϕt1 (x0 ) > ε. Then there
is a time t2 such that ϕt2 = ε, but L(ϕt2 ) < m = min||x||=ε L, which is a contradiction.
Proof of asymptotic stability: Consider the case that L is a strong Lyapunov function.
Then it is also a weak Lyapunov function and for ||x0 || < δ , ϕt (x0 ) < ε. We need to prove
ϕt (x0 ) → 0 for t → ∞.
Since L is strictly decreasing and non-negative, a sequence {ϕtn (x0 )}∞n=1 has a limit in
the region, L(ϕtn (x0 )) → c ≥ 0 when n → ∞. Assume by contradiction c > 0, and have
z ∈ Bε (0) the point at which this value is acquired. Then L(ϕt (z)) < c, and ϕtn +s (x0 ) →
ϕt (z). Therefore, for a large enough n, L(ϕtn +s (x0 )) < c. Finally, find m > n such that
tm > tn + s to obtain the contradiction.
Example: Any linear system ẋ = Ax that is asymptotically stable has a strong Lyapunov
function, of the form L = xT Sx, where S is a symmetric matrix: Note that L̇ is negative if
for all x 6= 0. To solve this, we can require AT S + SA = −I (called the Lyapunov equa-
tion), and then L̇ = −|x|2 < 0 for x 6= 0. Then this equation always has a solution when
´∞ T
A’s eigenvalues have negative real parts, by S = 0 eτA eτA dτ. This can be checked by
T
plugging this S into the Lyapunov equation, multiplying the equation by etA from the left
and by etA from the right, and noticing that the left hand side becomes a full derivative.
3
We shall not show the proof.
Although this theorem guarantees that a strong Lyapunov function exists for an asymp-
totically stable equilibrium, it is not possible to construct it using this method unless the
flow can be obtained analytically - in which case there is no reason to find L! However,
there are cases in which it is not hard to find a Lyapunov function and for which stability
is not obvious. You will see some examples in the HW.
An example
The equations for the damped pendulum, in dimensionless variables, can be written in the
following form:
ẋ = y, ẏ = −y − sin x.
(a) Show that the origin is a stable fixed point using the energy function V (x, y) =
1 2
2 y + (1 − cos x).
Solution:
∇V · f = sin xy + y(−y − sin x) = −y2 ≤ 0.
(b) Show that the origin is an asymptotically stable fixed point using a ”better” Lya-
punov function V (x, y) = 12 (x + y)2 + x2 + 12 y2 than the energy function.
Solution:
∇V · f = 2xy − y2 − (x + 2y) sin x ≈ 2xy − y2 − x2 − 2xy = −(x2 + y2 ) < 0.
except if x = y = 0.