Ma · Mathematics

How to Find a Lyapunov Function for a Nonlinear Time-Varying ODE

Published By the 9to5Science editorial team

At a glance

  1. 1. Check the equilibrium

    Write the system as ẋ = f(t, x) and verify that the equilibrium, usually x = 0, satisfies f(t, 0) = 0.

  2. 2. Choose a candidate

    Try a positive function of the state, or one that also depends explicitly on time.

  3. 3. Differentiate along solutions

    Use the chain rule, including the explicit time derivative of V(t, x).

  4. 4. Apply stability bounds

    Compare V and its derivative with positive functions of the state norm to establish stability or convergence.

A Lyapunov function is a way to study the stability of an equilibrium without solving the differential equation explicitly. For a non-autonomous nonlinear system, the right-hand side depends on time as well as the state, so the Lyapunov function may depend on both.

Write the system as

x˙=f(t,x),x∈Rn.\dot{x}=f(t,x), \qquad x\in\mathbb{R}^n.

The usual target is the equilibrium x=0x=0. It must actually be an equilibrium: f(t,0)=0f(t,0)=0 for every time under consideration. The key test is to find a function that is positive near the equilibrium and decreases along trajectories.

Differentiate the function along a solution

Let V(t,x)V(t,x) be continuously differentiable. Along any solution x(t)x(t), the chain rule gives

V˙(t,x)=∂V∂t(t,x)+∇xV(t,x) f(t,x).\dot V(t,x)=\frac{\partial V}{\partial t}(t,x)+\nabla_x V(t,x)\,f(t,x).

The term ∂V/∂t\partial V/\partial t is essential if VV depends explicitly on time. Omitting it can lead to a wrong stability conclusion. If VV depends only on xx, that term is zero, and the formula reduces to the familiar autonomous-system expression.

A useful stability test compares VV with the distance from the equilibrium. For example, suppose in a region around the origin there are class K\mathcal{K} functions α1\alpha_1 and α2\alpha_2 (continuous, strictly increasing, and zero at zero) such that

α1(∥x∥)≤V(t,x)≤α2(∥x∥).\alpha_1(\lVert x\rVert)\le V(t,x)\le\alpha_2(\lVert x\rVert).

These uniform-in-time bounds say that VV is positive away from the equilibrium and does not become arbitrarily small or large merely because time changes. If also V˙≤0\dot V\le 0, the equilibrium is stable under the standard Lyapunov conditions. If, more strongly,

V˙(t,x)≤−α3(∥x∥),\dot V(t,x)\le-\alpha_3(\lVert x\rVert),

for another class K\mathcal{K} function α3\alpha_3, trajectories are driven toward the equilibrium; with the stated uniform bounds, this gives uniform asymptotic stability. If the bounds and derivative inequality hold globally, and the lower bound is radially unbounded (for example, α1\alpha_1 is class K∞\mathcal{K}_\infty), the strict derivative bound gives global asymptotic stability, provided solutions exist for all forward time. With only V˙≤0\dot V\le 0, the global conclusion is stability, not necessarily convergence. Local inequalities establish only local results.

A worked nonlinear, time-varying example

Consider the scalar equation

x˙=−(1+sin⁡2t)x−x3.\dot{x}=-(1+\sin^2 t)x-x^3.

The coefficient varies with time, and the cubic term makes the system nonlinear. The origin is an equilibrium because the right-hand side is zero at x=0x=0 for every tt.

Try the simple candidate

V(x)=12x2.V(x)=\frac{1}{2}x^2.

It is positive for every x≠0x\ne0 and equals zero at the equilibrium. Since VV has no explicit time dependence, its derivative along a solution is

V˙=xx˙=x(−(1+sin⁡2t)x−x3)=−(1+sin⁡2t)x2−x4≤−x2=−2V.\begin{aligned} \dot V &=x\dot{x}\\ &=x\bigl(-(1+\sin^2 t)x-x^3\bigr)\\ &=-(1+\sin^2 t)x^2-x^4\\ &\le -x^2=-2V. \end{aligned}

The inequality uses sin⁡2t≥0\sin^2 t\ge0 and x4≥0x^4\ge0. Therefore VV decreases at least as fast as the solution of V˙=−2V\dot V=-2V. Integrating that comparison gives

V(t)≤V(t0)e−2(t−t0),t≥t0.V(t)\le V(t_0)e^{-2(t-t_0)}, \qquad t\ge t_0.

Because V=x2/2V=x^2/2, this implies

∣x(t)∣≤∣x(t0)∣e−(t−t0).|x(t)|\le |x(t_0)|e^{-(t-t_0)}.

Thus the origin is globally exponentially stable: every initial value converges to zero, with an explicit exponential bound. This example also shows that a time-varying system does not necessarily require a time-varying Lyapunov function.

How to choose a candidate

There is no universal recipe, but these starting points are common:

  • For systems with a linearization that suggests a quadratic energy, try V(x)=xTPxV(x)=x^TPx, where PP is symmetric positive definite.
  • For scalar equations, try V(x)=x2/2V(x)=x^2/2 or another positive power of ∣x∣|x| that is differentiable where needed.
  • For mechanical or physical models, try an energy-like expression, such as kinetic plus potential energy.
  • If the coefficients or forcing vary with time, consider V(t,x)V(t,x), or a state-only candidate whose derivative can still be bounded uniformly in time.

A candidate need not make the derivative strictly negative everywhere to prove stability. A nonpositive derivative can be enough for stability, while asymptotic convergence generally requires additional conditions, such as a negative-definite bound or a suitable invariance argument. For non-autonomous systems, the exact theorem and its uniformity assumptions matter; checking only that VV decreases at each instant may not establish uniform convergence.

Common mistakes

  • Ignoring explicit time dependence: For V(t,x)V(t,x), include ∂V/∂t\partial V/\partial t in the derivative.
  • Checking positivity only at one time: A time-dependent candidate should satisfy the needed positive bounds throughout the time interval, typically uniformly in time.
  • Confusing stability with convergence: A nonincreasing VV can keep trajectories near the equilibrium without proving they approach it.
  • Claiming a global result from local bounds: If the inequalities hold only near zero, the conclusion is local.
  • Forgetting existence of solutions: A global stability claim also requires that solutions continue to exist for all future time.

The practical method is to verify the equilibrium, choose a positive candidate, compute its full derivative along trajectories, and match the resulting inequalities to a stability theorem whose assumptions apply to the region and time interval you are studying.

References

  1. Nonlinear Systems, 3rd ed., Hassan K. Khalil
  2. Stability and Stabilization of Nonlinear Systems, Jean-Jacques E. Slotine and Weiping Li

Spotted an error? Send a correction. Read how we write and check articles in our editorial policy.