Control Systems-Lab Manual 06
Control Systems-Lab Manual 06
vii.
We will also learn how to make preliminary analysis of such systems using plots of
poles and zeros locations as well as time response due to impulse, step and arbitrary inputs.
Examples of Creating LTI Models
Building LTI models with Control System Toolbox is straightforward. The following
sections show simple examples. Note that all LTI models, i.e. TF, ZPK and SS are also
MATLAB objects.
Example of Creating Transfer Function Models
You can create transfer function (TF) models by specifying numerator and
denominator coefficients. For example,
>>num = [1 0];
>>den = [1 2 1];
>>sys = tf(num,den)
Transfer function:
s
------------s^2 + 2 s + 1
A useful trick is to create the Laplace variable, s. That way, you can specify
polynomials using s as the polynomial variable.
>>s=tf('s');
>>sys= s/(s^2 + 2*s +
1) Transfer function:
s
------------s^2 + 2 s +
This is identical to the previous transfer function.
19
20
LAB TASKS
Simulation to Arbitrary Inputs:
To simulates the (time) response of continuous or discrete linear systems to arbitrary inputs
use lsim. When invoked without left-hand arguments, lsim plots the response on the
screen. lsim(sys,u,t) produces a plot of the time response of the LTI model sys to the input
time history t,u. The vector t specifies the time samples for the simulation and
consists of regularly spaced time samples. Simulate and plot the response of the system
21
to a square wave with period of four seconds. First generate the square wave with gensig.
Sample every 0.1 second during 10 seconds, then simulate with lsim.
LAB TASK
4
using zpk command.
Exercise 4: Determine
the transfer function using zpk command.
22