CMU
UM


Example: Root Locus Design Method for the Bus Suspension System

Plotting the root locus
Adding a notch filter
Finding the gain from the root locus
Plotting closed-loop response

From the main problem, the dynamic equations in transfer function form are the following:




and the system schematic looks like:

For the original problem setup and the derivation of the above equations and schematic, please refer to the bus modeling page.

If you are interested in running an animation of this example based on the control techniques used in the root locus tutorial please go to the bus suspension animation page after completing this tutorial.

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 are now ready to design a controller using the root locus design method.

First let's see what the open loop poles of the system are:

Matlab should return:
Therefore the dominant poles are the roots -0.1098+/-5.2504i, which are close to the complex axis with a small damping ratio.

Plotting the root locus

The main idea of root locus design is to estimate the closed-loop response from the open-loop root locus plot. By adding zeros and/or poles to the original system (adding a compensator), the root locus and thus the closed-loop response will be modified. Let's first view the root locus for the plant. In your m-file, add the following command and then run the file, you should get the root locus plot below:

Note from the specification, we required the overshoot, %OS, to be less than 5% and damping ratio, zeta, can be find from approximation damping ratio equation, z = -log(%OS/100)/sqrt(pi^2+[log(%OS/100)^2]). The commandsgrid is used to overlay desired percent overshoot line on the close-up root locus, you can find more information from commands list.

From the plot above, we see that there are two pair of the poles and zeros that are very close together. These pair of poles and zeros are almost on the imaginary axis, they might make the bus system marginally stable, which might cause a problem. We have to make all of the poles and zeros move into the left-half plane as far as possible to avoid an unstable system. We have to put two zeros very close to the two poles on the imaginary axis of uncompensated system for pole-and-zero cancellation. Moreover, we put another two poles further on the real axis to get fast response.

Adding a notch filter

We will probably need two zeros near the two poles on the complex axis to draw the root locus, leaving those poles to the compensator zeros instead of to the plant zeros on the imaginary axis. We'll also need two poles placed far to the left to pull the locus to the left. It seems that a notch filter (2-lead controller) will probably do the job. Let's try putting the zeros at 30 and 60 and the poles at 3+/-3.5i. In your m-file add the following lines of code:

Add % in front of the rlocus(nump,denp) command (Matlab treats any text after a % sign as a comment) and rerun the m-file, you should get a new root locus plot looking like this:


Now let's change axis to see the details of the root locus.

Finding the gain from the root locus

Now that we have moved the root locus across the 5% damping ratio line, we can choose a gain that will satisfy the design requirements. Recall that we want the settling time and the overshoot to be as small as possible. Generally, to get a small overshoot and a fast response, we need to select a gain corresponding to a point on the root locus near the real axis and far from the complex axis or the point that the root locus crosses the desired damping ratio line. But in this case, we need the cancellation of poles and zeros near the imaginary axis, so we need to select a gain corresponding to a point on the root locus near zeros and percent overshoot line. There is a method to do this with the rlocfind command in matlab. Enter the following command into the Matlab command window:

Go to the plot and select the point at the position mentioned above (indicated by the white cross on the plot below:


You should see something similar to the following: Note that the value returned from your Matlab command window may not be exactly the same, but should at least have the same order of magnitude. This returned value can be used as the gain for the compensator. Add this gain to the system: Recall that the schematic of the system is the following:

and the closed-loop transfer function can be derived as following:

To obtain the closed-loop transfer function from W to X1-X2, add the following to your m-file:

Note that the function "polyadd" is not a Matlab standard function. You will need to copy it to a new m-file to use it. Click here for more information.

Plotting the closed-loop response

Let's see what the closed-loop step response looks like with this compensator. Keep in mind that we are going to use a 0.1 m high step as the disturbance. To simulate this, simply multiply numa by 0.1. Add the following commands into the m-file and put % marks in front of all rlocus and rlocfind commands.

and you should see the following plot:


From this plot we see that when the bus encounters a 0.1 m step on the road, the maximum deviation of the bus body from the wheel (or the road) is about 3.75 mm, and the oscillations settle in 2 seconds. Thus this response is satisfactory.

Note: A design problem does not necessarily have an unique answer. Using the root locus method (or any other method) may result in many different compensators. For practice, you may want to go back to the original open-loop root locus and try to find other good ways to add zeros and poles to get a better response.

If you are interested in running an animation of the bus suspension example based on the control techniques used in this tutorial please go to the Bus Suspension Animation Page.


User Feedback

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.


Root Locus Examples
Cruise Control | Motor Speed | Motor Position | Bus Suspension | Inverted Pendulum | Pitch Controller | Ball and Beam

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

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

Home Index Command

6/25/97 PP
8/24/97 WM