by
Telemark College
Porsgrunn, Norway
February 25,
1998
This publication can be downloaded and copied freely, but reference to the source is appreciated.
Contents:
1 Introduction
2 Creating and handling LTImodels (Linear TimeInvariant)
2.1 Creating models
2.2 Extracting subsystems
2.3 Setting and accessing LTIproperties
2.4 Conversion between statespace models and transfer functions
2.5 Conversion between continuoustime and discretetime models
2.6 Combining models (series, parallel, and feedback)
3 Model analysis tools
3.1 Simulation (time response)
3.2 Poles, eigenvalues, and zeros
3.3 Frequency response
3.4 Stability analysis based on frequency response
3.5 Padeapproximations
3.6 The LTIviewer
4 Controller design tools
4.1 Root locus
4.2 Pole placement
4.3 Optimal control
4.4 Kalman estimator (or filter)
5 Overview over functions in Control System
Toolbox
This text gives an easy guide to Control System Toolbox version 4 which assumes the installation of MATLAB version 5.
The text is selfinstructive: You are asked to perform a number of simpe tasks through which you will learn to master this toolbox, and the expected responses are even shown in the text.
It is assumed that you have the basic knowledge about dynamic systems and control theory. It is also assumed that you have basic skills in MATLAB. May I suggest Learn MATLAB 5 in 6 hours!? (See http://www.techteach.no/textbook.htm). And if you want to simulate your (control) systems, you should consider using SIMULINK which is based on MATLAB. Learn SIMULINK 2 in 3 hours! (see www.techteach.no) gives an introduction.
Compared to the older versions of this toolbox, this version has some new features:
In the following, CST will be used as an abbreviation for Control System Toolbox.
The models supported by CST are continuoustime models and discretetime models of the following types:
The CST also supports zeropolegain models, but since we will in practice hardly use that model format, it is not described in this text. If you need to use it, you can get information by executing "help zpk".
The various functions will be introduced via simple examples.
H0(s) = K0*s/(T0*s+1)
K0=2; T0=4; 
To display H0 we execute
H0 
Transfer function:
 2 s

4 s + 1
An LTImodel can contain a timedelay, as in the following model:
Hd(s) = [K0*s/(T0*s+1)]e^(Tdelay*s)
Tdelay=1; 
To display Hd we execute
Hd 
MATLAB's response is
Transfer function:
2 s

4 s + 1
 Input delay: 1
The expressions below create a twoinput oneoutput MIMO (MultipleInput MultpleOutput) system of the form
y(s) = H1(s) u1(s) + H2(s) u2(s)
The transfer function can be expressed as
H=[H1,H2]
K1=2; T1=4; num1=[K1,0]; den1=[T1,1]; 
To display H we execute
H 
MATLAB's response is
Transfer function from input 1 to output:
2 s

4 s + 1Transfer function from input 2 to output:
3

5 s + 1Input delays (listed by channel): 1 2
Note 1: If the system has no timedelay, it is sufficient to write
tf(num1,den1).
Note 2: If the transfer function has the form
H(s) = [H1(s)
H2(s)]
which may correspond to a oneinput twooutput system, the CST requires that the timedelays are equal.
[numHd,denHd,Ts]=tfdata(Hd) 

dx/dt = Ax + Bu
y = Cx + Du
dx1/dt = x2
dx2/dt = 4*x1 2*x2 + 2*u
y = x1
This model is created by
A=[0,1;4,2]; B=[0;2]; C=[1,0];
D=[0]; 
To display ss1 we execute
ss1 
MATLAB's response is
a =x1 x2
x1 0 1.00000
 x2 4.00000 2.00000
b =u1
x1 0
x2 2.00000
c =x1 x2
y1 1.00000 0
d =u1
y1 0
Continuoustime system.
Above, a, b, c, and d, which are default names, are used only for displaying purposes, and they do in fact not exist in the workspace. To retreive the system parameters and give them specific names, we can execute
[A1,B1,C1,D1,Ts]=ssdata(ss1) 
MATLAB's response is
A1 =0 1
4 2
B1 =0
2
C1 =1 0
D1 =0
Ts =0
Discretetime (z)transfer functions and statespace models are created in the same way as for continuoustime models.
Hdis(z) = (z+0.5)/(z^{2}+1.5*z+2)
with sampling time 0.4 (timeunits), we execute
numdis=[1,0.5]; dendis=[1,1.5,2];
Tsdis=0.4 
To display Hdis we execute
Hdis 
Hdsp(z) = (1+0.5*z^{1})/(1+1.5*z^{1}+2* z^{2})
with sampling time 0.4 (timeunits), we execute
numdsp=[1,0.5]; 
To display Hdsp we execute
Hdsp 
 Transfer function:
 1 + 0.5 z^1
 
 1 + 1.5 z^1 + 2 z^2
 Sampling time: 0.4
x(k+1) = Ad*x(k) + Bd*u(k)
y(k) = Cd*x(k) + Dd*u(k)
where Ad, Bd, Cd, and Dd are matrices. x(k) is the statevariable, u(k) is the input variable, and y is the output variable (these variables are generally vectors having one or more elements). k is the discretetime or timeindex. Discretetime statespace models are created using the syntax
ssdis=ss(Ad, Bd, Cd, Dd, Ts)
sys1=sys(outputno,inputno)

Transfer function from input 2 to output:
3

5 s + 1Input delay: 2
In fact, we can use ordinary matrixlike accessing, like for example "subsys=sys(1,2:4)" which selects inputs 2 to 4 and output 1, that is, three subsystems altogether.
Several properties can be attached to the LTIobjects (or LTImodels). The table belos gives an overview over the properties. To get detailed information about legal values of the properties, execute "help ltiprops".
In the table below, NU, NY, and NX refer to the number of inputs, outputs, and states (when applicable). TF refers to transfer functions, SS to statespace models, and ZPK to zeropolegain models.
Name 
Description 
Applies to LTIobject of type 

Sample Time 
All 
Td 
Input delays 
All (only continuous systems) 
Inputname 
Input names 
All 
Outputname 
Output names 
All 
Notes 
Notes on model history 
All 
Userdata 
Additional data 
All 
Num 
Numerator 
TF 
Den 
Denominators 
TF 
Variable 
Transfer function variable (e.g. 's' or 'z') 
TF, ZPK 
Z 
Zeros 
ZPK 
P 
Poles 
ZPK 
K 
Gains 
ZPK 
A 
Matrix A 
SS 
B 
Matrix B 
SS 
C 
Matrix C 
SS 
D 
Matrix D 
SS 
To see the values of the properties of a model, we use "get". Let us as an example look at the properties of the MIMOtransfer function H defined earlier:
get(H) 
MATLAB's response is
num = {1x2 cell}
den = {1x2 cell}
Variable = 's'
Ts = 0
Td = [1 2]
InputName = {2x1 cell}
OutputName = {''}
 Notes = {}
UserData = []
We can access specific LTIproperties. Let us as an example assign the value of the property Td of H to the variable Tdvec:
Tdvec=get(H,'Td') 
MATLAB's response is
Tdvec =
1 2
To set certain LTIproperties, we use "set". Let us as an example
set the property InputName of H to {'Voltage';'Flow'}, which is a cell
array:
set(H,'InputName',{'Voltage';'Flow'}) 
These input names are now used when displaying information about H:
H 
MATLAB's response is
Transfer function from input "Voltage" to output:2 s

4 s + 1Transfer function from input "Flow" to output:
3

5 s + 1Input delays (listed by channel): 1 2
2.4
Conversion between transfer functions and statespace models
From statespace model to transfer function
The function "tf" converts statespace models to a corresponding transfer function according to the formula(s)
H(s) = C(sIA)^{1}B + D (continuoustime case)
Hd(z) = Cd(zIAd)^{1}Bd + Dd (discretetime case)
In the following example a continuoustime statespace model is converted to a corresponding (continuoustime) transfer function:
A=1; B=2; C=3; D=4;

MATLAB's response is
Transfer function:4 s + 10

s + 1
And in the following example a discretetime statespace model is converted to a corresponding (discretetime) transfer function (the samplingtime is 0.1):
Ad=0.5; Bd=0.2; Cd=0.3; Dd=0.4;
Ts=0.1; 
MATLAB's response is
Transfer function:
0.4 z  0.14

z  0.5Sampling time: 0.1
From transfer function to statespace model
"ss" converts a transfer function to a statespace model. But this convertion is not unique, since there are an infinite number of statespace models which have the same transfer functions. Hence, "ss" chooses one such realization, called the controllercanonical form.
2.5 Conversion between continuoustime
and discretetime models
From discretetime to continuoustime
sysdis=c2d(syscont,Ts,method)
As an example, let us discretize a continuoustime model (transfer function) which contains a timedelay, assuming zero order hold:
K=2; T=4; num=[K,0]; den=[T,1]; Tdelay=1; 
MATLAB's response is
Transfer function:0.5 z  0.5

z^6  0.9512 z^5Sampling time: 0.2
(The high order of the denominator is due to the timedelay of the continuoustime system.)
From discretetime models to continuoustime models
Use the function "d2c".
2.6 Combining models (in
series, parallel, and feedback)
A model can be thought of as a block with inputs and outputs and containing a transfer function or a statespace model inside it. The functions "series", "parallel", and "feedback" can be used to perform basic blockdiagram manipulation, as demonstrated in the following. These functions apply to continuoustime models as well as discretetime systems.
Ha(s) = 1/(s+2)
Hb(s) = 3/(s+4)
First, let us create the above two systems:
k1=1; k2=2; k3=3; k4=4; 
Hser=series(Ha,Hb) 
MATLAB's response is
Transfer function: 3

s^2 + 6 s + 8
Below, Ha(s) and Hb(s) are connected in parallel, which means that Hpar(s)=Ha(s)+Hb(s).

MATLAB's response is
 Transfer function:
 4 s + 10
 
 s^2 + 6 s + 8
Finally, Ha(s) and Hb(s) are connected in a negative feedback loop with Ha(s) being in the forward path and Hb(s) being in the negative feedback path:
feedbsign=1;

Above, feedbsign is the sign of the feedback, and we set it to either 1 or 1. The transfer function Hfeedb(s) is given by
Hfeedb(s)=Ha(s)/[1+feedbsign*Ha(s)*Hb(s)]
MATLAB's response to the expressions above is
 Transfer function:
 s + 4
 
 s^2 + 6 s + 11
As a starting point for this chapter, let us define a continuoustime transfer function, H1c(s), and a discretetime transfer function, H1d(z) which will be the discretized version of H1c(s). We take H1c(s) as
H1c(s) = (s+0.5)/(s^2+2s+4)
and we create H1c(s) with
n1=[1,0.5]; d1=[1,2,4];

MATLAB's response is
Transfer function:s + 0.5

s^2 + 2 s + 4
Then, let H1d(z) be the zeroorder hold discretized version of H1c(s):
Ts=0.2;

MATLAB's response is
Transfer function:0.1692 z  0.1529

z^2  1.54 z + 0.6703
Sampling time: 0.2
3.1 Simulation (time response)
We can simulate the step response of one or several LTImodels with "step". The input step is then a unit step (the step height is equal to one). Let us simulate both H1c and H1d from t=0 to 10 time units:
Tf=10; step(H1c,H1d,Tf) 
The resulting plot is not shown here in this text.
We can store the simulated time response, y, and the time vector, t, by using return (left) arguments:
Tf=10; [y,t] = step(H1c,H1d,Tf); 
In this case, no plot is shown on the screen.
"impulse" simulates the impulse response:
Tf=10; impulse(H1c,Tf) 
The resulting plot is not shown here in this text.
"initial" simulates the response from the initial state of an LTImodel.
"lsim" is a more general simulation function as it accepts any input signal, not just step or impulse. To generate the input signal, we may use "gensig", which produces a sine wave, or a square wave, or periodic pulses. Let us as an example simulate H1c with a sinusoidal input, u, having period Tp=0.5, final time Tf=10, and time step Tstep=0.01:
Tp=0.5; Tf=10; Tstep=0.01;
[u,t]=gensig('sin',Tp,Tf,Tstep); 
The resulting plot is not shown here in this text.
Above, "gensig" was used to generate the input signal. Other signal generators are "square", "sawtooth", and "stepfun".
3.2 Poles, eigenvalues, and zeros
We can calculate the poles of an LTImodel with "pole", as in
p=pole(H1c) 
MATLAB's response is
p =
1.0000 + 1.7321i
1.0000  1.7321i
For a statespace model we can analogously calculate the eigenvalues with "eig".
"tzero" calulates zeros (transmission zeros for MIMOmodels). Here is an example based on H1c(s):
z=tzero(H1c) 
MATLAB's response is
z =
0.5000
With "[pol,zer]=pzmap" we can calculate and plot both the poles and the
zeros. Omitting the returnparameters just plots the poles and the zeros in the
complex plane:
pzmap(H1c) 
The resulting plot is not shown here in this text.
Poles and eigenvalues will always be real numbers and/or complex conjugate numbers. "damp" calculates the relative damping, z , and the natural (or udamped) resonance frequency, w _{0} for such complex poles/eigenvalues. It is assumed that the poles or eigenvalues are given as the roots of (the characteristic equation)
s^{2 }+ 2z w _{0}s + w _{0}^{2}
Here is one example:
damp(H1c) 
MATLAB's response is
Eigenvalue Damping Freq. (rad/s)
1.00e+000 + 1.73e+000i 5.00e001 2.00e+000
1.00e+000  1.73e+000i 5.00e001 2.00e+000
The frequency response of an LTImodel can be calculated with "bode". Here, "bode" shows the Bodeplots of both H1c and H1d, in the same diagram:
bode(H1c,H1d) 
The resulting plot is not shown here in this text. Using the syntax
[mag,phase,w] = bode(sys)
the magnitude and the phase (in degrees), and the frequency vector (in rad/s) used by "bode", are returned. With "bode(sys,w)" the Bodeplot will be drawn using our own frequency vector, w.
The frequency response can be drawn in a Nicholsdiagram with "nichols", and in a Nyquistdiagram with "nyquist" (examples follows in the next section).
3.4 Stability analysis based on frequency response
The function "margin" calculates the stability margins and the crossover frequencies for a feedback system (continuoustime or discretetime). In the following example "margin" draws a Bodeplot and writes the stability margins and the crossover frequencies in the diagram. The loop transfer function of the feedback system is
Hloop(s)=(K/s)*e^{Tdel*s}
where K=0.19, and Tdel=4.17 (timedelay). Let us first create the LTIobject Hloop:
K=0.19; Tdel=4.17;

Then we execute
margin(Hloop) 
The resulting Bodeplot is not shown in this text. We will see that the gain
margin is 5.9 dB, and the phase margin is 44.3 degrees. The amplitude crossover
frequency, which is the bandwidth of the loop, is 0.2 rad/sec (or 0.2 rad per
time unit), and the phase crossover frequency is 0.4 rad/s. In general, these
values are returned by "margin" if it is invoked with return arguments, using
this syntax: "[Gm,Pm,Wcg,Wcp] = margin(Hloop)". However, on my installation,
trying to execute this expression produced the error message "Cannot handle
input delays.", which is strange since "margin(Hloop)" worked all right. But we
will not give in, and will return to this problem after we have approximated the
timedelay part of the (loop) transfer function with a Padeapproximation.
Stability analysis can also be performed using a Nyquistplot or a
Nicholsplot. Let us try Nichols:
nichols(Hc1),ngrid 
Above, ngrid adds a Nichols grid to the plot. The resulting Nicholsplot
is not shown in this text. However, you will see that the interesting details
around the critical point (gain = 1 = 0dB, and phase =  180 degrees) do not
appear clearly. Try "zoom" to see the details!
3.5
Padeapproximation
Padeapproximations are rational transfer functions which approximates the transfer function of a timedelay. Padeapproximations can be calculated with "pade". Let us as an example develop a 5'th order approximation to a timedelay of 2 seconds (or timeunits), and represent it as an LTImodel (or object):
Tdelay=2; N=5; 
MATLAB's response is
Transfer function:
s^5 + 15 s^4  105 s^3 + 420 s^2  945 s + 945

s^5 + 15 s^4 + 105 s^3 + 420 s^2 + 945 s + 945
Now, let us (for fun) compare the step response of tfpade with the ideal step response of the timedelay (of 2 sec.). To generate a timedelayed step, we will use "stepfun".
tfinal=5; [ypade,time]=step(tfpade,tfinal); 
The plot will not be shown in this text, but it illustrates the approximation effectively.
In Sec. 3.4 we saw that "margin" did not accept a model containing a timedelay. So let us in stead use a Padeapproximation for the timedelay of the transfer function Hloop(s). "pade" is now used a little different than above:
K=.19; td=4.17; Hloop=tf(K,[1,0],'Td',td) %Just to repeat
the creation of Hloop. 
So, Hlooppade is the Padeapproximation of the entire original transfer function Hloop, and not of just the timedelay. Finally, let us try "margin" one more:
[Gm,Pm,Wcg,Wcp] = margin(Hlooppade) 
MATLAB's response is
Gm =
1.9826
Pm =
44.6046
Wcg =
0.3767
Wcp =
0.1900
which in fact is very close to the correct values shown in the Bodeplot produced by "margin" in Sec. 3.4. (Note that Gm = 1.9826 is equal to 5.94 dB).
LTIviewer makes it easy to perform simulations, frequency response plots etc. for one or several of the LTImodels which exist in the working directory. The LTIviewer is easy to use. Just execute
Ltiview 
and try it.
Given a closedloop system with negative feedback and loop transfer function k*L0(s), where k is a constant. [k*L0(s) is then the product of the individual transfer functions in the loop.] The function "rlocus" calculates the poles of the closedloop system as a function of k. These poles are the root locus of the closedloop system. The poles are the roots of the characteristic equation 1+k*L0(s). Here is one example: First, let us create the transfer function L0(s):

MATLAB's response is
Transfer function:
1

s^3 + 2 s^2 + s
Now, to plot the poles of the closedloop system which have the loop transfer function of k*L0(s), we execute:
L0=tf(1,[1 2 1 0]) rlocus(L0),sgrid 
The resulting figure showing the root locus is not shown here in this text. Note that "sgrid" plots a grid of z and w _{0}curves. ("zgrid" does the same in the discretetime case.) MATLAB chooses automatically the proper range of k for which the root locus is drawn. However, we can use our own values of k by executing "rlocus(L0,k0)". Of coourse, we must have created k0 (a vector) in advance.
Once the root locus is drawn (using "rlocus"), we can choose a pole location
in the root locus plot, and ask MATLAB to calculate the corresponding value of
k. This is done with "rlocfind". As an example, let us find (the approximate)
value of k which causes one of the closedloop poles to be placed on the
imaginary axis (the system is then on the stability limit). (It can be shown
that k0=2 produces closedloop poles at 2, ± i.). We execute:
[k0,pole0]=rlocfind(L0) 
"rlocfind" puts a crosshair cursor on the root locus plot. Let us, with the cursor, select the pole at +i (on the imaginary axis). As a result, MATLAB returns the both the selected point and the corresponding value of k:
selected_point =
0.0023 + 0.9912i
k0 =
1.9606
pole0 =
1.9921
0.0040 + 0.9921i
0.0040  0.9921i
In fact, our selected point (0.0023 + 0.9912i) is not exactly on the root locus, but MATLAB finds the value of k0 corresponding to the nearest point, and calculates the corresponding poles (pole0).
Suppose the system to be controlled has the (continuoustime) statespace model dx/dt=Ax+Bu. The system is to be controlled by statefeedback: u=Gx where G is a matrix of gains. Then the closedloop system has the statespace model dx/dt=Ax+B(Gx)=(ABG)x. The function "place" calculates G so that the eigenvalues of (ABG) (the closedloop system) are as specified. Here is one simple example: Assume the system to be controlled is given by dx/dt=u (which is an integrator, from u to x). The closedloop eigenvalue shall be E=4:
E=4; A=0;B=1; g1=place(A,B,E) 
MATLAB's response is
place: ndigits= 15
Warning: Pole locations are more than 10% in error.
g1 =
4
(The answer g1=4 is correct despite the warning message.)
"place" works similarly for discretetime systems: Suppose the system to be controlled has the model
x(k+1)=A_{d}x(k)+B_{d}u(k)
and the controller is
u(k)=G_{d}x(k)
Then, the closedloop system has the statespace model
x(k+1)=(A_{d}B_{d}G_{d})x(k)
"place" calculates G_{d} so that the eigenvalues of (A_{d}B_{d}G_{d}) (the closedloop system) are as specified in the vector E_{d}. Thus, we can execute "Gd=place(Ad,Bd,Ed)".
"place" can be used to calculate stateestimator gains, too: Suppose given a system with statespace model
dx/dt=Ax+Bu, y=Cx+Du, y=Cx+Du
and that the states x are to be estimated by the estimator
dx_{e}/dt=Ax_{e}+Bu+Ke, y_{e}=Cx_{e}+Du
where the residual e is given by e=yy_{e}. It can be shown that the state estimation error z is given by dz/dt=(AKC)z. The eigenvalues of this error model are given by E=eig(AKC) º eig(A'C'K'). (Here, A' means the transpose of A.) Thus, we can calculate the estimatorgain by executing "K1=place(A',C',Ee); K=K1' ".
The function "dlqr" performs linearquadratic regulator design for discretetime systems. This means that the controller gain G in the feedback
u(k)=Gx(k)
for the controlled system
x(k+1)=A_{d}x(k)+B_{d}u(k)
is calculated so that the cost function
J = Sum {x'Qx + u'Ru + 2*x'Nu}
is minimized. The syntax is
[K,S,E] = dlqr(A_{d},B_{d},Q,R,N)
The matrix N is set to zero if omitted. Above, S is the solution of the Riccati equation, E contains the closedloop eigenvalues which are the eigenvalues of (A_{d}B_{d}G). Here is one example:
Ad=0.85;Bd=0.15; Q=1;R=0.2; [G,S,E]=dlqry(Ad,Bd,Q,R) 
MATLAB's response is
G =
1.1797
S =
2.3370
E =
0.6731
"lqr" works analogously for continuoustime systems. "dlqry" minimizes the cost function J = Sum {y'Qy + u'Ru}in which only the output vector y, and not the whole statevector x, is weighted. "dlqy" works analogously for continuoustime systems.
4.4 Kalman estimator (or filter)
"kalman" designs both continuoustime and discrete.time Kalmanfilters. The discretetime Kalmanfilter is more commonly used. In this case, it is assumed that the system is given by a discretetime statespace model in the form of an LTIobject. The model is
x(k+1) = Ax(k) + Bu(k) + Gw(k)
y(k) = Cx(k) + Du(k) + Hw(k) + v(k)
where w is the process noise, and v is the measurement noise. Note that the LTIobject must be created by the expression
sys=ss(A,[B,G],C,[D,H])
Q, R, and N are the whitenoise covariances as follows:
E{ww'} = Q, E{vv'} = R, E{wv'} = N
(In the calling syntax, N may be omitted if it is zero.) The Kalmanestimator is
x(k+1k) = Ax(kk1) + Bu(k) + L[y(k)  y(kk)] (apriori estimate)
x(kk) = x(kk1) + M[y(k)  y(kk)] (aposteriori estimate)
where
y(kk) = Cx(kk) + Du(k)
The syntax of "kalman" is
[Kest,L,P,M,Z] = kalman(sys,Q,R,N)
Here, Kest is the Kalman estimator in the form of an LTIobject having [u;yv] as inputs (yv is the measurements), and [yest,xest] as outputs. L is the steadystate filter gain. (In many cases, we do not need Kest and L.) M is the steadystate innovation gain, and P, and Z are the steadystate error covariances:
P = E{[x  x(kk1)][x  x(kk1)]'} (Covariance of apriori estimate error)
Z = E{[x  x(kk)][x  x(kk)]'} (Covariance of aposteriori estimate error)
Here is one example:
A=0.85;B=0.15;C=1;D=1;Ts=0.1; G=1;H=0; s1=ss(A,[B,G],C,[D,H],Ts); Q=1; R=0.2; [Kest,L,P,M,Z] = kalman(s1,Q,R) 
MATLAB's response is
a =
x1_e
x1_e 0.12853
b =
u1 u2
x1_e 0.57147 0.72147
c =
x1_e
y1_e 0.15121
x1_e 0.15121
d =
u1 u2
y1_e 0.15121 0.84879
x1_e 0.84879 0.84879
Sampling time: 0.1
Discretetime system.
L =
0.7215
P =
1.1226
M =
0.8488
Z =
0.1698
Version 4.0.1 07Mar1997
Creation of LTI models.
ss  Create a statespace model.
zpk  Create a
zero/pole/gain model.
tf  Create a transfer function model.
dss  Specify
a descriptor statespace model.
filt  Specify a digital filter.
set 
Set/modify properties of LTI models.
ltiprops  Detailed help for available
LTI properties.
Data extraction.
ssdata  Extract statespace matrices.
zpkdata 
Extract zero/pole/gain data.
tfdata  Extract numerator(s) and
denominator(s).
dssdata  Descriptor version of SSDATA.
get  Access
values of LTI model properties.
Model characteristics.
class  Model type ('ss', 'zpk', or 'tf').
size
 Input/output dimensions.
isempty  True for empty LTI models.
isct 
True for continuoustime models.
isdt  True for discretetime
models.
isproper  True for proper LTI models.
issiso  True for
singleinput/singleoutput systems.
isa  Test if LTI model is of given
type.
Conversions.
ss  Conversion to state space.
zpk  Conversion to
zero/pole/gain.
tf  Conversion to transfer function.
c2d  Continuous to
discrete conversion.
d2c  Discrete to continuous conversion.
d2d 
Resample discrete system or add input delay(s).
Overloaded arithmetic operations.
+ and   Add and subtract LTI systems
(parallel connection).
*  Multiplication of LTI systems (series
connection).
\  Left divide  sys1\sys2 means inv(sys1)*sys2.
/  Right
divide  sys1/sys2 means sys1*inv(sys2).
'  Pertransposition.
.' 
Transposition of input/output map.
[..]  Horizontal/vertical concatenation
of LTI systems.
inv  Inverse of an LTI system.
Model
dynamics.
pole, eig  System poles.
tzero  System transmission
zeros.
pzmap  Polezero map.
dcgain  D.C. (low frequency) gain.
norm
 Norms of LTI systems.
covar  Covariance of response to white
noise.
damp  Natural frequency and damping of system poles.
esort  Sort
continuous poles by real part.
dsort  Sort discrete poles by
magnitude.
pade  Pade approximation of time delays.
Statespace models.
rss,drss  Random stable statespace models.
ss2ss
 State coordinate transformation.
canon  Statespace canonical
forms.
ctrb, obsv  Controllability and observability matrices.
gram 
Controllability and observability gramians.
ssbal  Diagonal balancing of
statespace realizations.
balreal  Gramianbased input/output
balancing.
modred  Model state reduction.
minreal  Minimal realization
and pole/zero cancellation.
augstate  Augment output by appending
states.
Time response.
step  Step response.
impulse  Impulse
response.
initial  Response of statespace system with given initial
state.
lsim  Response to arbitrary inputs.
ltiview  Response analysis
GUI.
gensig  Generate input signal for LSIM.
stepfun  Generate unitstep
input.
Frequency response.
bode  Bode plot of the frequency
response.
sigma  Singular value frequency plot.
nyquist  Nyquist
plot.
nichols  Nichols chart.
ltiview  Response analysis GUI.
evalfr
 Evaluate frequency response at given frequency.
freqresp  Frequency
response over a frequency grid.
margin  Gain and phase margins.
System interconnections.
append  Group LTI systems by appending inputs
and outputs.
parallel  Generalized parallel connection (see also overloaded
+).
series  Generalized series connection (see also overloaded
*).
feedback  Feedback connection of two systems.
star  Redheffer star
product (LFT interconnections).
connect  Derive statespace model from block
diagram description.
Classical design tools.
rlocus  Evans root locus.
rlocfind 
Interactive root locus gain determination.
acker  SISO pole
placement.
place  MIMO pole placement.
estim  Form estimator given
estimator gain.
reg  Form regulator given statefeedback and estimator
gains.
LQG design tools.
lqr,dlqr  Linearquadratic (LQ) statefeedback
regulator.
lqry  LQ regulator with output weighting.
lqrd  Discrete LQ
regulator for continuous plant.
kalman  Kalman estimator.
kalmd 
Discrete Kalman estimator for continuous plant.
lqgreg  Form LQG regulator
given LQ gain and Kalman estimator.
Matrix equation solvers.
lyap  Solve continuous Lyapunov
equations.
dlyap  Solve discrete Lyapunov equations.
care  Solve
continuous algebraic Riccati equations.
dare  Solve discrete algebraic
Riccati equations.
Demonstrations.
ctrldemo  Introduction to the Control System
Toolbox.
jetdemo  Classical design of jet transport yaw damper.
diskdemo
 Digital design of harddiskdrive controller.
milldemo  SISO and MIMO LQG
control of steel rolling mill.
kalmdemo  Kalman filter design and
simulation.