Lecture 4
Lecture 4
Lecture 4
The previous chapter introduced the concepts of open-loop and closed-loop con-
trol laws, and then dove into techniques for designing open-loop control laws
for robots based on optimal control and differential flatness. These techniques
are useful for determining control inputs that accomplish different objectives,
such as “move from point A to point B in a minimal amount of time while sat-
isfying some constraints”. Additionally, computing open-loop control laws is
often computationally less challenging that computing closed-loop control laws.
However in practice open-loop control is not very robust since observations
are not leveraged to update the control input. One solution to this robustness
problem is to convert the open-loop control law into a closed-loop control law,
typically referred to as trajectory tracking controllers. Another solution is to not
use any open-loop techniques but rather to directly synthesize a closed-loop
control law, for example by performing a Lyapunov stability analysis. This chap-
ter will introduce techniques for synthesizing closed-loop controllers in both of
these ways.
Recall from the previous chapter that open-loop control laws are defined as a
function of time for a given initial condition. In contrast, closed-loop control
laws are a function of the current state, and therefore are reactive.
Definition 3.0.1 (Closed-loop Control). If the control law is a function of the state
and time, i.e.,
u ( t ) = π ( x ( t ), t ) (3.1)
the system (e.g. wheel slipping), then the robot would not exactly reach its
desired destination. Alternatively, a closed-loop control law can continuously
correct for these errors since it is always taking in new information.
2. Design a closed-loop control law that is designed to make sure the system
stays close to the desired trajectory.
These controllers are referred to as trajectory tracking controllers, and their con-
trol law is defined as
u ( t ) = u d ( t ) + π ( x ( t ) − x d ( t ), t ). (3.2)
This type of control law is also said to be a “feedforward plus feedback” con-
troller. This is because the term ud (t) is an open-loop “feedforward” term that
attempts to generally make the system follow the desired trajectory, while the
term π ( x(t) − xd (t), t) is a “feedback” term that attempts to correct for any
errors.
The previous chapter discussed techniques for solving open-loop control
problems to define the desired trajectory, and additionally there are several
approaches for designing the feedback component π ( x(t) − xd (t), t):
• Geometric approaches generally leverage some sort of insight about the sys-
tem and are therefore hard to discuss in general settings. They are also typi-
cally difficult to derive theoretical guarantees for.
where z(q+1) is the q + 1-th order derivative of the flat outputs z and q is the
degree of the flat output space (i.e. the highest order of derivatives of the flat
output that are needed to describe system dynamics), and w is a modified “vir-
tual” input term.
The set of ODEs (3.3) are linear, which means that techniques from linear
control theory can be applied to design a control law for w. In particular, for
trajectory tracking problems suppose a reference flat output trajectory zd (t)
has been defined which corresponds to the virtual input wd (t). Let the error
between the actual flat output and desired flat output be defined as e(t) =
z(t) − zd (t) and consider a closed-loop control law of the form
q
∑ ki,j ei
( j)
wi (t) = wi,d (t) − ( t ), (3.4)
j =0
( j)
where (·)i denotes the i-th component of the vector, e( j) = z( j) − zd is the j-th
order derivative of the error, and k i,j are called controller gains. The application
of this control law to the system (3.3) will result in closed-loop dynamics of the
form
q
z ( q +1 ) = wd − ∑ K j e( j) ,
j =0
( q +1)
where K j is a diagonal matrix with i-th diagonal element k i,j . Since zd =
wd (t) this can be simplified to give the closed-loop error dynamics:
q
e ( q +1) + ∑ K j e( j) = 0. (3.5)
j =0
This set of linear ODEs describes the dynamics of the error, and many classical
techniques from linear control theory can be used to choose the gains k i,j that
will guarantee this system is stable. Having stable error dynamics means that
the error will decay to zero, which in this case means the system will track the
desired trajectory.
4 closed-loop motion planning & control
where the two inputs are the acceleration a(t) and the rotation rate ω (t). This
system is differentially flat with flat outputs x and y and order q = 1. It can
therefore be expressed as:
" # " #" # " #
ẍ cos(θ ) −V sin(θ ) a w1
z̈ = = := ,
ÿ sin(θ ) V cos(θ ) ω w2
| {z }
:= J
w1 = ẍd − k px ( x − xd ) − k dx ( ẋ − ẋd ),
w2 = ÿd − k py (y − yd ) − k dy (ẏ − ẏd ),
where (·)d represents a term associated with the desired trajectory. The control
inputs a(t) and ω (t) can then be computed by solving the linear system
" # " #
a w1
J = ,
ω w2
v = k1 ρ cos α,
sin α cos α (3.11)
ω = k2 α + k1 ( α + k 3 δ ),
α
where k1 , k2 , k3 > 0.
The candidate Lyapunov function is quadratic and therefore is positive ev-
erywhere, V ≥ 0, and is equal to zero only at the origin with ρ = 0, α = 0,
δ = 0. Therefore, if it is possible to show that along all closed-loop system tra-
jectories the Lyapunov function is decreasing (V̇ < 0), then it can be guaranteed
that the system will converge to the origin! To show that the Lyapunov function
decreases along trajectories of the system, begin by taking the derivative of V:
This quantity can now be shown to decrease along all closed-loop trajectories by
substituting in the dynamics equations (3.8) with the closed-loop control law as
defined by (3.11):
where in the last line the control laws were substituted in for v and ω and al-
gebraically simplified. Note that since k1 and k2 have been chosen to be strictly
positive, this function must be strictly negative for all values of ρ and α! There-
fore this Lyapunov stability analysis has theoretically proven that the system
under the closed-loop control law (3.11) will converge to the origin.
3.3 Exercises
Both exercises for this chapter can be found in the online repository:
https://github.com/PrinciplesofRobotAutonomy/AA274A_HW1.
[1] M. Aicardi et al. “Closed loop steering of unicycle like vehicles via Lya-
punov techniques”. In: IEEE Robotics & Automation Magazine 2.1 (1995),
pp. 27–35.
[2] J. Levine. Analysis and Control of Nonlinear Systems: A Flatness-based Ap-
proach. Springer, 2009.
[3] J.-J. E. Slotine and W. Li. Applied Nonlinear Control. Pearson, 1991.