In this tutorial, we provide an introduction to feedback linearization, and how this method can be used to elegantly derive controllers of dynamical systems. We also provide Simulink block diagrams that simulate the closed-loop system. The YouTube video accompanying this tutorial is given below.
Our teaching philosophy is to explain the main ideas of an approach by using examples. Only in the later stage, the theory should be explained. That is, students should first obtain a strong hands-on knowledge of a concept, and in the later stage, they should enlarge and deepen their knowledge by studying the theory. Accordingly, by following this approach we explain the feedback linearization by using an example.
Let us consider a pendulum system shown in the figure below.
In our previous tutorial, which can be found here, we derived an equation of motion of this system. The equation of motion is given below
(1)
where is the gravitational acceleration constant, is the mass of the ball, is the length of the rod, and is the external force acting on the ball. This force is perpendicular to the rod. Here, we assume that the force is a control force. Consequently, we can express this force as follows
(2)
where is a constant and is the control input. From the previous two equations, we have
(3)
We rewrite this equation as follows
(4)
Next, we introduce the state-space variables
(5)
In our previous tutorial, we explained how to derive the state space model. The state-space model has the following form
(6)
This is a nonlinear state-space model because of the term . This term significantly complicates the control system design. If we would be able somehow to cancel this term, then we would significantly simplify the control system design.
In a nutshell, the main idea of feedback linearization is to determine a control input that will
- Cancel the nonlinear term
(7)
on the right-hand side of the equation (6).
2. Assign (place) the poles of the feedback-linearized closed-loop system to desired locations such that the system is stabilized around the desired point.
In our case, we are interested in asymptotic stabilization of the control system around the stable equilibrium point . Of course, the feedback linearization approach can easily be generalized for the case of set-point tracking. That is, we can select any point around which we want to stabilize the system. This will be explained in future tutorials. For the time being, in order not to blur the main ideas of feedback linearization with too many details, we focus on the simplest possible case. That is, we focus on stabilization around the equilibrium point .
Here is the main idea of feedback linearization. We want the right-hand side of the second state-equation to be
(8)
where and are control parameters that we need to design such that the system is asymptotically stable. From the last equation, we obtain
(9)
The equation (9) is our feedback control law. Note that this is a state feedback control law that will “exactly” linearize the closed loop system. Although the closed-loop system will become linear, the feedback control law is still nonlinear. Let us substitute the control law (9) in our state-space model (6). As the result, we obtain
(10)
and consequently, we obtained a linear closed-loop system. That is, we have “exactly” linearized the nonlinear system.
The next task is to find the control system parameters and that will render the closed-loop system asymptotically stable. There are many ways to do that. Let us follow a textbook approach that is based on pole placement and computation of the characteristic polynomial.
The closed loop system can be written in the following form
(11)
where the matrix is defined by
(12)
The characteristic polynomial is given as
(13)
where
(14)
Consequently, the characteristic polynomial is
(15)
Let us place the closed-loop poles at the following locations
(16)
Consequently, the desired closed-loop characteristic polynomial is
(17)
The desired polynomial should be equal to the parametrized characterized polynomial. That is, the equation (15) and the equation (17) should be equal. Consequently, we have
(18)
From this equation, we obtain the parameters and :
(19)
Next, we explain how to simulate the system in Simulink. First, we simulate the system without any control. That is we simulate the equation:
(20)
The parameters for the simulation are
(21)
with the initial conditions
(22)
The Simulink block diagram is given in the figure below.
This block diagram solves the differential equation. The solution is shown in the figure below.
Next, we add a control input, and simulate the scaled step response. The equation we simulate is given below.
(23)
where we assume that
(24)
The simulation results are given below.
Next, we simulate the feedback linearization control law. The control parameters (19) produce the following control law
(25)
The block diagram corresponding to this control law is given below.
The response of the system is given below (theta variable).
As we can observe, the system is asymptotically stabilized. That is, the closed-loop system is asymptotically stabilized by the feedback nonlinear control law.