CMU
UM


Example: A State-space Controller for a Bus Suspension System

Designing the full-state feedback controller
Plotting the closed-loop response

From the main problem, the dynamic equations in state-space form are the following:


For the original problem setup and the derivation of the above equations, please refer to the main problem.

We want to design a feedback controller so that when the road disturbance (W) is simulated by a unit step input, the output (X1-X2) has a settling time less than 5 seconds and an overshoot less than 5%. For example, when the bus runs onto a 10 cm high step, the bus body will oscillate within a range of +/- 5 mm and will stop oscillating within 5 seconds.

The system model can be represented in Matlab by creating a new m-file and entering the following commands (refer to main problem for the details of getting those commands). We need to define the A, B, C, D matrices by entering the following into the m-file:

Designing the full-state feedback controller

First, let's design a full-state feedback controller for the system. Assuming for now that all the states can be measured (this assumption is probably not true but is sufficient for this problem), the schematic of the system should be:


The characteristic polynomial for this closed-loop system is the determinant of (sI-(A-B[1,0]'K)). Note that it's not sI-(A-BK) because the controller K can only control the force input u but not the road disturbance W. Recall that our B matrix is a 4 x 2 matrix, and we only need the first column of B to control u.

Since A and B*[1,0]'*K are all 4x4 matrices, there should be 4 closed-loop poles for the system. We might want to place the two dominant poles at -5 + 5i and -5 - 5i (this corresponds to zeta = 0.7 which gives 5% overshoot and sigma = 5 which leads to a 1 sec rise time). For the other two poles, we want to place them far to the left so that they won't affect the response too much. For now, let's try placing them at -20 and -100. Once we determine the closed-loop poles we want, Matlab can find the K matrix for us. Simply add the following code into the m-file:

Plotting the closed-loop response

Looking at the schematic above again, we see that after adding the K matrix into the system, the state-space equations become:


We can now obtain the closed-loop response by simply adding the following code into your m-file. Note that we need to multiply B matrix by 0.1 to simulate 0.1 m high step disturbance: Running the m-file in the command window, you should see the following plot:


This time the overshoot and settling time requirements are satisfactory, but we see a big steady-state error. A 10 cm high step on the road will leave a 3 mm deformation to the suspension system! This result is not acceptable, due to the high cost of buying new buses. How do you eliminate this steady-state error? Let's go back and change our four poles p1, p2, p3 and p4 with some trial & error. First try moving all of the poles further to the left to see whether it will help or not: Rerunning the program should yield the following plot:

Now the steady-state error is smaller than 1 mm. Since the overshoot is smaller than 1%, the settling time is about 0.5 sec and the steady-state error is smaller than 1%, we will determine that the response is satisfactory.

You might ask, can we eliminate the steady-state error? It is possible to build an estimater which will estimate not only the states but also the value of the step disturbance. A controller can then be designed which will drive all the states to zero even in the presence of this disturbance. This type of solution is beyond the scope of these tutorials and will not be introduced in detail here, but if you are interested, you may wish to consult Linear System Theory by W. J. Rugh, 2nd edition, p. 280, or another book on linear systems.


User Survey
Your anonymous answers to the following questions will help us to improve future versions of these tutorials.
How useful was this example?
Very useful Useful Somewhat useful Not very useful A waste of time
How was the level of the example?
Too simple About right Too difficult
How much time did you spend on it?
Less than 30 mins. 30 - 60 mins. More than 60 mins.
How much of the Matlab code did you run?
None Some Most

We would like to hear about suggestions you have for improvement, difficulties you had with the tutorials, errors that you found, or any other comments that you have. This feedback is anonymous.

If you would like to receive a response, send your comments or questions to ctm-feedback@umich.edu


State Space Examples
Cruise Control | DC Motor | Bus Suspension | Inverted Pendulum

Bus Suspension Examples
Modeling | PID | Root Locus | Frequency Response | State Space

Tutorials

Basics | Modeling | PID | Root Locus | Frequency Response | State Space | Examples

Home Index Commands

8/30/1996 YS