0% found this document useful (0 votes)
9 views

Chapter 1- Linear Discrete Dynamic Systems Analysis

The document is a lecture note on Digital Control Systems, specifically focusing on Linear Discrete Dynamic Systems Analysis. It covers topics such as the Z-Transform, basic digital control systems, discrete transfer functions, and various mathematical properties and examples related to these concepts. The content is structured into chapters and sections, providing a comprehensive overview of the subject matter.

Uploaded by

senshree250
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views

Chapter 1- Linear Discrete Dynamic Systems Analysis

The document is a lecture note on Digital Control Systems, specifically focusing on Linear Discrete Dynamic Systems Analysis. It covers topics such as the Z-Transform, basic digital control systems, discrete transfer functions, and various mathematical properties and examples related to these concepts. The content is structured into chapters and sections, providing a comprehensive overview of the subject matter.

Uploaded by

senshree250
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 80

ECEg4322: Digital Control

Systems
Nigusu Teshome,
Lecturer/Electrical and Computer Engineering Department,
Institute of Technology,
University of Gondar, Ethiopia.
eMail : [email protected]
Chapter 1

Linear Discrete Dynamic


Systems Analysis
Contents
1.1. Review of 𝓩-Transform
1.1.1. Introduction
1.1.2. Properties of 𝓩-Transform
1.2. Basic Digital Control System
1.3. The Discrete Transfer Function
1.4. Block Diagrams and State Variable Descriptions
1.5. Constant Coefficient Difference Equation (CCDE)
1.6. Sample and Hold
1.7. Digitization
1.8. Discrete Transfer Function of a Continuous System Preceded by a ZOH
1.9. Analysis of Sample and Hold
1.10. Sampling Operation by using Impulse Modulation
1.1. Review of 𝓩 -Transform
1.1.1. Introduction
Theorem:- Let r be any number and 𝑐 ≠ 0. Then, the geometric series
𝑐𝑟 𝑛 converges if and only if 𝑟 < 1.
• Then, for 𝑟 < 1

𝒏
𝒄
𝒄𝒓 =
𝟏−𝒓
𝒏=𝟎
∞ 𝑛
• If 𝑛=0 𝑐𝑟 converges, then

𝑚
𝑐𝑟
𝑐𝑟 𝑛 =
1−𝑟
𝑛=𝑚
Cont’d…
𝑛 𝑎
Proof:- The series sum form of 𝑎=0 𝑐𝑟 is:
⇒ 𝑆𝑛 = 𝑐 + 𝑐𝑟 + 𝑐𝑟 2 + 𝑐𝑟 3
+ ⋯ + 𝑐𝑟 𝑛
⇒ 𝑟𝑆𝑛 = 𝑐𝑟 + 𝑐𝑟 2 + 𝑐𝑟 3 + 𝑐𝑟 4 + ⋯ + 𝑐𝑟 𝑛+1
• Then
⇒ 𝑟𝑆𝑛 − 𝑆𝑛 = −𝑐 + 𝑐𝑟 𝑛+1
⇒ 𝑆𝑛 (𝑟 − 1) = 𝑐(−1 + 𝑟 𝑛+1 )

⇒ −𝑆𝑛 1 − 𝑟 = −𝑐(1 − 𝑟 𝑛+1 )


(1 − 𝑟 𝑛+1 )
⇒ 𝑆𝑛 = −𝑐
−1 1 − 𝑟

(1 − 𝑟 𝑛+1 )
⇒ 𝑆𝑛 = 𝑐
1−𝑟
Cont’d…
(1 − 𝑟 𝑛+1 )
⇒ lim 𝑆𝑛 = lim 𝑐
𝑛→∞ 𝑛→∞ 1−𝑟
𝑐
= lim {1 − 𝑟 𝑛+1 }
1 − 𝑟 𝑛→∞
𝑐
= 1 − lim 𝑟 𝑛+1
1−𝑟 𝑛→∞

𝑎𝑠 𝑟 < 1 𝑎𝑛𝑑 𝑛 𝑔𝑒𝑡𝑠 𝑙𝑎𝑟𝑔𝑒𝑟 𝑎𝑛𝑑 𝑙𝑎𝑟𝑔𝑒𝑟, lim 𝑟 𝑛+1 ≅ 0.


𝑛→∞

𝒄
= , 𝑓𝑜𝑟 𝒓 < 𝟏
𝟏−𝒓
Cont’d…
 If a signal has discrete values 𝑒0 , 𝑒1 , … , 𝑒𝑘 , we define the 𝓏-
transform of the signal as the function:
𝑬 𝒛 = 𝓩{𝒆(𝒌)}

= 𝒆(𝒌)𝒛−𝒌 , 𝒓𝒐 < |𝒛| < 𝑹𝒐


𝒌=−∞
and we assume that, we can find values of ro and Ro as bounds on the
magnitude of the complex variable z for which the series equation
∞ −𝒌
𝒌=−∞ 𝒆(𝒌)𝒛 converges.
Examples: Find the 𝓏-transform of:
1) Unit Impulse Function
1 , 𝑘=0
𝑒 𝑘 =
0 , 𝑘≠0
• Therefore

𝒵{𝑒(𝑘)} = 𝑒(𝑘)𝑧 −𝑘
𝑘=−∞

= 𝑧 −𝑘
𝑘=0
= 𝑧 −𝑘 | k=0

= 𝑧0
=1
Cont’d…
2) Unit Step Function
1, 𝑘≥0
𝑒 𝑘 =
0, 𝑒𝑙𝑠𝑒 𝑤ℎ𝑒𝑟𝑒
• Therefore

𝒵{𝑒(𝑘)} = 𝑒(𝑘)𝑧 −𝑘
𝑘=−∞

= 𝑧 −𝑘
𝑘=0
1
= 𝑓𝑜𝑟 𝑧 −1 < 1
1−𝑧 −1
𝑧
= 𝑓𝑜𝑟 𝑧 >1
𝑧−1
Cont’d…
3) Sinusoidal Function
𝑒 𝑘 = 𝑟 𝑘 sin 𝑘𝜃 1 𝑘 , 𝑟>0
Solution:
𝑟 𝑘 𝑗𝑘𝜃
𝑒 𝑘 = 𝑒 − 𝑒 −𝑗𝑘𝜃 1 𝑘 , 𝑟>0
2𝑗
• Therefore

𝒵{𝑒(𝑘)} = 𝑒(𝑘)𝑧 −𝑘
𝑘=−∞

𝑟 𝑘 𝑗𝑘𝜃
= 𝑒 − 𝑒 −𝑗𝑘𝜃 1 𝑘 𝑧 −𝑘
2𝑗
𝑘=−∞

𝑟 𝑘 𝑗𝑘𝜃
= 𝑒 − 𝑒 −𝑗𝑘𝜃 𝑧 −𝑘
2𝑗
𝑘=0
Cont’d… ∞ ∞
1
= 𝑟 𝑘 𝑒 𝑗𝑘𝜃 𝑧 −𝑘 − 𝑟 𝑘 𝑒 −𝑗𝑘𝜃 𝑧 −𝑘
2𝑗
𝑘=0 𝑘=0

∞ ∞
1 𝑗𝜃 −1 𝑘 −𝑗𝜃 −1 𝑘
= 𝑟𝑒 𝑧 − 𝑟𝑒 𝑧
2𝑗
𝑘=0 𝑘=0
• Let us do term by term:

𝑗𝜃 −1 𝑘 1
𝑟𝑒 𝑧 = 𝑓𝑜𝑟 𝑟𝑒 𝑗𝜃 𝑧 −1 < 1
1 − 𝑟𝑒 𝑗𝜃 𝑧 −1
𝑘=0
𝑧
= 𝑓𝑜𝑟 𝑟𝑒 𝑗𝜃 < 𝑧
𝑧−𝑟𝑒 𝑗𝜃

𝑠𝑖𝑛𝑐𝑒 − 1 ≤ 𝑒 𝑗𝜃 ≤ 1, 𝑟 > 0
⇛ 𝑧 >𝑟
Cont’d…
• And:

−𝑗𝜃 −1 𝑘 1
𝑟𝑒 𝑧 = 𝑓𝑜𝑟 𝑟𝑒 −𝑗𝜃 𝑧 −1 < 1
1 − 𝑟𝑒 −𝑗𝜃 𝑧 −1
𝑘=0
𝑧
= 𝑓𝑜𝑟 𝑟𝑒 −𝑗𝜃 < 𝑧 , 𝑠𝑖𝑛𝑐𝑒 − 1 ≤ 𝑒 −𝑗𝜃 ≤ 1, 𝑟 > 0
𝑧−𝑟𝑒 −𝑗𝜃
⇛ 𝑧 >𝑟
• So
∞ ∞
1 𝑗𝜃 −1 𝑘 −𝑗𝜃 −1 𝑘
𝒵{𝑒(𝑘)} = 𝑟𝑒 𝑧 − 𝑟𝑒 𝑧
2𝑗
𝑘=0 𝑘=0

1 𝑧 𝑧
= 𝑗𝜃
− , 𝑧 >𝑟
2𝑗 𝑧 − 𝑟𝑒 𝑧 − 𝑟𝑒 −𝑗𝜃
Cont’d…
𝑧 1 1
𝒵{𝑒(𝑘)} = 𝑗𝜃
− , 𝑧 >𝑟
2𝑗 𝑧 − 𝑟𝑒 𝑧 − 𝑟𝑒 −𝑗𝜃
𝑧 𝑧 − 𝑟𝑒 −𝑗𝜃 − 𝑧 + 𝑟𝑒 𝑗𝜃
= , 𝑧 >𝑟
2𝑗 (𝑧 − 𝑟𝑒 𝑗𝜃 )(𝑧 − 𝑟𝑒 −𝑗𝜃 )

𝑧 −𝑟𝑒 −𝑗𝜃 + 𝑟𝑒 𝑗𝜃
= , 𝑧 >𝑟
2𝑗 𝑧 2 − 𝑟𝑧𝑒 −𝑗𝜃 − 𝑟𝑧𝑒 𝑗𝜃 + 𝑟 2

𝑧 −𝑟(cos 𝜃 − 𝑗 sin 𝜃) + 𝑟(cos 𝜃 + 𝑗 sin 𝜃)


= , 𝑧 >𝑟
2𝑗 𝑧 2 − 𝑟𝑧(cos 𝜃 − 𝑗 sin 𝜃 + cos 𝜃 + 𝑗 sin 𝜃) + 𝑟 2

𝑧 −𝑟 cos 𝜃 + 𝑟𝑗 sin 𝜃 + 𝑟 cos 𝜃 + 𝑟𝑗 sin 𝜃)


= , 𝑧 >𝑟
2𝑗 𝑧 2 − 𝑟𝑧(2 cos 𝜃) + 𝑟 2

𝑟𝑧 sin 𝜃
= 2 , 𝑧 >𝑟
𝑧 + 𝑟 2 − 2𝑟𝑧 cos 𝜃
Cont’d…
1.1.2. Properties of 𝓩-Transform
(i) Linearity
• A continuous function 𝑓(𝑥) is linear if and only if:
𝑓 𝛼𝑥1 + 𝛽𝑥2 = 𝛼𝑓 𝑥1 + 𝛽𝑓 𝑥2
• For discrete function

𝒵 𝛼𝑓1 𝑘 + 𝛽𝑓2 𝑘 = {𝛼𝑓1 (𝑘) + 𝛽𝑓2 (𝑘)}𝑧 −𝑘


𝑘=−∞
∞ ∞

= 𝛼𝑓1 (𝑘) 𝑧 −𝑘 + 𝛽𝑓2 (𝑘)𝑧 −𝑘


𝑘=−∞ 𝑘=−∞
∞ ∞

=𝛼 𝑓1 (𝑘) 𝑧 −𝑘 + 𝛽 𝑓2 (𝑘)𝑧 −𝑘
𝑘=−∞ 𝑘=−∞

= 𝜶𝑭𝟏 𝒛 + 𝜷𝑭𝟐 𝒛
Cont’d…
(ii) Convolution of Time Sequences
∞ ∞ ∞

𝒵 𝑓1 𝑙 𝑓2 𝑘 − 𝑙 = 𝑓1 𝑙 𝑓2 𝑘 − 𝑙 𝑧 −𝑘
𝑙=−∞ 𝑘=−∞ 𝑙=−∞
∞ ∞

= 𝑓1 𝑙 𝑓2 𝑘 − 𝑙 𝑧 −𝑘
𝑙=−∞ 𝑘=−∞
𝑙𝑒𝑡 𝑘−𝑙 =𝑏 ⟹𝑘 =𝑏+𝑙
∞ ∞

= 𝑓1 𝑙 𝑓2 𝑏 𝑧 −(𝑏+𝑙)
𝑙=−∞ 𝑏=−∞
∞ ∞

= 𝑓1 𝑙 𝑓2 𝑏 𝑧 −𝑏 𝑧 −𝑙
𝑙=−∞ 𝑏=−∞
∞ ∞

= 𝑓1 𝑙 𝑧 −𝑙 𝑓2 𝑏 𝑧 −𝑏
𝑙=−∞ 𝑏=−∞

= 𝑭𝟏 𝒛 𝑭𝟐 𝒛
Cont’d…
(iii) Time Shift
𝒵 𝑓 𝑘 + 𝑛 = 𝒛𝒏 𝑭 𝒛
𝒵 𝑓 𝑘 − 𝑛 = 𝒛−𝒏 𝑭 𝒛
Proof: ∞

𝒵 𝑓 𝑘+𝑛 = 𝑓 𝑘 + 𝑛 𝑧 −𝑘
𝑘=−∞


𝑙𝑒𝑡 𝑘 + 𝑛 = 𝑙 ⟹ 𝑘 = 𝑙 − 𝑛
= 𝑓 𝑙 𝑧 −(𝑙−𝑛)
𝑙=−∞

= 𝑓 𝑙 𝑧 −𝑙 𝑧 𝑛
𝑙=−∞

= 𝑧𝑛 𝑓 𝑙 𝑧 −𝑙
𝑙=−∞

= 𝒛𝒏 𝑭 𝒛
Cont’d…
(iv) Scaling in the z-plane
𝒵 𝑟 −𝑘 𝑓 𝑘 = 𝑭 𝒓𝒛
Proof: ∞

𝒵 𝑟 −𝑘 𝑓 𝑘 = 𝑟 −𝑘 𝑓 𝑘 𝑧 −𝑘
𝑘=−∞

= 𝑓 𝑘 (𝑟𝑧)−𝑘
𝑘=−∞

= 𝑭 𝒓𝒛
Cont’d…
(v) Final Value Theorem
 If 𝐹 𝑧 converges for 𝑧 > 1 and all poles of (𝑧 − 1)𝐹 𝑧 are inside the
unit circle, then
𝐥𝐢𝐦 𝒇(𝒌) = 𝐥𝐢𝐦(𝒛 − 𝟏)𝑭 𝒛
𝒌→∞ 𝒛→𝟏
Example: Find the final value of
(𝑧 + 1 2)(𝑧 + 2)
𝐹 𝑧 = , 𝑧 >1
(𝑧 − 1 4)(𝑧 − 1)
Solution: 𝐹 𝑧 satisfies the condition for evaluating the final value of 𝑓 𝑘 :
(𝑧 + 1 2)(𝑧 + 2) 3 2 ∗ 3
lim 𝑓(𝑘) = lim (𝑧 − 1) = =6
𝑘→∞ 𝑧→1 (𝑧 − 1 4)(𝑧 − 1) 3
4
1.2. Basic Digital Control System

Figure: Block diagram of a basic digital control system


Cont’d…
Where
𝑟 𝑘𝑇 = 𝑅𝑒𝑓𝑒𝑟𝑒𝑛𝑐𝑒 𝑜𝑟 𝑐𝑜𝑚𝑚𝑎𝑛𝑑 𝑖𝑛𝑝𝑢𝑡𝑠
𝑢 𝑡 = 𝐶𝑜𝑛𝑡𝑟𝑜𝑙 𝑜𝑟 𝑎𝑐𝑡𝑢𝑎𝑡𝑜𝑟 𝑖𝑛𝑝𝑢𝑡 𝑠𝑖𝑔𝑛𝑎𝑙
𝑦 𝑡 = 𝐶𝑜𝑛𝑡𝑟𝑜𝑙𝑙𝑒𝑑 𝑜𝑟 𝑜𝑢𝑡𝑝𝑢𝑡 𝑠𝑖𝑔𝑛𝑎𝑙
𝑦 𝑘𝑇 = 𝐼𝑛𝑠𝑡𝑟𝑢𝑚𝑒𝑛𝑡 𝑜𝑟 𝑠𝑒𝑛𝑠𝑜𝑟 𝑜𝑢𝑡𝑝𝑢𝑡
𝑒 𝑘𝑇 = 𝑟 𝑘𝑇 − 𝑦 𝑘𝑇 = 𝐼𝑛𝑑𝑖𝑐𝑎𝑡𝑒𝑑 𝑒𝑟𝑟𝑜𝑟
𝑤 𝑡 = 𝐷𝑖𝑠𝑡𝑢𝑟𝑏𝑎𝑛𝑐𝑒 𝑖𝑛𝑝𝑢𝑡 𝑡𝑜 𝑡ℎ𝑒 𝑝𝑙𝑎𝑛𝑡
𝑣 𝑡 = 𝐷𝑖𝑠𝑡𝑢𝑟𝑏𝑎𝑛𝑐𝑒 𝑜𝑟 𝑛𝑜𝑖𝑠𝑒 𝑖𝑛 𝑡ℎ𝑒 𝑠𝑒𝑛𝑠𝑜𝑟
𝐴/𝐷 = 𝐴𝑛𝑎𝑙𝑜𝑔 𝑡𝑜 𝐷𝑖𝑔𝑖𝑡𝑎𝑙 𝐶𝑜𝑛𝑣𝑒𝑟𝑡𝑒𝑟
𝐷/𝐴 = 𝐷𝑖𝑔𝑖𝑡𝑎𝑙 𝑡𝑜 𝐴𝑛𝑎𝑙𝑜𝑔 𝐶𝑜𝑛𝑣𝑒𝑟𝑡𝑒𝑟
Cont’d…
 Plant:- is a process to be controlled whose satisfactory response
requires control action. By “satisfactory response” we mean that the
plant output 𝑦(𝑡), is to be forced to follow or track the reference input
𝑟(𝑡), despite the presence of disturbance inputs to the plant [𝑤(𝑡)]
and despite errors in the sensor [𝑣(𝑡)].
 Regulation:- is the process of holding 𝑦(𝑡) close to 𝑟(𝑡), including
the case where r ≡ 0.
 A system that has good regulation in the presence of disturbance
signals is said to have good disturbance rejection.
 A system that has good regulation in the face of changes in the plant
parameters is said to have low sensitivity to these parameters.
 A system that has both good disturbance rejection and low
sensitivity, we call it robust.
1.3. Discrete Transfer Function
 The 𝒵-transform has the same role in discrete systems that the
Laplace transform has in analysis of continuous systems.
 Consider that 𝑒𝑖 and 𝑢𝑖 are input and output signals of D/A computer. Suppose
we call the input signals up to the 𝑘th sample 𝑒0 , 𝑒1 , 𝑒2 , …, 𝑒𝑘 , and the output
signals prior to that time 𝑢0 , 𝑢1 , 𝑢2 , …, 𝑢𝑘−1 .
• Then, to get the next output, we have the machine compute some function,
which can express in symbolic form as

𝑢𝑘 = 𝑓{𝑒0 , 𝑒1 , 𝑒2 , …, 𝑒𝑘 ; 𝑢0 , 𝑢1 , 𝑢2 , …, 𝑢𝑘−1 }

 Assuming that 𝑓 is a linear and depends on only a finite number of past e’s and
u’s. Thus we can write
𝑢𝑘 = −𝑎1 𝑢𝑘−1 − 𝑎2 𝑢𝑘−2 − ⋯ − 𝑎𝑛 𝑢𝑘−𝑛 + 𝑏0 𝑒𝑘 + 𝑏1 𝑒𝑘−1 + ⋯ + 𝑏𝑚 𝑒𝑘−𝑚 .
Discrete Approximation to Integration
• Suppose we have a continuous signal 𝑒(𝑡) of which a segment is sketched in
below and we wish to compute an approximation to the integral

• Using only the discrete values 𝑒0 , 𝑒1 , 𝑒2 , …, 𝑒𝑘

Fig: Plot of 𝑒(𝑡) and alternative approximations to the area under the curve.
Cont’d…
• We assume that we have an approximation for the integral from zero to the time
𝑡𝑘−1 and we call it 𝑢𝑘−1 .
• The problem is to obtain 𝑢𝑘 from this information. Taking the view of the
integral as the area under the curve 𝑒(𝑡), we see that this problem reduces to
finding an approximation to the area under the curve between 𝑡𝑘−1 and 𝑡𝑘 .
• From fig (a), the area of the trapezoid is
1
𝐴 = (𝑡𝑘 − 𝑡𝑘−1 )𝑒𝑘−1 + (𝑡𝑘 − 𝑡𝑘−1 )(𝑒𝑘 − 𝑒𝑘−1 )
2
𝑡𝑘 −𝑡𝑘−1
= (2𝑒𝑘−1 + 𝑒𝑘 − 𝑒𝑘−1 )
2

𝑡𝑘 −𝑡𝑘−1
= (𝑒𝑘 + 𝑒𝑘−1 )
2
Cont’d…
 If we assume the sampling period 𝑡𝑘 − 𝑡𝑘−1 is a constant 𝑇, we are led to a
simple formula for discrete integration called the trapezoid rule
𝑇
𝐴= 𝑒𝑘 + 𝑒𝑘−1 𝑏𝑢𝑡 𝐴 = 𝑢𝑘 − 𝑢𝑘−1
2
• Then
𝑇
𝑢𝑘 − 𝑢𝑘−1 = 𝑒𝑘 + 𝑒𝑘−1
2
𝑇
𝑢𝑘 = 𝑢𝑘−1 + 𝑒𝑘 + 𝑒𝑘−1 … 𝑇𝑟𝑎𝑝𝑒𝑧𝑜𝑖𝑑 𝑅𝑢𝑙𝑒
2
Transfer function for trapezoid-rule integration:
 multiplying the trapezoid rule by 𝑧 −𝑘 and summing over k, we can get,
Cont’d…
∞ ∞ ∞
−𝑘 −𝑘
𝑇
𝑢𝑘 𝑧 = 𝑢𝑘−1 𝑧 + (𝑒𝑘 + 𝑒𝑘−1 )𝑧 −𝑘
2
𝑘=−∞ 𝑘=−∞ 𝑘=−∞
∞ ∞ ∞ ∞
−𝑘 −𝑘
𝑇 −𝑘
𝑇
𝑢𝑘 𝑧 = 𝑢𝑘−1 𝑧 + 𝑒𝑘 𝑧 + 𝑒𝑘−1 𝑧 −𝑘
2 2
𝑘=−∞ 𝑘=−∞ 𝑘=−∞ 𝑘=−∞

𝑇 𝑇 −1
⟹𝑈 𝑧 = 𝑧 −1 𝑈 𝑧 + 𝐸(𝑧) + 𝑧 𝐸(𝑧)
2 2

𝑇
⟹ (1 − 𝑧 −1 )𝑈 𝑧 = (1 + 𝑧 −1 )𝐸(𝑧)
2

𝑇 −1 )
𝑈 𝑧 (1+𝑧 𝑇 𝑧+1
2
⟹ = =
𝐸 𝑧 1−𝑧 −1 2 𝑧−1

𝑇 𝑧+1
𝐻 𝑧 =
2 𝑧−1
Cont’d…
 In general, the transfer function can be written as
𝑏0 + 𝑏1 𝑧 −1 + 𝑏2 𝑧 −2 + ⋯ + 𝑏𝑚 𝑧 −𝑚
𝑯 𝑧 =
1 + 𝑎1 𝑧 −1 + 𝑎2 𝑧 −2 + ⋯ + 𝑎𝑛 𝑧 −𝑛
• and if 𝑛 ≥ 𝑚, we can write this as a ratio of polynomials in 𝑧 as
𝑏0 𝑧 𝑛 + 𝑏1 𝑧 𝑛−1 + 𝑏2 𝑧 𝑛−2 + ⋯ + 𝑏𝑚 𝑧 𝑛−𝑚
𝑯 𝑧 =
𝑧 𝑛 + 𝑎1 𝑧 𝑛−1 + 𝑎2 𝑧 𝑛−2 + ⋯ + 𝑎𝑛
𝑏(𝑧)
=
𝑎(𝑧)
 The place in 𝑧 where 𝑏 𝑧 = 0 are zeros of the transfer function and
the place in 𝑧 where 𝑎 𝑧 = 0 are the poles of 𝐻 𝑧 .
Cont’d…
 When completely factored, the transfer function would be
𝑚
𝑖=1(𝑧 − 𝑧𝑖 )
𝑯 𝑧 =K 𝑛
𝑖=1(𝑧 − 𝑝𝑖 )
 The general input-output relation between transforms with linear,
constant, difference equations is:
𝑼(𝑧)
𝑯 𝑧 =
𝑬(𝑧)
• Or
𝑼 𝑧 = 𝑯 𝑧 𝑬(𝑧)
1.4. Block Diagrams and State Variable Descriptions
 Rules for Block Diagram Realization:
1. The transfer function of paths in parallel is the sum of the single path transfer
functions.

Fig a: Block diagram of parallel blocks.


2. The transfer function of paths in series is the product of the path transfer
functions.

Fig b: Block diagram of cascade blocks.


Cont’d…
3. The transfer function of a single loop of paths is the transfer function of
forward path divided by one minus the loop transfer function.

Fig c: Feedback transfer function.


4. The transfer function of an arbitrary multipath diagram is given by
combinations of these cases.
 S.J. Mason’s rule can also be used.
Canonical forms
 There are many ways to reduce the difference equation to a block diagram
involving 𝑧 only as the delay operator 𝑧 −1 .

(i) Control Canonical form


• Let the transfer function be
𝑼 𝒛
𝑯 𝒛 =
𝑬(𝒛)
𝑼 𝒛 𝒃 𝒛
⇛ =
𝑬(𝒛) 𝒂(𝒛)
𝑼 𝒛 𝑬 𝒛
⇛ =
𝒃(𝒛) 𝒂(𝒛)
Cont’d…
• Let
𝑼 𝒛 𝑬 𝒛
⇛ = = ℰ(𝒛)
𝒃(𝒛) 𝒂(𝒛)
• From this we can develop the following sets of equations:
𝑼 𝒛
i. 𝒃(𝒛)
= 𝓔(𝒛) ⟹ 𝑼 𝒛 = 𝒃(𝒛)𝓔(𝒛)
𝑬 𝒛
ii. 𝒂(𝒛)
= ℰ(𝒛) ⟹ 𝑬 𝒛 = 𝒂(𝒛)ℰ(𝒛)

• Consider a 4th order difference equation:


𝑈(𝑧) 𝑏0 𝑧 4 + 𝑏1 𝑧 3 + 𝑏2 𝑧 2 + 𝑏3 𝑧 + 𝑏4
= 4
𝐸(𝑧) 𝑧 + 𝑎1 𝑧 3 + 𝑎2 𝑧 2 + 𝑎3 𝑧 + 𝑎4
Cont’d…
 From this, we can develop the following sets of equations:
𝑧 4 + 𝑎1 𝑧 3 + 𝑎2 𝑧 2 + 𝑎3 𝑧 + 𝑎4 ℰ 𝑧 = 𝐸 𝑧 (𝑖)

𝑏0 𝑧 4 + 𝑏1 𝑧 3 + 𝑏2 𝑧 2 + 𝑏3 𝑧 + 𝑏4 ℰ 𝑧 = 𝑈 𝑧 (𝑖𝑖)
(a). From Equation (i), we can develop the state equation as follows:

⇛ 𝑧 4 ℰ 𝑧 + 𝑎1 𝑧 3 ℰ 𝑧 + 𝑎2 𝑧 2 ℰ 𝑧 + 𝑎3 𝑧ℰ 𝑧 + 𝑎4 ℰ 𝑧 = 𝐸 𝑧

⇛ 𝑧 4 ℰ 𝑧 = −𝑎1 𝑧 3 ℰ 𝑧 − 𝑎2 𝑧 2 ℰ 𝑧 − 𝑎3 𝑧ℰ 𝑧 − 𝑎4 ℰ 𝑧 + 𝐸(𝑧)
• Then, by applying inverse 𝒵-transform, the time domain of this state equation becomes:
⇛ 𝜀 𝑘 + 4 = −𝑎1 𝜀 𝑘 + 3 − 𝑎2 𝜀 𝑘 + 2 − 𝑎3 𝜀 𝑘 + 1 − 𝑎4 𝜀 𝑘 + 𝑒(𝑘)
Cont’d…
• To represent this system in terms of state variables, let us define
𝑥1 𝑘 = 𝜀 𝑘 + 3 ⟹ 𝑥1 𝑘 + 1 = 𝜀 𝑘 + 4
⟹ 𝑥1 𝑘 − 1 = 𝜀 𝑘 + 2

𝑥2 𝑘 = 𝑥1 𝑘 − 1 ⟹ 𝑥2 𝑘 + 1 = 𝑥1 𝑘
⟹ 𝑥2 𝑘 − 1 = 𝜀 𝑘 + 1

𝑥3 𝑘 = 𝑥2 𝑘 − 1 ⟹ 𝑥3 𝑘 + 1 = 𝑥2 𝑘
⟹ 𝑥3 𝑘 − 1 = 𝜀 𝑘

𝑥4 𝑘 = 𝑥3 𝑘 − 1 ⟹ 𝑥4 𝑘 + 1 = 𝑥3 𝑘
Cont’d…
• From the above four (4) Equations, the state equation becomes:
𝑥1 𝑘 + 1 = −𝑎1 𝑥1 𝑘 − 𝑎2 𝑥2 𝑘 − 𝑎3 𝑥3 𝑘 − 𝑎4 𝑥4 𝑘 + 𝑒(𝑘)

𝑥2 𝑘 + 1 = 𝑥1 𝑘

𝑥3 𝑘 + 1 = 𝑥2 𝑘

𝑥4 𝑘 + 1 = 𝑥3 𝑘

(b). From Equation (ii), we can develop the output equation as follows:
⇛ 𝑏0 𝑧 4 + 𝑏1 𝑧 3 + 𝑏2 𝑧 2 + 𝑏3 𝑧 + 𝑏4 ℰ 𝑧 = 𝑈 𝑧
⇛ 𝑏0 𝑧 4 ℰ 𝑧 + 𝑏1 𝑧 3 ℰ 𝑧 + 𝑏2 𝑧 2 ℰ 𝑧 + 𝑏3 𝑧ℰ 𝑧 + 𝑏4 ℰ 𝑧 = 𝑈 𝑧
Cont’d…
• Then, by applying inverse 𝒵 -transform, the time domain of this output equation
becomes:
⇛ 𝑏0 𝜀 𝑘 + 4 + 𝑏1 𝜀 𝑘 + 3 + 𝑏2 𝜀 𝑘 + 2 + 𝑏3 𝜀 𝑘 + 1 + 𝑏4 𝜀 𝑘 = 𝑢(𝑘)

⇛ 𝑢 𝑘 = 𝑏0 𝑥1 𝑘 + 1 + 𝑏1 𝑥1 𝑘 + 𝑏2 𝑥2 𝑘 + 𝑏3 𝑥3 𝑘 + 𝑏4 𝑥4 𝑘

= 𝑏0 −𝑎1 𝑥1 𝑘 − 𝑎2 𝑥2 𝑘 − 𝑎3 𝑥3 𝑘 − 𝑎4 𝑥4 𝑘 + 𝑒 𝑘 +
𝑏1 𝑥1 𝑘 + 𝑏2 𝑥2 𝑘 + 𝑏3 𝑥3 𝑘 + 𝑏4 𝑥4 𝑘

= (𝑏1 −𝑎1 𝑏0 )𝑥1 𝑘 + (𝑏2 −𝑎2 𝑏0 )𝑥2 𝑘 + (𝑏3 −𝑎3 𝑏0 )𝑥3 𝑘 +


(𝑏4 − 𝑎4 𝑏0 )𝑥4 𝑘 + 𝑏0 𝑒(𝑘)
Cont’d…
 In general, the state and output controllable canonical forms can be written in
matrix notation as the following:
𝒙 𝒌 + 𝟏 = 𝑨𝒄 𝒙 𝒌 + 𝑩𝒄 𝒆(𝒌)
𝒖(𝒌) = 𝑪𝒄 𝒙(𝒌) + 𝑫𝒄 𝒆(𝒌)
where
−𝑎1 −𝑎2 −𝑎3 −𝑎4 1
1 0 0 0 0
𝑨𝒄 = 0 1 0 0 , 𝑩𝒄 =
0
0 0 1 0 0

𝑪𝒄 = 𝑏1 − 𝑎1 𝑏0 𝑏2 − 𝑎2 𝑏0 𝑏3 − 𝑎3 𝑏0 𝑏4 − 𝑎4 𝑏0

𝑫𝒄 = 𝑏0
Cont’d…
 Block Diagram Development for Control Canonical Form
• From the State Equation,
𝑥1 𝑘 + 1 = −𝑎1 𝑥1 𝑘 − 𝑎2 𝑥2 𝑘 − 𝑎3 𝑥3 𝑘 − 𝑎4 𝑥4 𝑘 + 𝑒(𝑘)
⇒ 𝑧𝑋1 𝑧 = −𝑎1 𝑋1 𝑧 − 𝑎2 𝑋2 𝑧 − 𝑎3 𝑋3 𝑧 − 𝑎4 𝑋4 𝑧 + 𝐸(𝑧)

⇒ 𝑋1 𝑧 = 𝑧 −1 {−𝑎1 𝑋1 𝑧 − 𝑎2 𝑋2 𝑧 − 𝑎3 𝑋3 𝑧 − 𝑎4 𝑋4 𝑧 + 𝐸 𝑧 }
And also
𝑥2 𝑘 + 1 = 𝑥1 𝑘 ⇒ 𝑋2 𝑧 = 𝑧 −1 𝑋1 𝑧
𝑥3 𝑘 + 1 = 𝑥2 𝑘 ⇒ 𝑋3 𝑧 = 𝑧 −1 𝑋2 𝑧
𝑥4 𝑘 + 1 = 𝑥3 𝑘 ⇒ 𝑋4 𝑧 = 𝑧 −1 𝑋3 𝑧
• from the output equation, we have
𝑢 𝑘 = 𝑏0 𝑥1 𝑘 + 1 + 𝑏1 𝑥1 𝑘 + 𝑏2 𝑥2 𝑘 + 𝑏3 𝑥3 𝑘 + 𝑏4 𝑥4 𝑘
Cont’d…

Figure: Block diagram development of control canonical form


Cont’d…
(ii) Observer Canonical form
 Consider the following difference equation:
𝑈(𝑧) 𝑏0 𝑧 4 + 𝑏1 𝑧 3 + 𝑏2 𝑧 2 + 𝑏3 𝑧 + 𝑏4
= 4
𝐸(𝑧) 𝑧 + 𝑎1 𝑧 3 + 𝑎2 𝑧 2 + 𝑎3 𝑧 + 𝑎4
𝑧 4 𝑈(𝑧) + 𝑎1 𝑧 3 𝑈(𝑧) + 𝑎2 𝑧 2 𝑈(𝑧) + 𝑎3 𝑧𝑈(𝑧) + 𝑎4 𝑈(𝑧)
= 𝑏0 𝑧 4 𝐸(𝑧) + 𝑏1 𝑧 3 𝐸(𝑧) + 𝑏2 𝑧 2 𝐸(𝑧) + 𝑏3 𝑧𝐸(𝑧) + 𝑏4 𝐸(𝑧)
• Procedure:
(a) In this equation, the external input is 𝑒(𝑘), and the response is 𝑢(𝑘), which is
the solution of this equation. The terms with factors of 𝑧 are time-shifted toward the
future with respect to 𝑘 and must be eliminated in some way. To do this, we assume
at the start that we have the 𝑢(𝑘), and of course the 𝑒(𝑘), and we rewrite the
equation as:
Cont’d…
𝑏4 𝐸 𝑧 − 𝑎4 𝑈(𝑧) = 𝑧 4 𝑈 𝑧 + 𝑎1 𝑧 3 𝑈 𝑧 + 𝑎2 𝑧 2 𝑈 𝑧 + 𝑎3 𝑧𝑈 𝑧 − 𝑏0 𝑧 4 𝐸 𝑧 − 𝑏1 𝑧 3 𝐸 𝑧 − 𝑏2 𝑧 2 𝐸 𝑧 − 𝑏3 𝑧𝐸(𝑧)

⇛ 𝑏4 𝐸 𝑧 − 𝑎4 𝑈(𝑧) = 𝑧{𝑧 3 𝑈 𝑧 + 𝑎1 𝑧 2 𝑈 𝑧 + 𝑎2 𝑧𝑈 𝑧 + 𝑎3 𝑈 𝑧 − 𝑏0 𝑧 3 𝐸 𝑧 − 𝑏1 𝑧 2 𝐸 𝑧 − 𝑏2 𝑧𝐸 𝑧 − 𝑏3 𝐸 𝑧 }

⇛ 𝑧 −1 {𝑏4 𝐸 𝑧 − 𝑎4 𝑈 𝑧 } = 𝑧 3 𝑈 𝑧 + 𝑎1 𝑧 2 𝑈 𝑧 + 𝑎2 𝑧𝑈 𝑧 + 𝑎3 𝑈 𝑧 − 𝑏0 𝑧 3 𝐸 𝑧 − 𝑏1 𝑧 2 𝐸 𝑧 − 𝑏2 𝑧𝐸 𝑧 − 𝑏3 𝐸 𝑧

Let
𝑥4 (𝑘 + 1) = 𝑏4 𝑒 𝑘 − 𝑎4 𝑢 𝑘
⇒ 𝑧𝑋4 𝑧 = 𝑏4 𝐸 𝑧 − 𝑎4 𝑈 𝑧
⇒ 𝑋4 𝑧 = 𝑧 −1 {𝑏4 𝐸 𝑧 − 𝑎4 𝑈 𝑧 }

⇛ 𝑋4 𝑧 = 𝑧 3 𝑈 𝑧 + 𝑎1 𝑧 2 𝑈 𝑧 + 𝑎2 𝑧𝑈 𝑧 + 𝑎3 𝑈 𝑧 − 𝑏0 𝑧 3 𝐸 𝑧 − 𝑏1 𝑧 2 𝐸 𝑧 − 𝑏2 𝑧𝐸 𝑧 − 𝑏3 𝐸 𝑧

(b) Now in this internal result there appear 𝑎3 𝑈(𝑧) and −𝑏3 𝐸(𝑧), which can be canceled by
adding proper multiples of 𝑈(𝑧) and 𝐸(𝑧), and once they have been removed, the remainder can
again be operated on by 𝑧 −1 .
𝑋4 𝑧 + 𝑏3 𝐸 𝑧 − 𝑎3 𝑈 𝑧 = 𝑧 3 𝑈 𝑧 + 𝑎1 𝑧 2 𝑈 𝑧 + 𝑎2 𝑧𝑈 𝑧 − 𝑏0 𝑧 3 𝐸 𝑧 − 𝑏1 𝑧 2 𝐸 𝑧 − 𝑏2 𝑧𝐸 𝑧
Cont’d…
⇛ 𝑋4 𝑧 + 𝑏3 𝐸 𝑧 − 𝑎3 𝑈 𝑧 = 𝑧{𝑧 2 𝑈 𝑧 + 𝑎1 𝑧𝑈 𝑧 + 𝑎2 𝑈 𝑧 − 𝑏0 𝑧 2 𝐸 𝑧 − 𝑏1 𝑧𝐸 𝑧 − 𝑏2 𝐸 𝑧 }
⇛ 𝑧 −1 {𝑋4 𝑧 + 𝑏3 𝐸 𝑧 − 𝑎3 𝑈 𝑧 } = 𝑧 2 𝑈 𝑧 + 𝑎1 𝑧𝑈 𝑧 + 𝑎2 𝑈 𝑧 − 𝑏0 𝑧 2 𝐸 𝑧 − 𝑏1 𝑧𝐸 𝑧 − 𝑏2 𝐸 𝑧

• Let
𝑥3 𝑘 + 1 = 𝑥4 𝑘 + 𝑏3 𝑒 𝑘 − 𝑎3 𝑢 𝑘

⇒ 𝑧𝑋3 𝑧 = 𝑋4 𝑧 + 𝑏3 𝐸 𝑧 − 𝑎3 𝑈 𝑧

⇒ 𝑋3 𝑧 = 𝑧 −1 {𝑋4 𝑧 + 𝑏3 𝐸 𝑧 − 𝑎3 𝑈 𝑧 }
• Then
⇛ 𝑋3 𝑧 = 𝑧 2 𝑈 𝑧 + 𝑎1 𝑧𝑈 𝑧 + 𝑎2 𝑈 𝑧 − 𝑏0 𝑧 2 𝐸 𝑧 − 𝑏1 𝑧𝐸 𝑧 − 𝑏2 𝐸 𝑧
 If we continue this process of subtracting out the terms at 𝑘 and operating on the
rest by 𝑧 −1 , we finally arrive at the place where all that is left is 𝑈(𝑧) alone!
Cont’d…
c 𝑋3 𝑧 = 𝑧 2 𝑈 𝑧 + 𝑎1 𝑧𝑈 𝑧 + 𝑎2 𝑈 𝑧 − 𝑏0 𝑧 2 𝐸 𝑧 − 𝑏1 𝑧𝐸 𝑧 − 𝑏2 𝐸 𝑧
⇛ 𝑋3 𝑧 + 𝑏2 𝐸 𝑧 − 𝑎2 𝑈 𝑧 = 𝑧 2 𝑈 𝑧 + 𝑎1 𝑧𝑈 𝑧 − 𝑏0 𝑧 2 𝐸 𝑧 − 𝑏1 𝑧𝐸 𝑧
⇛ 𝑋3 𝑧 + 𝑏2 𝐸 𝑧 − 𝑎2 𝑈 𝑧 = 𝑧{𝑧𝑈 𝑧 + 𝑎1 𝑈 𝑧 − 𝑏0 𝑧𝐸 𝑧 − 𝑏1 𝐸 𝑧 }
⇛ 𝑧 −1 {𝑋3 𝑧 + 𝑏2 𝐸 𝑧 − 𝑎2 𝑈 𝑧 } = 𝑧𝑈 𝑧 + 𝑎1 𝑈 𝑧 − 𝑏0 𝑧𝐸 𝑧 − 𝑏1 𝐸 𝑧
• Let
𝑥2 𝑘 + 1 = 𝑥3 𝑘 + 𝑏2 𝑒 𝑘 − 𝑎2 𝑢 𝑘

⇒ 𝑧𝑋2 𝑧 = 𝑋3 𝑧 + 𝑏2 𝐸 𝑧 − 𝑎2 𝑈 𝑧

⇒ 𝑋2 𝑧 = 𝑧 −1 {𝑋3 𝑧 + 𝑏2 𝐸 𝑧 − 𝑎2 𝑈 𝑧 }
• Then
⇛ 𝑋2 𝑧 = 𝑧𝑈 𝑧 + 𝑎1 𝑈 𝑧 − 𝑏0 𝑧𝐸 𝑧 − 𝑏1 𝐸 𝑧
Cont’d…
d 𝑋2 𝑧 = 𝑧𝑈 𝑧 + 𝑎1 𝑈 𝑧 − 𝑏0 𝑧𝐸 𝑧 − 𝑏1 𝐸 𝑧
⇛ 𝑋2 𝑧 + 𝑏1 𝐸 𝑧 − 𝑎1 𝑈 𝑧 = 𝑧𝑈 𝑧 − 𝑏0 𝑧𝐸 𝑧

⇛ 𝑋2 𝑧 + 𝑏1 𝐸 𝑧 − 𝑎1 𝑈 𝑧 = 𝑧{𝑈 𝑧 − 𝑏0 𝐸 𝑧 }

⇛ 𝑧 −1 {𝑋2 𝑧 + 𝑏1 𝐸 𝑧 − 𝑎1 𝑈 𝑧 } = 𝑈 𝑧 − 𝑏0 𝐸 𝑧
• Let
𝑥1 𝑘 + 1 = 𝑥2 𝑘 + 𝑏1 𝑒 𝑘 − 𝑎1 𝑢 𝑘
⇒ 𝑧𝑋1 𝑧 = 𝑋2 𝑧 + 𝑏1 𝐸 𝑧 − 𝑎1 𝑈 𝑧
⇒ 𝑋1 𝑧 = 𝑧 −1 {𝑋2 𝑧 + 𝑏1 𝐸 𝑧 − 𝑎1 𝑈 𝑧 }
• Then
⇛ 𝑋1 𝑧 = 𝑈 𝑧 − 𝑏0 𝐸 𝑧
Cont’d…
e 𝑋1 𝑧 = 𝑈 𝑧 − 𝑏0 𝐸 𝑧

⇛ 𝑈 𝑧 = 𝑋1 𝑧 + 𝑏0 𝐸 𝑧

⇛ 𝑢 𝑘 = 𝑥1 𝑘 + 𝑏0 𝑒 𝑘

 In general, from the above 5 steps

𝑢 𝑘 = 𝑥1 𝑘 + 𝑏0 𝑒 𝑘

𝑥1 𝑘 + 1 = 𝑥2 𝑘 + 𝑏1 𝑒 𝑘 − 𝑎1 𝑢 𝑘

= 𝑥2 𝑘 + 𝑏1 𝑒 𝑘 − 𝑎1 {𝑥1 𝑘 + 𝑏0 𝑒 𝑘 }

= −𝑎1 𝑥1 𝑘 + 𝑥2 𝑘 + (𝑏1 − 𝑎1 𝑏0 )𝑒 𝑘
Cont’d…
𝑥2 𝑘 + 1 = 𝑥3 𝑘 + 𝑏2 𝑒 𝑘 − 𝑎2 𝑢 𝑘

= 𝑥3 𝑘 + 𝑏2 𝑒 𝑘 − 𝑎2 {𝑥1 𝑘 + 𝑏0 𝑒 𝑘 }
= −𝑎2 𝑥1 𝑘 + 𝑥3 𝑘 + (𝑏2 − 𝑎2 𝑏0 )𝑒 𝑘

𝑥3 𝑘 + 1 = 𝑥4 𝑘 + 𝑏3 𝑒 𝑘 − 𝑎3 𝑢 𝑘

= 𝑥4 𝑘 + 𝑏3 𝑒 𝑘 − 𝑎3 {𝑥1 𝑘 + 𝑏0 𝑒 𝑘 }
= −𝑎3 𝑥1 𝑘 + 𝑥4 𝑘 + (𝑏3 − 𝑎3 𝑏0 )𝑒 𝑘

𝑥4 𝑘 + 1 = 𝑏4 𝑒 𝑘 − 𝑎4 𝑢 𝑘

= 𝑏4 𝑒 𝑘 − 𝑎4 {𝑥1 𝑘 + 𝑏0 𝑒 𝑘 }
= −𝑎4 𝑥1 𝑘 + (𝑏4 − 𝑎4 𝑏0 )𝑒 𝑘
Cont’d…
 The observable canonical form can be written in matrix form as the following:
𝒙 𝒌 + 𝟏 = 𝑨𝒐 𝒙 𝒌 + 𝑩𝒐 𝒆(𝒌)
𝒖(𝒌) = 𝑪𝒐 𝒙(𝒌) + 𝑫𝒐 𝒆(𝒌)
where
−𝑎1 1 0 0 𝑏1 − 𝑎1 𝑏0
−𝑎 0 1 0 𝑏2 − 𝑎2 𝑏0
𝑨𝒐 = −𝑎2 , 𝑩𝒐 =
3 0 0 1 𝑏3 − 𝑎3 𝑏0
−𝑎4 0 0 0 𝑏4 − 𝑎4 𝑏0

𝑪𝒐 = 1 0 0 0

𝑫𝒐 = 𝑏0
Cont’d…
 Block Diagram Development for Observable Canonical Form

Figure: Block diagram development of observable canonical form


1.5. Constant Coefficient Difference Equation (CCDE)

 The relation between 𝑢𝑖 and 𝑒𝑖 can be generally expressed in linear


difference equation as
𝑢𝑘 = −𝑎1 𝑢𝑘−1 − 𝑎2 𝑢𝑘−2 − ⋯ − 𝑎𝑛 𝑢𝑘−𝑛 + 𝑏0 𝑒𝑘 + 𝑏1 𝑒𝑘−1 + ⋯ + 𝑏𝑛 𝑒𝑘−𝑛
 If the 𝑎’s and 𝑏’s are constant, then the difference equation is
called a constant-coefficient difference equation (CCDE).
 To solve a specific CCDE, we need a starting time (k-value) and
some initial conditions to characterize the contents of the computer
memory at this time.
 If the response of a dynamic system to any finite initial conditions
can grow without bound, we call the system is unstable.
Cont’d…
 Consider the following difference equation with no input values.
𝑢𝑘 = 𝑢𝑘−1 + 𝑢𝑘−2 , 𝑢0 = 𝑢1 = 1
• Solution of the above system can be obtained by assuming a form for the solution with
unknown constants and to solve for the constants to match the given initial conditions.
• If we assume 𝑢𝑘 = 𝐴𝑧 𝑘 , then:
⇛ 𝐴𝑧 𝑘 = 𝐴𝑧 𝑘−1 + 𝐴𝑧 𝑘−2 , 𝐴 ≠ 0, 𝑧≠0
⇛ 𝐴𝑧 𝑘 = 𝐴𝑧 𝑘 𝑧 −1 + 𝐴𝑧 𝑘 𝑧 −2
⇛ 1 = 𝑧 −1 + 𝑧 −2
⇛ 𝑧2 − 𝑧 − 1 = 0
1+ 5 1− 5
∴ 𝑧1 = and 𝑧2 =
2 2
Cont’d…
• Since our equation is linear, a sum of the individual solutions will also be a solution.
Thus, we have found that a solution of the form:
⇛ 𝑢 𝑘 = 𝐴1 𝑧1 𝑘 + 𝐴2 𝑧2 𝑘
• We can solve for the unknown constants by requiring that this general solution satisfy
the specific initial conditions given.
• If we substitute 𝑘 = 0 and 𝑘 = 1, we obtain the simultaneous equations:
• at 𝑘 = 0,
⇛ 𝑢 0 = 𝐴1 𝑧1 0 + 𝐴2 𝑧2 0 ⟹ 1 = 𝐴1 + 𝐴2
• at 𝑘 = 1,
⇛ 𝑢 1 = 𝐴1 𝑧11 + 𝐴2 𝑧21 ⟹ 1 = 𝐴1 𝑧1 + 𝐴2 𝑧2
• These equations are easily solved to give:
5 +1 5 −1
𝐴1 = and 𝐴2 =
2 5 2 5
Cont’d…
1+ 5
 Furthermore, we can see that since 𝑧1 = is greater than 1, the
2
term in 𝑧1 𝑘 will grow without bound as k grows, which confirms our
suspicion that the equation represents an unstable system.
 The equation in 𝑧 that we obtain after we substitute 𝑢 = 𝑧 𝑘 is a
polynomial in 𝑧 is known as the characteristic equation of the
difference equation.
 If any solution of this equation is outside the unit circle (has a magnitude
greater than one), the corresponding difference equation is unstable in the
specific sense that for some finite initial conditions the solution will grow
without bound as time goes to infinity.
If all the roots of the characteristic equation are inside the unit circle, the
corresponding difference equation is stable.
Cont’d…
Example: Check the following system for stability.
𝑢𝑘 = 0.5𝑢𝑘−1 − 𝑢𝑘−2
Solution:
• let 𝑢𝑘 = 𝐴𝑧 𝑘 , then:
⇛ 𝐴𝑧 𝑘 = 0.5𝐴𝑧 𝑘−1 − 𝐴𝑧 𝑘−2
⇛ 1 = 0.5𝑧 −1 − 𝑧 −2
⇛ 𝑧 2 − 0.5𝑧 + 1 = 0
1 15
⇛ 𝑧1,2 = ± 𝑗
4 4

1 15 1 15
∴ 𝑧1 = + =1 and 𝑧2 = + =1
16 16 16 16
⇛ Since the roots are on the unit circle, the system is asymptotically stable.
1.6. Sample and Hold
• Sampling: it can be a modulation process in which a pulse train 𝑝(𝑡) with
magnitude 1 𝜎 and period 𝑇, multiplies a continuous function 𝑓(𝑡) and produce a

sampled function 𝑓𝑝 𝑡 .
Cont’d…
 Digital to Analog, DAC (or D/A) Converter:
 It serves as a device that converts the sampled signal to a continuous
signal.
 Zero Order Hold (ZOH):
 It takes the value of D/A converter at 𝑡 = 𝑘𝑇 and holds it constant
for 𝑘𝑇 ≤ 𝑡 < 𝑘 + 1 𝑇.
• Example: Let us consider a Sampler and ZOH for the following
signal.
Cont’d…
1.7. Digitization
 Continuous controllers are built using analog electronics such
as resistors, capacitors and operational amplifiers.

Figure: Block diagram of continuous control systems


Cont’d…
 However, most of control systems today use digital
computers (usually microprocessors or microcontrollers).

Figure: Block diagram of digital control systems


Cont’d…
 Difference between the two implementations:
 Digital system operates on samples of the sensed plant output rather than
on the continuous signal.
 The dynamics of digital controllers are represented by difference
equations.
Analog to Digital, ADC (or A/D) Converter:
 Acts on a physical variable (most commonly an electrical voltage) and
converts it into a binary number that usually consists of 10 or 12 bits.
 A binary number with 10 bits can take on 210 = 1024 values.
 The conversion from the analog signal y(t) occurs repetitively at instants of
time that are T seconds apart.
where 𝑇 = sampling period
Cont’d…
 Euler’s Method of Digital Approximation:
 From the definition of a derivative:
𝛿𝑥
𝑥 = lim
𝛿𝑡→0 𝛿𝑡
• where 𝛿𝑥 is the change in 𝑥 over a time interval 𝛿𝑡.
• Even if 𝛿𝑡 is not quite equal to zero, this relationship will be approximately
true, and
𝑥 𝑘+1 −𝑥 𝑘
𝑥≅ , 𝑇 = 𝑡𝑘+1 − 𝑡𝑘
𝑇
This approximation can be used in place of all derivatives that appear in the
controller differential equations to arrive at a set of difference equations that can
be solved by a digital computer.
Cont’d…
Example: Using Euler’s method, find the difference equations of the following
continuous controller with a sampling rate of 10 Hz.
𝑠+2
𝐻 𝑠 =5
𝑠 + 10
Solution:
⇒𝑇=1 𝑓 = 1
10 = 0.1 𝑠𝑒𝑐

𝑈(𝑠) 5𝑠+10
⇒𝐻 𝑠 = =
𝐸(𝑠) 𝑠+10

⇒ 𝑠 + 10 𝑈 𝑠 = 5𝑠 + 10 𝐸 𝑠

⇒ 𝑠𝑈 𝑠 + 10𝑈 𝑠 = 5𝑠𝐸 𝑠 + 10𝐸(𝑠)


Cont’d…
⇒ 𝑢 𝑡 + 10𝑢 𝑡 = 5𝑒 𝑡 + 10𝑒 𝑡

𝑢 𝑘+1 −𝑢(𝑘) 𝑒 𝑘+1 −𝑒(𝑘)


⇒ + 10𝑢 𝑘 = 5 + 10𝑒(𝑘)
𝑇 𝑇

⇒ 𝑢 𝑘 + 1 − 𝑢 𝑘 + 10𝑇𝑢 𝑘 = 5𝑒 𝑘 + 1 − 5𝑒 𝑘 + 10𝑇𝑒(𝑘)

⇒ 𝑢 𝑘 + 1 − 𝑢 𝑘 + (10 ∗ 0.1)𝑢 𝑘 = 5𝑒 𝑘 + 1 − 5𝑒 𝑘 + (10 ∗ 0.1)𝑒(𝑘)

⇒ 𝑢 𝑘 + 1 − 𝑢 𝑘 + 𝑢 𝑘 = 5𝑒 𝑘 + 1 − 5𝑒 𝑘 + 𝑒(𝑘)

⇒ 𝑢 𝑘 + 1 = 5𝑒 𝑘 + 1 − 4𝑒 𝑘
1.8. Discrete Transfer Function of a Continuous System
Preceded by a ZOH

We wish to find the discrete transfer function from the input samples 𝑢(𝑘𝑇) (which
probably come from a computer of some kind) to the output samples 𝑦(𝑘𝑇) picked up
by the A/D converter.
• Let us assume that this discrete transfer function is 𝐺(𝑧).
• To find 𝐺(𝑧) we need only observe that the 𝑦 𝑘𝑇 are samples of the plant output
when the input is from the D/A converter. As for D/A converter, we assume that this
device, commonly called a ZOH accepts a sample 𝑢(𝑘𝑇) at 𝑡 = 𝑘𝑇 and holds its
output constant at this value until the next sample is sent at 𝑡 = 𝑘𝑇 + 𝑇. The piecewise
constant output of the D/A is the signal, 𝑢(𝑡), that is applied to the plant.
• Consider that the input samples are unit impulse
Cont’d… 1, for k = 0
𝑢 𝑘𝑇 =
0 , elsewhere
• The output of the D/A converter preceded by a ZOH is a pulse of width 𝑇 seconds and
a height of 1.
𝑢 𝑡 =1 𝑡 −1 𝑡−𝑇

• The output of the plant in response to the given input is:


𝑌 𝑠 =𝐺 𝑠 𝑈 𝑠
= 𝐺 𝑠 ℒ{1 𝑡 − 1 𝑡 − 𝑇 }
1 𝑒 −𝑇𝑠
= 𝐺 𝑠 −{ }
𝑠 𝑠
−𝑇𝑠 𝐺 𝑠
= (1 − 𝑒 )
𝑠
Cont’d…
The required transfer function is the 𝒵-transform of the samples of the output
(the inverse Laplace transform of 𝑌 𝑠 ).
⇛𝑌 𝑧 =𝐺 𝑧 𝑈 𝑧
• Since the input samples are unit impulse, then:

𝑈 𝑧 = 𝒵{𝑢(𝑘𝑇)}
= 𝒵 1 |𝑘 = 0
=1
• Then

⇛𝑌 𝑧 =𝐺 𝑧
⇛ 𝐺 𝑧 = 𝒵 𝑦(𝑘𝑇)
= 𝒵 ℒ −1 𝑌(𝑠) |𝑡 = 𝑘𝑇
Cont’d…
−1 −𝑇𝑠 𝐺 𝑠
⇛𝐺 𝑧 =𝒵 ℒ (1 − 𝑒 ) |𝑡 = 𝑘𝑇
𝑠

−1 𝐺 𝑠 𝐺 𝑠
=𝒵 ℒ − ℒ −1 𝑒 −𝑇𝑠
𝑠 𝑠

−1 𝐺 𝑠 −1 −𝑇𝑠 𝐺 𝑠
=𝒵 ℒ −𝒵 ℒ 𝑒
𝑠 𝑠

𝑒 −𝑇𝑠 is a delay of one period

−1 𝐺 𝑠 𝐺 𝑠
=𝒵 ℒ − 𝑧 −1 𝒵 ℒ −1
𝑠 𝑠

𝐺 𝑠
= 1− 𝑧 −1 𝒵 ℒ −1 |𝑡 = 𝑘𝑇
𝑠
Cont’d…
Example: What is the discrete transfer function of
6
𝐺 𝑠 =
(𝑠 + 3)(𝑠 + 2)
preceded by a ZOH?

Solution:
𝐺 𝑠 6 1 2 3
⇛ = = + −
𝑠 𝑠(𝑠 + 3)(𝑠 + 2) 𝑠 𝑠 + 3 𝑠 + 2

−1 𝐺 𝑠
⇛ ℒ = 1 𝑡 + 2𝑒 −3𝑡 − 3𝑒 −2𝑡
𝑠

−1 𝐺 𝑠
⇛𝒵 ℒ |𝑡 = 𝑘𝑇
= 𝒵 1 𝑘𝑇 + 2𝑒 −3𝑘𝑇 − 3𝑒 −2𝑘𝑇
𝑠
Cont’d…
𝐺 𝑠 1 1 1
⇛𝒵 ℒ −1 |𝑡 = 𝑘𝑇
= −1
+2 −3𝑇 −1
−3
𝑠 1−𝑧 1−𝑒 𝑧 1 − 𝑒 −2𝑇 𝑧 −1
𝑧 𝑧 𝑧
= + 2 −3
𝑧−1 𝑧−𝑒 −3𝑇 𝑧−𝑒 −2𝑇

• The discrete transfer function 𝐺 𝑧 is:


𝐺 𝑠
𝐺 𝑧 = 1− 𝑧 −1 ∗𝒵 ℒ −1 |𝑡 = 𝑘𝑇
𝑠
𝑧 𝑧 𝑧
= 1− 𝑧 −1 + 2 − 3
𝑧−1 𝑧−𝑒 −3𝑇 𝑧−𝑒 −2𝑇

𝑧−1 𝑧 𝑧 𝑧
= + 2 − 3
𝑧 𝑧−1 𝑧−𝑒 −3𝑇 𝑧−𝑒 −2𝑇

𝑧−1 𝑧−1
=1+ 2 − 3
𝑧−𝑒 −3𝑇 𝑧−𝑒 −2𝑇
1.9. Analysis of Sample and Hold
• To get samples of a physical signal such as a position or a velocity into a digital
form, we have a sensor device that produces a voltage proportional to the
physical variable and an A/D converter or ADC that transforms the voltage into
a digital number.
• In order to give the computer an accurate representation of the signal exactly at the
sampling instants kT, the A/D converter is typically preceded by a sample-and-hold
circuit (SHC).

Figure: Analog-to-digital converter with sample and hold


• Where 𝑆 is an electronic switch that is driven by simple logic from a clock.
Cont’d…
Operation:
1. With the switch 𝑆 in position 1, the operational amplifier output vout (t) tracks
the input voltage vin (t) through the transfer function 1/(RCs+1).
 The circuit bandwidth of the SHC, 1/RC, is selected to be high compared to the input
signal bandwidth.
 During this “tracking time,” the ADC is turned off and ignores vout.
⟹ 𝑖1 = 𝑖2
𝑣𝑖 −𝑣𝑜
⟹ =
𝑅 𝑅𝑒𝑞
1 𝑅
𝑅𝑒𝑞 = 1 1 =
+ 𝑅𝐶𝑠+1
𝑅 1
𝐶𝑠
𝑣𝑖 −𝑣𝑜
⟹ =𝑅
𝑅 𝑅𝐶𝑠+1

𝑣𝑜 1
⟹ = −
𝑣𝑖 𝑅𝐶𝑠+1
Cont’d…
2. When a sample is to be taken at 𝑡 = 𝑘𝑇, the switch 𝑆 is set to position 2 and
the capacitor C holds the output of the op-amp frozen from that time at
𝑣𝑜𝑢𝑡 𝑘𝑇 = 𝑣𝑖𝑛 𝑘𝑇 .
The A/D converter is now signaled to begin conversion of the constant input from the SHC into a
digital number which will be a true representation of the input voltage at the sample instant.

When the conversion is completed, the digital number is presented to the computer at which time
the calculations based on this sample value can begin.

The SHC switch is now moved to position 1 and the circuit is again tracking, waiting for the next
command to freeze a sample. The SHC needs only to hold the voltage for a short time on the
order of microseconds in order for the conversion to be completed before it starts tracking again.

 So, the combination of the electronic SHC plus the ADC operate as a sample
and hold for the sampling period, T.
Cont’d…
1.10. Sampling Operation by using Impulse Modulation

• The role of the ideal sampler is to give a mathematical representation of the


process of taking periodic samples from r 𝑡 to produce 𝑟 𝑘𝑇 and to do this in
such a way that we can include the sampled signals in the analysis of continuous
signals using the Laplace transform. The technique is to use impulse modulation
as the mathematical representation of sampling.
• The output of a sampler as a string of impulses is:

𝑟∗ 𝑡 = 𝑟 𝑡 𝛿 𝑡 − 𝑘𝑇 = 𝑟(𝑘𝑇)
𝑘=−∞

• Impulse:- the limit of a pulse of unit area that has growing amplitude and
shrinking duration.
Cont’d…
The Laplace transform of the sampler is:

⇛ ℒ 𝑟∗ 𝑡 = 𝑟 ∗ 𝜏 𝑒 −𝑠𝜏 𝑑𝜏
−∞

∞ ∞

⇛ 𝑅∗ 𝑠 = 𝑟 𝜏 𝛿 𝜏 − 𝑘𝑇 𝑒 −𝑠𝜏 𝑑𝜏
−∞ 𝑘=−∞

∞ ∞

= 𝑟 𝜏 𝛿 𝜏 − 𝑘𝑇 𝑒 −𝑠𝜏 𝑑𝜏
𝑘=−∞ −∞

∞ ∞

= 𝑟 𝜏 𝑒 −𝑠𝜏 𝛿 𝜏 − 𝑘𝑇 𝑑𝜏
𝑘=−∞ −∞
Cont’d…
• But from impulse shifting property:

𝑓 𝑡 𝛿 𝑡 − 𝑎 𝑑𝑡 = 𝑓(𝑎)
−∞

⇛ 𝑅∗ 𝑠 = 𝑟 𝑘𝑇 𝑒 −𝑠𝑘𝑇
𝑘=−∞

The Laplace transform of the sample of a unit step function by using impulse
modulation is:
𝑟 𝑡 =1 𝑡 𝑓𝑜𝑟 𝑡≥0

𝑟∗ 𝑡 = 𝑟 𝑡 𝛿 𝑡 − 𝑘𝑇
𝑘=−∞
Cont’d…

𝑟∗ 𝑡 = 1 ∗ 𝛿 𝑡 − 𝑘𝑇
𝑘=0

= 𝛿 𝑡 − 𝑘𝑇
𝑘=0

𝑅∗ 𝑠 = 𝑟 𝑘𝑇 𝑒 −𝑠𝑘𝑇
𝑘=−∞

= 1 𝑘𝑇 𝑒 −𝑠𝑘𝑇
𝑘=0
Cont’d… ∞

𝑅∗ 𝑠 = 𝑒 −𝑠𝑘𝑇
𝑘=0

1
=
1 − 𝑒 −𝑠𝑇

• The hold is defined as the means whereby these impulses are extrapolated to the
piecewise constant signal 𝑟ℎ 𝑡 , defined as:
𝑟ℎ 𝑡 = 𝑟 𝑘𝑇 , 𝑘𝑇 ≤ 𝑡 < 𝑘𝑇 + 𝑇
• A general technique of data extrapolation from samples is to use a polynomial fit to
the past samples.
• If the extrapolation is done by a constant, which is a zero-order polynomial, then the
extrapolator is called a zero-order hold, and its transfer function is designated as
𝑍𝑂𝐻 𝑠 .
Cont’d…
 𝑍𝑂𝐻 𝑠 can be computed from the transform of its impulse
response.
 If 𝑟 ∗ (𝑡) = 𝛿(𝑡), then 𝑟ℎ 𝑡 , which is now the impulse response of
the 𝑍𝑂𝐻, is a pulse of height 1 and duration T seconds.

• The mathematical representation of the impulse response is simply:


𝑝 𝑡 = 1 𝑡 − 1(𝑡 − 𝑇)
• The required transfer function is the Laplace transform of 𝑝 𝑡 .
Cont’d…
 The Laplace transform of 𝑝 𝑡 is:
⇛ 𝑃 𝑠 = ℒ 𝑍𝑂𝐻 ∗ ℒ 𝑟 ∗ 𝑡
⇛ 𝑃 𝑠 = ℒ 𝑍𝑂𝐻 ∗ ℒ 𝛿 𝑡
⇛ 𝑃 𝑠 = ℒ 𝑍𝑂𝐻 ∗ 1
⇛ 𝑃 𝑠 = ℒ 𝑍𝑂𝐻
⇛ ℒ 𝑍𝑂𝐻 = 𝑃 𝑠
⇛ 𝑍𝑂𝐻 𝑠 = ℒ 𝑝(𝑡)

= ℒ 1 𝑡 − 1(𝑡 − 𝑇)

1 − 𝑒 −𝑠𝑇
=
𝑠
Assignment #1
1. a) List at least 3 commercially available ADC and DAC and compare their
performances.
b) Why we use ADC and DAC?
1. Describe the fundamental differences between “sampled data systems” and
“discrete time systems” in detail.
2. Let r be any number and 𝑐 ≠ 0. If

𝑐𝑟 𝑛
𝑛=0
converges, then proof that:

𝑚
𝑐𝑟
𝑐𝑟 𝑛 =
1−𝑟
𝑛=𝑚

You might also like