Escolar Documentos
Profissional Documentos
Cultura Documentos
Anthony Rossiter
ACS108 (and ACS211)
Department of Automatic
Control and Systems
Engineering
Overview
1.Representation of Laplace transforms
2.Inverse Laplace
3.Block diagrams
4.Time responses
Consider
s 2 + 3s + 2
G= 3
s + 9 s 2 + 27 s + 27
Numerator coefficients
are
[1 3 2]
Denominator
coefficients are
[1 9 27 27]
these coefficients.
The final result is clear
TASK
Use MATLAB to define the following
transfer functions.
Answers are on the next slide.
3s + 2 3
G= 3 H= 2
s + 12 s + 48s + 64
2
s +4
s+5 2( s + 1)
K = 3 M= 2
s+6 s + 4s
Answers
G=tf([3,2],[1,12,48,64])
H=tf(3,[1, 0,4])
S e e w e e k6 _la p la ce . m
K=3*tf([1 5],[1 6])
A lso h a s o th e r exa m p le s to lo o k a
M=tf([2 2],[1 4 0])
•
Note it sometimes better to use
numerator
coefficients out of a
transfer function?
Use tfdata.m as
shown here. [The ‘v’
is important]
Two output
coefficients and
want the roots, use
TASK
1. What does the following command
do?
H=tf(poly(-2),poly([0,-3 -5]))
−1
• impulse response L [G ( s )]
• step response −1 G ( s )
L [ ]
The latter is more
s
common in control
scenarios.
Laplace 1.8
1.6
1.4
1.2
Amplitude
1
0.8
0.6
0.4
0.2
0
0 0.5 1 1.5
Impulse
TimeResponse
(sec)
0.5
0.45
0.4
0.35
0.3
Amplitude
0.25
0.2
0.15
0.1
0.05
0
0 1 2 3 4 5 6 7
Time (sec)
Extracting the
numerical
answers
If you want the
computed. 1.6
1.4
1.2
Laplace computed.
0.4
0.2
0
0 0.5 1 1.5
What about step responses
Same syntax as impulse.m
Just write step instead, e.g.
[y,t]=step(G,tfinal)
TASKS
1.Compute and plot the impulse and step
responses for all the transfer
functions given earlier.
2.Validate your answers by doing some
computations on pen and paper.
3.Take some examples from the ACS114
notes/lectures and form the
impulse/step responses with
MATLAB.
4.Look at week6_laplace.m,
week6_laplace1.m,
week6_laplace2.m
Non-simple input sequences
1.In some cases the input is neither an
impulse or a step but some more
complicated shape.
2.To simulate the response of a transfer
function in this case use lsim.m
3.This function needs enough information
to define the input precisely, that is
pairs of values (input magnitude,
time).
4.It will interpolate between the values
given, so ensure the time gaps are
small to minimise any errors from
Illustratio
n of
lsim.m
1. Define input
values.
2. Define
corresponding
times.
3. Give three
0.8
0.7
arguments, 0.6
and times.
Input values
0.4
4. Plotting: 0.3
circles and 0
0 0.5 1 1.5 2 2.5 3 3.5 4
Block diagrams
How do I form the closed-
add a compensator ?
GK
y=
Set point to output.
r =G c r
1 + GK
Set point to input.
K
u = r = Gcu r
1 + GK
is K, feedback path is
G.
TASK
Use MATLAB for find the closed-loop
transfer functions (setpoint to error,
input and output) for the following
arrangements.
Use pen and paper to validate your
programming.
3 2 2
G = ; K = 1 G = ; K=
s+4 ( s + 1)( s + 2) s
2 2 s + 0.1
G = ; K = 1 G = ; K=
( s + 1)( s + 2) s ( s + 2)( s + 3) s + 0. 04
Extra task
m
0.6
Open-loop
Amplitude
0.4
0.2
-0.2
TASK
2
Amplitude
1
compare_open_closed( 0
-0.2 0 0.2 0.4 0.6 0.8 1 1.2
Engineering Resources project of the HE Academy Engineering Subject Centre. The Open Engineering Resources project
was funded by HEFCE and part of the JISC/HE Academy UKOER programme.
The JISC logo is licensed under the terms of the Creative Commons Attribution-Non-Commercial-No Derivative Works 2.0 UK: England & Wales Licence.
All reproductions must comply with the terms of that licence.
The HEA logo is owned by the Higher Education Academy Limited may be freely distributed and copied for educational purposes only, provided that
appropriate acknowledgement is given to the Higher Education Academy as the copyright holder and original publisher.
The name and logo of University of Sheffield is a trade mark and all rights in it are reserved. The name and logo should not be reproduced without the
Where Matlab® screenshots are included, they appear courtesy of The MathWorks , Inc.