cs6501: basics z-transforms and transfer functions (tools for analyzing the dynamics of systems)...
TRANSCRIPT
CS6501: Basics
Z-Transforms and Transfer Functions
(Tools for analyzing the dynamics of systems)
Spring 2015
CS6501: Basics
Outline
• Signals and Systems• Z-Transforms
– What are Z-Transforms– What are inverse Z-Transforms– How to infer properties of a signal from
its Z-transform
• Transfer Functions– What are Transfer Functions– How to infer properties of a system from
its Transfer Function
CS6501: Basics
Important
• Z-transforms and transfer functions enable you to analyze signals and systems (general techniques)
– With or without a controller!!!
CS6501: Basics
Signals
• The signals we are studying – Discrete Signals– A discrete signal takes value at each
non-negative time instance
0 2 4 6 8 10 120
2
4
6
8
10
12
14
16
18
CS6501: Basics
Example of a System
0 2 4 6 8 10 120
2
4
6
8
10
12
14
16
18
0 2 4 6 8 10 120
2
4
6
8
10
12
14
16
18
raw readings from a noisy temperature sensor- Input Signal
smooth temperature values after filtering- Output Signal
Filter
33)u(k2)u(k1)u(k
y(k)
A (SISO) system takes an input signal, manipulates it and gives a corresponding output signal.
CS6501: Basics
Control System
Controller TargetSystem
Transducer
ReferenceInput
Controlerror
ControlInput
MeasuredOutput
TransducerOutput
CS6501: Basics
Common Signals
-1 0 1 2 3 4 5 6 7 8 90
0.5
1
-1 0 1 2 3 4 5 6 7 8 90
0.5
1
-1 0 1 2 3 4 5 6 7 8 90
0.5
1
-1 0 1 2 3 40
1
2
3
4
0 5 10 150
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
-1 0 1 2 3 4 5 6 7 8 90
1
2
3
4
5
6
a=1.2
0 2 4 6 8 10 12 14 16 18-1
-0.5
0
0.5
1
sin(k*pi/6)
0 2 4 6 8 10 12 14 16 18-1
-0.5
0
0.5
1
cos(k*pi/6)
0 2 4 6 8 10 12 14 16 18-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
u(k)=c os(k*pi/6)*0.9k
impulse
delayed impulse
step
ramp
exponential
|a|<1|a|>1
sine
cosine
exponentiallymodulatedcosine/sine
(ak)
CS6501: Basics
Other Signals – (arbitrary)
• From a temperature sensor• From an acoustic sensor
CS6501: Basics
Z-Transform of a Signal
u(k)Z-1
u(0)
u(1)
u(2)
u(3)
u(4)
…
0k
kzu(k)U(z)
U(z)Z
u(0) · z0
+u(1) · z-1
+u(2) · z-2
+u(3) · z-3
+u(4) · z-4
…
CS6501: Basics
Z-Transform – Cont’d
• Mapping from a discrete signal to a function of z– Many Z-Transforms have this form:
• Helps intuitively derive the signal properties– Does it converge?– To which value does it converge? – How fast does it converges to the value?
m
0j
jj
n
0i
ii
zb
zaU(z)
Rational Function of z
CS6501: Basics
Z Transform of Unit Impulse Signaluimpulse(k) Uimpulse(z)Z
Z-1
u(0) = 1
u(1) = 0
u(2) = 0
u(3) = 0
u(4) = 0
…
1 · z0
+0 · z-1
+0 · z-2
+0 · z-3
+0 · z-4
…
-1 0 1 2 3 4 5 6 7 8 90
0.5
1
1(z)Uimpulse
CS6501: Basics
Delayed Unit Impulse Signal
udelay(k) Udelay(z)ZZ-1
u(0) = 0
u(1) = 1
u(2) = 0
u(3) = 0
u(4) = 0
…
0 · z0
+1 · z-1
+0 · z-2
+0 · z-3
+0 · z-4
…
1delay z(z)U
-1 0 1 2 3 4 5 6 7 8 90
0.5
1
CS6501: Basics
Z-Transform of Unit Step Signalustep(k) Ustep(z)Z
Z-1
u(0) = 1
u(1) = 1
u(2) = 1
u(3) = 1
u(4) = 1
…
1 · z0
+1 · z-1
+1 · z-2
+1 · z-3
+1 · z-4
…
...zzz1(z)U 321step
-1 0 1 2 3 4 5 6 7 8 90
0.5
1
CS6501: Basics
Unit Step Signal - continued
,n 1,|a|
a1
a1
a1
)a...aaa)(1(1a...aa1
1n
n2n2
A little bit of math …
assuming
a1
1a1
a1lim
a1
)a...aaa)(1(1lim...aa1
1n
n22
n
n
1-321
step z-11
...zzz1(z)U
CS6501: Basics
Z-Transform of Exponential Signaluexp(k) Uexp(z)Z
Z-1
u(0) = 1
u(1) = a
u(2) = a2
u(3) = a3
u(4) = a4
…
1 · z0
+a · z-1
+a2 · z-2
+a3 · z-3
+a4 · z-4
…
1-
33221exp
az-11
...zazaaz1(z)U
-1 0 1 2 3 4 5 6 7 8 90
1
2
3
4
5
6
a=1.2
Remember this!
CS6501: Basics
What about an arbitrary signal?
• Apply z-transform to any signal
• Just use the z-transform formula
• May not have a convenient formula that summarizes the signal
CS6501: Basics
LTI Systems
• Linear, Time Invariant (LTI) System– Many systems we analyze or design are
or can be approximated by LTI systems– We have a well-established theory for
LTI system analysis and design
• Example - A simple moving average– y(k)=[u(k-1)+u(k-2)+u(k-3)]/3
3-MAu(k) y(k)
CS6501: Basics
What does “Linear” mean exactly?• Scaling
• Superposition
3-MAu(k) y(k)
3-MAλu(k) λy(k)
3-MAu1(k) y1(k)
3-MAu2(k) y2(k)
3-MAu1(k)+u2(k) y1(k)+y2(k)
CS6501: Basics
Time Invariance
3-MAu(k) y(k)
3-MAu’(k)=u(k-n) y’(k)=y(k-n)
Idiom:u(k-n) is u(k) delayed by n time units!
CS6501: Basics
Reality Check
• Typically speaking, are computing systems linear? Why/why not?– Consider saturation …– Assume RT for one job alone in system is X
• Is RT for 3 jobs 3X?
• Typically speaking, are computing systems time-invariant? Why/why not?– Resource allocations are in different states at
different times
CS6501: Basics
Unit Impulse Response
3-MAuimpulse(k) yimpulse(k)
-1 0 1 2 3 4 5 6 7 8 9 100
0.5
1
Claim: If we know yimpulse(k), we can obtain y(k) corresponing to ANY input u(k)!
yimpulse(k) contains ALL information about the input-output relationship of an LTI system.
-1 0 1 2 3 4 5 6 70
0.5
1
33)u(k2)u(k1)u(k
y(k)
Key Points
• Impulse Response – input impluse - basis of convolution (time domain)
• Frequency Response – input sine wave – basis of DFT
CS6501: Basics
CS6501: Basics
An Example: 3-MA
-1 0 1 2 3 4 5 6 70
0.5
1
3MAuimpulse(k) yimpulse(k)
-1 0 1 2 3 4 5 6 70
0.5
1
3MAu (k) y (k) ?
-1 0 1 2 3 4 5 6 70
0.5
1
-1 0 1 2 3 4 5 6 70
0.5
1
-1 0 1 2 3 4 5 6 70
0.5
1
6 x
-1 0 1 2 3 4 5 6 70
1
2
3
4
5
6
7
8
9
9 x
3 x
u(k) =
+
+
+…
uimpulse(k)
uimpulse(k-1)
uimpulse(k-2)
Input: Scaled and delayed
CS6501: Basics
-1 0 1 2 3 4 5 6 70
0.5
1
-1 0 1 2 3 4 5 6 70
0.5
1
An Example: 3-MA
-1 0 1 2 3 4 5 6 70
0.5
1
3MAuimpulse(k) yimpulse(k)
-1 0 1 2 3 4 5 6 70
0.5
1
3MAu (k) y (k) ?
6 x
9 x
3 x
+
+
+…
yimpulse(k-1)
yimpulse(k-2)
-1 0 1 2 3 4 5 6 70
1
2
3
4
5
6
7
8
9
y(k) =
-1 0 1 2 3 4 5 6 70
0.5
1 yimpulse(k)
CS6501: Basics
Convolution
• y(5)= u(0) · yimpulse(k)
+ u(1) · yimpulse(k-1)
+ u(2) · yimpulse(k-2)
+ u(3) · yimpulse(k-3)
+ u(4) · yimpulse(k-4)
-1 0 1 2 3 4 5 6 70
0.5
1
-1 0 1 2 3 4 5 6 70
0.5
1
u(0) x
u(1) x
u(2) x
+
+
+…
yimpulse(k-1)
yimpulse(k-2)
-1 0 1 2 3 4 5 6 70
1
2
3
4
5
6
7
8
9
y(k) =
-1 0 1 2 3 4 5 6 70
0.5
1 yimpulse(k)
(k)yu(k)
i)](ky[u(i)y(k)
impulse
1k
0iimpulse
*
CS6501: Basics
Important Theorem
u(k) *(convolution)
v(k) = y(k)
U(z) V(z) Y(z)=·(multiplication)
Z Z-1 Z Z-1 Z Z-1
Time Domain
Z Domain
CS6501: Basics
Z-Transform/Inverse Z-Transform
LTI: yimpuse(k)=0.3k-1u (k)=0.7k y (k)?
0 5 10 150
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
*(convolution)
10.7z11
Z
=
·(multiplication)
= )0.7z)(10.3z(1z
11
1
0 5 10 150
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
Z-1
1
-1
0.3z1z
Z Transfer Function
0 2 4 6 8 10 12 14 16 180
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
CS6501: Basics
Delay the Unit Step Signal
-1 0 1 2 3 40
0.5
1
ustep (k) udelayed(k) udstep(k)*(convolution)
=
y(k)=u(k-1)
1z11
Z Transfer Function
·(multiplication)
Zz-1 =
-1 0 1 2 3 4 5 6 7 8 90
0.5
1
-1 0 1 2 3 4 5 6 7 8 90
0.5
1
1
-1
z1z
Z
LTI: yimpuse(k)=udelayed(k)
u (k) y (k)
CS6501: Basics
Delayed Unit Step Signal – Cont’d
udstep(k) Udstep(z)ZZ-1
u(0) = 0
u(1) = 1
u(2) = 1
u(3) = 1
u(4) = 1
…
0 · z0
+1 · z-1
+1 · z-2
+1 · z-3
+1 · z-4
…
1z1
z-1z
...zzz(z)U
1-
1-
321dstep
-1 0 1 2 3 4 5 6 7 8 90
0.5
1
Remember this!
CS6501: Basics
Signals in Computer Systems
-1 0 1 2 3 40
0.5
1
-1 0 1 2 3 4 5 6 7 8 90
0.5
1
0 1 2 3 4 5 6 7 8 9 100
2
4
6
8
10
12
Spike, one-time fluctuation in input/output, or disturbance
Change of reference value
Multiple changes of reference value
CS6501: Basics
Transfer Function
• Z-transforms can be used to describe signals
• They can also be used to describe systems (called a transfer function)
• G(z) = Y(z)/U(z) or Y(z) = G(z)U(z)
• Output/InputU(k) Y(k)
CS6501: Basics
Transfer Function
• Transfer function provides a much more intuitive way to understand the input-output relationship, or system characteristics of an LTI system– Stability– Accuracy– Settling time– Overshoot
CS6501: Basics
An LTI System – Discrete Integrator
LTI: yimpuse(k)=udstep(k)
u (k) y (k)
ustep(k) udstep(k) uramp(k)*(convolution)
=
y(k)=y(k-1)+u(k-1)
Z-1Transfer Function
·(multiplication)
Z
1
-1
z1z
-1 0 1 2 3 40
0.5
1
Y(k)=u(k-1)+u(k-2)+…+u(1)+u(0)
-1 0 1 2 3 40
0.5
1
-1 0 1 2 3 40
1
2
3
4
Z
1z11
= 21
-1
)z(1z
CS6501: Basics
Inverse Z-Transform
• Table Lookup – if the Z-Transform looks familiar, look it up in the Z-Transform table!
• Long Division• Partial Fraction Expansion
u(k) U(z)ZZ-1?
2k 3
(k)2u(k)3uu(k) rampstep
(z)2U(z)3U
)z(12z
z13
U(z)
rampstep
21
1
1
Z-1?
CS6501: Basics
Long Division
• Sort both nominator and denominator with descending order of z first
21
1
z2z1z3
U(z)
• u(0), u(1), u(2), u(3), …, are coefficients of the z terms in the answer above (remember, a list of signal values is encoded with z terms: 3,5,7,9…)
CS6501: Basics
Partial Fraction Expansion
• Many Z-transforms of interest can be expressed as division of polynomials of z
m
0j
jj
n
0i
ii
zb
zaU(z)
May be trickier:complex rootduplicate root
)p)...(zp)(zp(zb
zb...zbzbb
m21m
mm
2210
m
1j j
j0 pz
ccU(z)
,1kjdexpp p(k)u
j
m
1jdexppimpulse0 (k)u(k)ucu(k)
j
where k>0
1j
1
zp1
cz
j
CS6501: Basics
An Example
86zz1414z3z
U(z) 2
2
4z
c2z
ccU(z) 21
0
0k,4c2c
0k,cu(k) 1k
21k
1
0
(z-2)(z-4)
U1(z)=c0 Z-1 u1(k)=c0*uimpulse(k)
Z-1
Z-1 u2(k)=c1*2k-1, k>02z
c(z)U 1
2
4zc
(z)U 23
u3(k)=c2*4k-1, k>0
c0? c1? c2?
CS6501: Basics
Get The Constants!
86zz1414z3z
U(z) 2
2
4z
c2z
ccU(z) 21
0
(z-2)(z-4)
,4z
c2z
ccU(z) 21
0
,z ,cU(z) 0 3
86zz1414z3z
limc 2
2
z0
,c2z4)(zc
4)c(z4)U(z)-(zK(z) 21
0
3|2z
1414z3zcK(4) 4z
2
2
CS6501: Basics
An Example – Complete Solution
386zz1414z3z
limU(z)limc 2
2
zz0
4-z1414z3z
86zz1414z3z
2)(z(z)U
2
2
2
2
2-z
1414z3z
86zz
1414z3z4)(z(z)U
2
2
2
3
86zz1414z3z
U(z) 2
2
4z
c2z
ccU(z) 21
0
14-2
1421423(2)Uc
2
21
32-4
1441443(4)Uc
2
32
4z3
2z1
3U(z)
0k,432
0k3,u(k) 1k1k
CS6501: Basics
Solving Difference Equations
m)u(kb...1)u(kbn)y(ka...1)y(kay(k) m1n1
U(z)zb...U(z)zbY(z)za...Y(z)zaY(z) mm
11
nn
11
U(z)za...za1
zb...zbY(z) n
n1
1
mm
11
...y(k)
Z
Z-1Transfer Function
CS6501: Basics
Signal Characteristics from Z-
Transform • If U(z) is a rational function, and
• Then Y(z) is a rational function, too
• Poles are more important – determine key characteristics of y(k)
m)u(kb...1)u(kbn)y(ka...1)y(kay(k) m1n1
m
1jj
n
1ii
)p(z
)z(z
D(z)N(z)
Y(z)
zeros
poles
CS6501: Basics
Determine Properties of System• Most properties only require knowledge of
roots of denominator– SASO properties
• Denominator is called the characteristic polynomial
• Roots of denominator may have complex poles– Represented in rectangular or polar coordinates
CS6501: Basics
Why are poles important?
m
1j j
j0m
1jj
n
1ii
pz
cc
)p(z
)z(z
D(z)N(z)
Y(z)
m
1j
1-kjjimpulse0 pc(k)ucY(k)
Z-1
Z domain
Time domain
poles
components
CS6501: Basics
Various pole values (1)
-1 0 1 2 3 4 5 6 7 8 90
0.5
1
1.5
2
2.5
-1 0 1 2 3 4 5 6 7 8 90
0.2
0.4
0.6
0.8
1
-1 0 1 2 3 4 5 6 7 8 90
0.2
0.4
0.6
0.8
1
-1 0 1 2 3 4 5 6 7 8 9-2.5
-2
-1.5
-1
-0.5
0
0.5
1
1.5
2
2.5
-1 0 1 2 3 4 5 6 7 8 9-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
-1 0 1 2 3 4 5 6 7 8 9-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
p=1.1
p=1
p=0.9
p=-1.1
p=-1
p=-0.9
CS6501: Basics
Various pole values (2)
-1 0 1 2 3 4 5 6 7 8 90
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
-1 0 1 2 3 4 5 6 7 8 90
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
-1 0 1 2 3 4 5 6 7 8 90
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
p=0.9
p=0.6
p=0.3
-1 0 1 2 3 4 5 6 7 8 9-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
-1 0 1 2 3 4 5 6 7 8 9-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
-1 0 1 2 3 4 5 6 7 8 9-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
p=-0.9
p=-0.6
p=-0.3
CS6501: Basics
Conclusion for Real Poles
• If and only if all poles’ absolute values are smaller than 1, y(k) converges to 0
• The smaller the poles are, the faster the corresponding component in y(k) converges
• A negative pole’s corresponding component is oscillating, while a positive pole’s corresponding component is monotonic
CS6501: Basics
How fast does y(k) converge?
• U(k)=ak, consider u(k)≈0 when the absolute value of u(k) is smaller than or equal to 2% of u(0)’s absolute value
|a|ln4
k
3.912ln0.02|a|kln
0.02|a| k
110.36
4|0.7|ln
4k
0.7a
RememberThis!
0 2 4 6 8 10 120
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
y(k)=0.7k
y(11)=0.0198
CS6501: Basics
Property - Settling Time (k units of time)
• Use Formula for k
|a|ln
4k
a is the magnitude of the (dominant) pole
CS6501: Basics
Example
10.8z11
U(z)
U(z)0.6zY(z)0.4zY(z) 11
0.4z0.6
U(z)Y(z)
G(z)
)0.8z-)(10.4z-(10.6z
U(z)0.4z1
0.6zY(z) 1-1-
-1
1
1
LTI: y(k)=0.4y(k-1)+0.6u(k-1)u (k)=0.8k y (k)?
ZZ
1k1k 0.8b0.4ay(k)
Z-1
SettlingTime
CS6501: Basics
When There Are Complex Poles …
U(z)za...za1
zb...zbY(z) n
n1
1
mm
11
c)...bz(az2
2a4acbb
z2
0,4acb2 )
2a4acbb
)(z2a
4acbba(zcbzaz
222
0,4acb2 )
2ab4acib
)(z2a
b4aciba(zcbzaz
222
If
If
Or in polar coordinates,
)irr)(zirra(zcbzaz2 θθθθ sincossincos
CS6501: Basics
What If Poles Are Complex• If Y(z)=N(z)/D(z), and coefficients of both
D(z) and N(z) are all real numbers, if p is a pole, then p’s complex conjugate must also be a pole– Complex poles appear in pairs
l
1j22
j
j0
l
1j j
j0
r)z(2rz)rdz(zbzr
pz
cc
irrzc'
irrzc
pz
ccY(z)
θ
θθ
θθθθ
cos
cossin
sincossincos
coskθdrsinkθbrpc(k)ucy(k) kkm
1j
1-kjjimpulse0
Z-1
Time domain
CS6501: Basics
An Example
0 2 4 6 8 10 12 14 16 18 20-1
-0.5
0
0.5
1
1.5
2
)3
kπcos(0.8)
3kπ
sin(0.82y(k)
0.640.8zzzz
Y(z)
kk
2
2
Z-Domain: Complex Poles
Time-Domain:Exponentially Modulated Sin/Cos
CS6501: Basics
Poles on Complex Plane
CS6501: Basics
Observations
• Using poles to characterize a signal– The smaller is |r|, the faster the signal converges
• |r| < 1, converge• |r| > 1, does not converge, unbounded• |r|=1?
– When the angle increase from 0 to pi, the frequency of oscillation increases
• Extremes – 0, does not oscillate, pi, oscillate at the maximum frequency
CS6501: Basics
Change Angles
0.9-0.9 Re
Im
0 5 10 15-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
0 5 10 15-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
0 5 10 15-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
0 5 10 15-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
0 5 10 15-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
0 5 10 15-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
0 5 10 15-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
0 5 10 15-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
0 5 10 15-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
CS6501: Basics0 2 4 6 8 10 12 14
-6
-4
-2
0
2
4
6
8
10
12
Changing Absolute Value
Im
Re
1
0 5 10 15-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
0 5 10 15-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
0 5 10 15-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
0 5 10 15-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
0 2 4 6 8 10 12 14-3
-2
-1
0
1
2
3
4
CS6501: Basics
Conclusion for Complex Poles
• A complex pole appears in pair with its complex conjugate
• The Z-1-transform generates a combination of exponentially modulated sin and cos terms
• The exponential base is the absolute value of the complex pole
• The frequency of the sinusoid is the angle of the complex pole (divided by 2π)
CS6501: Basics
Steady-State Analysis• If a signal finally converges, what value
does it converge to?• When it does not converge
– Any |pj| is greater than 1– Any |r| is greater than or equal to 1
• When it does converge– If all |pj|’s and |r|’s are smaller than 1, it
converges to 0– If only one pj is 1, then the signal converges to cj
• If more than one real pole is 1, the signal does not converge
kdrkbr kk cossin
m
1j
1-kjjimpulse0 pc(k)ucy(k)
CS6501: Basics
An Example (one pole is = 1)
kk 0.9)(30.52u(k)0.9z
3z0.5zz
1z2z
U(z)
0 10 20 30 40 50 60-1
0
1
2
3
4
5
6
converge to 2
CS6501: Basics
Final Value Theorem
• Enable us to decide whether a system has a steady state error (yss-rss)
CS6501: Basics
Final Value Theorem
1
Theorem: If all of the poles of (1 ) ( ) lie within the unit circle, then
lim ( ) lim ( 1) ( )k z
z Y z
y k z Y z
````````````````````````````
2
1 1
0.11 0.11( )
1.6 0.6 ( 1)( 0.6)
0.11( 1) ( ) | | 0.275
0.6z z
z zY z
z z z z
zz Y z
z
0 5 10 15-0.35
-0.3
-0.25
-0.2
-0.15
-0.1
-0.05
0
k
y(k)
If any pole of (z-1)Y(z) lies out of or ON the unit circle, y(k) does not converge!
CS6501: Basics
What Can We Infer from TF?
• Almost everything we want to know– Stability– Steady-State– Transients
• Settling time• Overshoot
– …
CS6501: Basics
0 5 10 15 200
0.2
0.4
0.6
0.8
1
Bounded Signals
-5
0
5a=0.4
-5
0
5a=0.9
-5
0
5a=1.2
0 5 10-5
0
5a=-0.4
0 5 10-5
0
5a=-0.9
0 5 10-5
0
5a=-1.2
0 10 20 30 40 50 60 70-1
-0.5
0
0.5
1 0 2 4 6 8-1
-0.5
0
0.5
1
CS6501: Basics
BIBO Stability
• Bounded Input Bounded Output Stability– If the Input is bounded, we want the
Output is bounded, too– If the Input is unbounded, it’s okay for
the Output to be unbounded
• For some computing systems, the output is intrinsically bounded (constrained), but limit cycle may happen
CS6501: Basics
Limit Cycle
Solution: make sure the system works in a linearized operating region
Output constrained, But oscillating – Bad!
Imagine CPU utilization Constantly switching from 1 to 0, 0 to 1, …
CS6501: Basics
Example of Stability
10.8z11
U(z)
U(z)0.6zY(z)0.4zY(z) 11
0.4z0.6
U(z)Y(z)
G(z)
)0.8z-)(10.4z-(10.6z
U(z)0.4z1
0.6zY(z) 1-1-
-1
1
1
LTI: y(k)=0.4y(k-1)+0.6u(k-1)u (k)=0.8k y (k)?
ZZ
BIBO? – only one pole at 0.4, so BIBO!
CS6501: Basics
Steady State Gain
yss
CS6501: Basics
Steady-State Gain – Cont’d
• Which value does the output converge to when the input is an unit step signal?– First of all, it has to converge
G(1)
zG(z)lim1z
z1)G(z)(zlim
1)Y(z)(zlimy(k)limy
1z
1z
1zkss
Final Value Theorem
Unit Step Input
CS6501: Basics
More General Case
m)u(kb...1)u(kbn)y(ka...1)y(kay(k) m1n1
U(z)za...za1
zb...zbY(z) n
n1
1
mm
11
n1
m1ss a...a1
b...by
Z
z=1
Transfer Function
Recall y(ss) = G(1) (that is, when z = 1)
CS6501: Basics
Example of Steady State Gain
1z11
U(z)
U(z)0.6zY(z)0.4zY(z) 11
0.4z0.6
U(z)Y(z)
G(z)
)z-)(10.4z-(10.6z
U(z)0.4z1
0.6zY(z) 1-1-
-1
1
1
LTI: y(k)=0.4y(k-1)+0.6u(k-1)u (k)=1 y (k)?
ZZ
Yss? G(1)=1, so yss=1
CS6501: Basics
System Order
• System Order = Number of Poles• The higher the system order is, the
more complex the system behavior is
• Some poles are more important than others– Why?
– If |pi|<|pj|,|pi/pj|k-1 approaches 0 when k is large (pi
k-1 converges faster than pjk-1)
m
1j
1-kjjimpulse0 pc(k)ucy(k)
CS6501: Basics
Overshoot and Settling Time
• If not all poles are positive real numbers, overshoot may happen– Easy to figure out when the system is
first order– For higher order systems, approximation
to first order systems works under certain conditions
• Settling time– First order system– Higher order systems
|p|ln4
ks
CS6501: Basics
How fast does y(k) converge?
• U(k)=ak, consider u(k)≈0 when the absolute value of u(k) is smaller than or equal to 2% of u(0)’s absolute value
|p|ln4
k
3.912ln0.02|p|kln
0.02|p| k
110.36
4|0.7|ln
4k
0.7p
RememberThis!
0 2 4 6 8 10 120
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
y(k)=0.7k
y(11)=0.0198
CS6501: Basics
Examples: Positive Pole
0 5 10 15 20 25 300
0.2
0.4
0.6
0.8
1
0 5 10 15 20 25 300
0.2
0.4
0.6
0.8
1
0 5 10 15 20 25 300
0.2
0.4
0.6
0.8
1
0 5 10 15 20 25 300
0.2
0.4
0.6
0.8
1
0.9z0.1
0.1)-0.9)(z(z0.09
0.3)-0.9)(z(z0.07
0.1)-0.3)(z-0.9)(z(z0.063
DominantPole: 0.9
CS6501: Basics
Examples: Negative Pole
0 5 10 15 20 25 300
0.5
1
1.5
2
0 5 10 15 20 25 300
0.5
1
1.5
2
0 5 10 15 20 25 300
0.5
1
1.5
2
0 5 10 15 20 25 300
0.5
1
1.5
2
0.9z1.9
0.1)-0.9)(z(z1.71
0.3)-0.9)(z(z1.33
0.1)-0.3)(z-0.9)(z(z1.197
DominantPole: -0.9
CS6501: Basics
Dominant Pole
• We can approximate a high-order system with a first-order system with the dominant pole of the high-order system– IF the dominant pole DOES exist– Can give a pretty good estimation of
settling time– Can give a reasonable estimate of the
maximum overshoot
• Some high-order systems do not have dominant pole!
CS6501: Basics
Dominant Pole – Cont’d
• If there is a dominant pole, it must be the pole with the maximum magnitude– The largest pole should have at least
twice the magnitude of the other poles!
• If the dominant pole is real (p’), the high-order system can be approximated by a first-order system
p'z)p'G(1)(1
(z)G'
|p'|ln4
ks
CS6501: Basics
Summary• Signals/Systems
– An LTI system can be specified by• Difference equation• Unit impulse response• Transfer function
• Characterize a signal with Z-transform– Z-domain (poles) -> Time domain (convergence,
etc.)
• Characterize a system with Transfer function– BIBO stability– Steady-State Gain– Transients: overshoot, settling time
• If there exists a dominant pole
CS6501: Basics
Extra Slides
• z-transforms of sin and cos and exponentially modulated sine
CS6501: Basics
sin? cos?
0 2 4 6 8 10 12 14 16 18-1
-0.5
0
0.5
1
sin(k*pi/6)
0 2 4 6 8 10 12 14 16 18-1
-0.5
0
0.5
1
cos(k*pi/6)
CS6501: Basics
From Exponential to Trigonometric
isincose i
isincos)isin()cos(e
1-
33221exp
az-11
...zazaaz1(z)U
?
Euler Formula:
Z[cos(kθ)]?Z[sin(kθ)]?
2ee
cosii
2iee
sinii
CS6501: Basics
Z-Transform of sin/cos
ikeu(k) 1-i ze-11
U(z)
2ee
)cos(ku(k)ikik
Time Domain Z-Transform
2iee
)sin(ku(k)ikik
-ikeu(k)1-i- ze-1
1U(z)
21
1
2121
1
1111
1i1-i
zz2cos1zcos1
)z(sin)zcos(1zcos1
)/2zisinzcos1
1zisinzcos1
1(
)/2ze1
1ze-1
1(U(z)
21-
-1
zz2cos-1zsin
U(z)
CS6501: Basics
Exponentially Modulated sin/cos
2)(ae)(ae
)cos(ka(k)ukiki
kexpcos
2i
)(ae)(ae)sin(ka(k)u
kikik
expsin
221-
-1
zazcos2a-1zsina
U(z)
0 2 4 6 8 10 12 14 16 18-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
u(k)=c os(k*pi/6)*0.9k
221-
-1
zazcos2a-1zsina
U(z)
A damped oscillating signal – a typical output of a second order system
CS6501: Basics
Are these BIBO?
Unity y(k+1) = 1
P Controller y(k+1) = KP u(k)
Integrator y(k+1) = y(k) + u(k)
I Controller y(k+1) = y(k) + KI u(k)
M/M/1/K y(k+1) = 0.49y(k) + 0.033u(k)
Mystery y(k+1) = -1.3y(k) + 2.3u(k)
CS6501: Basics
Better Way to Decide BIBO or NOTTheorem:
A system G(z) is BIBO stable iff all the poles of G(z) are inside the unit circle.
System Time domain Eq Transfer Function Poles
Unity y(k+1) = 1 G(z) = 1 N/A
P Controller
y(k+1) = KP u(k) G(z) = KP N/A
Integrator y(k+1) = y(k) + u(k) G(z) = 1/(z-1) z=1
I Controller
y(k+1) = y(k) + KI u(k) G(z) = KI/(z-1) z=1
M/M/1/K y(k+1) = 0.49y(k) + 0.033u(k)
G(z) = 0.033/(z-0.49)
z = 0.49
Mystery y(k+1) = -1.3y(k) + 2.3u(k)
G(z) = 2.3/(z+1.3) z = -1.3
CS6501: Basics
No Dominant Pole
0 5 10 15 20 25 30 35 40 45 50-3
-2
-1
0
1
2
3
4
5Step Response
Time (sec)
Am
plit
ud
e
pole=-0.9
pole=-0.7
poles=-0.9, -0.7
CS6501: Basics
Why do we need Z-Transform?• A signal can be characterized with
its Z-transform (poles, final value …)• In an LTI system, Z-transform Y(z) is
the multiplication of Z-transform U(z) and the transfer function
• The LTI system can be characterized by the transfer function, or the Z-transform of the unit impulse response