Lecturer

Set up MATLAB

cd matlab
pwd
clear all
imatlab_export_fig('print-svg')  % Static svg figures.
format compact
Copy to clipboard
ans =
    '/Users/eechris/code/src/github.com/cpjobling/eglm03-textbook/03/2/matlab'
Copy to clipboard

3.2. Introduction to Root Locus Design

In this section we will engage in a short exploration of compensator design in the time domain with a look at root-locus design of a velocity-feedback compensator for a simple “double integrator” system. This serves as an introduction to the topic of phase lead compensation which is used to improve transient performance and relative stability.

3.2.1. Gain compensation

First design example (Satellite Attitude Control). The system may be represented in block diagram form as shown in Figure 1. (Simulink model: satellite.slx)

Satellite control with gain modulated torque

Figure 1 Satellite control with gain modulated torque

For this system the plant transfer function is

G(s)=1s2

Feedback:

H(s)=1

Controller:

D(s)=K

The root locus equation is:

1+KG(s)H(s)=0

with root locus parameter = K.

Defining the problem in Matlab

G = tf(1,conv([1,0],[1,0]));
H = tf(1,1);
Go = G*H
Copy to clipboard
Go =
Copy to clipboard
   1
Copy to clipboard
  ---
Copy to clipboard
  s^2
Copy to clipboard
Continuous-time transfer function.
Copy to clipboard

Note: The root locus gain K is implied in Matlab (it does not need to be defined)

rlocus(Go),title('Root locus diagram for gain modulated satellite attitude control')
Copy to clipboard
../../_images/velfb_10_0.svg

Pick off an arbitrary gain

[K]=rlocfind(Go,3/4j)
Copy to clipboard
K =
    0.5625
Copy to clipboard

Closed-loop transfer function

Gc = feedback(K*G,H)
Copy to clipboard
Gc =
Copy to clipboard
     0.5625
Copy to clipboard
  ------------
Copy to clipboard
  s^2 + 0.5625
Copy to clipboard
Continuous-time transfer function.
Copy to clipboard
Gc(s)=0.5625ss+0.5625
step(Gc,45),title('Step response for closed-loop system with K=sqrt(3)/2')
Copy to clipboard
../../_images/velfb_16_0.svg

3.2.2. With velocity feedback,

The block diagram becomes that shown in Figure 2 (Simulink model: velfb.slx).

velfb
Copy to clipboard

The root locus equation is

1+KKT(s+1/KT)s2=0

where KKT is the root locus gain.

System with velocity feedback

Figure 2 System with velocity feedback

Kt = 0.5;
Go2=tf(Kt*[1, 1/Kt],[1,0,0]);
rlocus(Go2),title('Root locus of system with velocity feedback')
Copy to clipboard
../../_images/velfb_21_0.svg

3.2.3. Closed-loop step response

Go(s)=1s×K/s1+(KKT)/s
Go(s)=Ks(s+KKT)
Gc(s)=Ks2+KKTs+K
[K] = rlocfind(Go2,-2+2j)
Copy to clipboard
K =
     8
Copy to clipboard
Integrator=tf(1,[1,0]);
G1=feedback(K*Integrator,Kt)*Integrator;
Gc2=feedback(G1,1)
Copy to clipboard
Gc2 =
Copy to clipboard
        8
Copy to clipboard
  -------------
Copy to clipboard
  s^2 + 4 s + 8
Copy to clipboard
Continuous-time transfer function.
Copy to clipboard
step(Gc2),title('Step response for velocity feedback (rate) compensated system')
Copy to clipboard
../../_images/velfb_25_0.svg

Since KKt=4

Kt = 4/K
Copy to clipboard
Kt =
    0.5000
Copy to clipboard

Running the simulink model with these values should give you the same result.

3.2.4. Resources

An executable version of this document is available to download as a MATLAB Live Script file velfb.mlx.

The Simulink model of the satellite attitude control system is satellite.slx.

The system with velocity feedback control is available as velfb.slx.