MA3005 Compiled
MA3005 Compiled
R(s) +
C(s)
+
-
Controller + Plant
1
Background
▪ Educational Background (Mechanical Engineering)
➢ B.Eng. with first class honors from NTU (2006 – 2010)
➢ Dual Ph.Ds. from NTU and CMU (2011 – 2016)
➢ Post-Doctoral Researcher at MPI (2016 – 2017)
CMU – Carnegie Mellon University (USA), MPI – Max Planck Institute for Intelligent Systems (Germany)
▪ Contact Details
➢ Email: [email protected]
➢ Office: N3.2-01-22
2
Teaching Plan (Part I)
LAMS and Live Short Review Lectures
Week Lecture Topics Tutorial
1 Introduction to Systems and Laplace Transformation
2 Mathematical Modelling of Dynamic Systems 1
3 Mathematical Modelling of Mechanical Systems 2
4 Response and Stability 3
5 First-Order and Second-Order Systems 4
6 Transient Response 5
7 Basic Control Actions (Quiz Week)
3
Teaching Plan (Part II)
Live Lectures
Week Lecture Topics Tutorial
8 Recap & Introduction to controller design/System Types 6
4
Assessment
Quiz (20%)
• Week 7 during lecture hours.
• Hint: Simpler than final exams – Don’t miss it!
Homework (20%)
• Released in Week 10 and two weeks to complete
5
Suggestions
6
Motivation
1. A method to unify sub-systems across different disciplines
For example:
Desired Electrical System Mechanical System Actual
Velocity Voltage Torque Velocity
Controller
Sensors
7
Laplace Transformation
Converting differential equations (t) algebraic equations (s)
𝑑𝑓 0
ℒ 𝑓(𝑡) = 𝐹(𝑠), ℒ = 𝑠𝐹 𝑠 − 𝑓(𝑡 = 0)
𝑑𝑡
8
Physical System
H(s)
Sensor
Software
Programming
9
Microcontroller
Example (Modelling)
Derive equation of motion
F Using f = ma,
C1 𝐹 − 𝐶1 𝑥ሶ + 𝐾1 𝑥 = 𝑀𝑥ሷ
M 𝐹 = 𝑀𝑥ሷ + 𝐶1 𝑥ሶ + 𝐾1 𝑥
K1 Laplace Transform
C1 x
𝐹(𝑠) = 𝑀𝑠 2 𝑋 + 𝐶1 𝑠𝑋 + 𝐾1 𝑋
𝐶1 𝑥ሶ 𝐶1 𝑥ሶ
𝐹 𝑠 = 𝑀𝑠 2 + 𝐶1 𝑠 + 𝐾1 𝑋
1
Input in s-domain: 𝐹(𝑠) =
𝑠
Solving 𝒙(𝒕)
1 1 1
𝑋 𝑠 = 𝐹(𝑠) 𝑋(𝑠) = 2
𝑀𝑠 2 + 𝐶1 𝑠 + 𝐾1 𝑠 + 7𝑠 + 6 𝑠
1
𝑋(𝑠) =
𝑠 𝑠 + 1 [𝑠 + 6]
11
11
Example (Solving II)
Ns 𝑁
1 Assume that: 𝑀 = 1 kg, 𝐶1 = 7 , 𝐾1 = 6 .
m 𝑚
F(s) 𝑀𝑠 2 + 𝐶1 𝑠 + 𝐾1 X(s) Solve 𝑥(𝑡) when 𝑓 𝑡 = 1 N.
1 A B C
Partial Fraction: 𝑋(𝑠) = 𝑠 𝑠 + 1 [𝑠 + 6] → 𝑋 s = s + s + 1 + s + 6
1 A B C
Partial Fraction: 𝑋(𝑠) = 𝑠 𝑠 + 1 [𝑠 + 6] → 𝑋 s = s + s + 1 + s + 6
1
= lim𝑠
𝑠→0 𝑠 𝑠 + 1 [𝑠 + 6]
1 1
= lim =
𝑠→0 1 [6] 6
14
14
Position Control System
Physical System
F
C1
K1 Displacement
x sensor
Block Diagrams
Xd(s) + E(s) F(s) X(s)
-
Gc (s) G(s)
Controller Plant
H(s)
Sensor 15
Summary
2. Laplace transformation
▪ Partial fraction and Laplace Inverse
▪ Final value theorem
16
Acknowledgement
17
D(s)
R(s) +
C(s)
+
-
Controller + Plant
1
Teaching Plan (Part I)
LAMS and Live Short Review Lectures
Week Lecture Topics Tutorial
1 Introduction to Systems and Laplace Transformation
2 Mathematical Modelling of Dynamic Systems 1
3 Mathematical Modelling of Mechanical Systems 2
4 Response and Stability 3
5 First-Order and Second-Order Systems 4
6 Transient Response 5
7 Basic Control Actions (Quiz Week)
2
Block Diagrams
Control Signal
Transfer Function
Objectives
• Understand the relationship between control signals and transfer functions
• Simplify the block diagrams
• Establish the relationship between the input and output control signals
3
3
General Rules
1. Multiply
𝐺1 𝐺2 𝐺1 𝐺2
𝐴 𝐴𝐺1 𝐺2
𝐺1 𝐺2
2. Summation
4
4
General Rules
3. Pre-Multiply (G) -> Post-Multiply (G)
AH AH
𝐻 𝐻/G
AG A
𝐺 𝐺
A AG
B
BG
G
B
5
5
General Rules
4. Post-Multiply (G) -> Pre-Multiply (G)
AGH AGH
𝐻 𝐺𝐻
𝐺 𝐺
A AG A AG
A+B/G
A AG+B
A AG AG+B G
G
B/G
B
1/G
B
6
6
General Rules
5. Closed-loop R – CH E(G)
R(s) 𝐺 C(s)
1 + 𝐺𝐻
8
8
Example I
Aim: Establish the relationship between Y(s) and X(s)
X A AX
𝑌 = 𝐴𝑋 + 𝐵𝑋 + 𝐶𝑋
X X BX Y
B + 𝑌 = 𝐴+𝐵+𝐶 𝑋
CX 𝑌
X C =𝐴+𝐵+𝐶
𝑋
X(s) Y(s)
𝐴+𝐵+𝐶
9
9
Example II (PYP April 2014)
Question 3B: Simplify the system and find C/R (7 marks)
R C
+
- G1 +
- G2 G3
H1
H2
R C
+
- +
- G1 G2 G3
H1
𝐻2
𝐺1
10
10
Example II (PYP April 2014)
Question 3B: Simplify the system and find C/R (7 marks)
R C
+
- +
- G1 G2 G3
H1
𝐻2
𝐺1
R C
+
- +
- G1 G2 G3
H1
𝐻2
𝐺1
11
11
Example II (PYP April 2014)
Question 3B: Simplify the system and find C/R (7 marks)
R C
+
- +
- G1 G2 G3
H1
𝐻2
𝐺1
R 𝐺1 𝐺2 C
+
- G3
1+𝐺1 𝐺2 𝐻1
𝐶 𝐺
G =
𝑅 1 + 𝐺𝐻
𝐻2
𝐺1
12
H 12
Example III (PYP April 2015)
Question 3A: Simplify the system and find C/R (6 marks)
R - C
+
- 𝐺1 + G2 +
- 𝐺3 G4
𝐻1 𝐻2
1
𝐺4
R - C
+
- 𝐺1 + G2 +
- 𝐺3 G4
𝐻1 𝐻2
13
13
Example III (PYP April 2015)
Question 3A: Simplify the system and find C/R (6 marks)
1
𝐺4
R - 𝐺3 𝐺4
+
- 𝐺1 + G2
1 + 𝐺3 𝐺4 𝐻2 C
𝐻1
1
𝐺4
R - C
+
- 𝐺1 + G2 +
- 𝐺3 G4
𝐻1 𝐻2
14
14
Example III (PYP April 2015)
Question 3A: Simplify the system and find C/R (6 marks)
1
𝐺4
R - 𝐺3 𝐺4
+
- 𝐺1 + G2
1 + 𝐺3 𝐺4 𝐻2 C
𝐻1
1
𝐺1 𝐺4
R - 𝐺3 𝐺4
+
- + 𝐺1 G2
1 + 𝐺3 𝐺4 𝐻2 C
𝐻1
15
15
Example III (PYP April 2015)
Question 3A: Simplify the system and find C/R (6 marks)
1
𝐺1 𝐺4
R - 𝐺3 𝐺4
+ +
- 𝐺1 G2
1 + 𝐺3 𝐺4 𝐻2 C
𝐻1
1
𝐺1 𝐺4
R - 𝐺3 𝐺4
+
- + 𝐺1 G2
1 + 𝐺3 𝐺4 𝐻2 C
𝐻1
16
16
Example III (PYP April 2015)
Question 3A: Simplify the system and find C/R (6 marks)
1
𝐺1 𝐺4
R - 𝐺3 𝐺4
+ +
- 𝐺1 G2
1 + 𝐺3 𝐺4 𝐻2 C
𝐻1
H 1
𝐺1 𝐺4
R - 𝐺1 𝐺2 𝐺3 𝐺4 𝐶 𝐺
+
1 + 𝐺1 𝐺2 𝐻1 1 + 𝐺3 𝐺4 𝐻2 C =
𝑅 1 + 𝐺𝐻
G
17
17
Summary
18
D(s)
R(s) +
C(s)
+
-
Controller + Plant
1
Teaching Plan (Part I)
LAMS and Live Short Review Lectures
Week Lecture Topics Tutorial
1 Introduction to Systems and Laplace Transformation
2 Mathematical Modelling of Dynamic Systems 1
3 Mathematical Modelling of Mechanical Systems 2
4 Response and Stability 3
5 First-Order and Second-Order Systems 4
6 Transient Response 5
7 Basic Control Actions (Quiz Week)
2
Mechanical Systems
PYP Dec 2015 Qn 2B: Find Y/X (12 marks)
𝑧
Y(s)
G(s) X(s)
General Steps
1. Separate the springs, dampers and mass
2. Analyze forces on springs and dampers
3. Use free-body diagrams to write down the equation of motion
4. Laplace Transform
3
3
Steps 1–2
1. Separate the springs, dampers and mass
2. Analyze forces on springs and dampers
𝐾2𝑥 = 𝑀1 𝑧ሷ + 𝐵1𝑧ሶ + 𝐾1 + 𝐾2 𝑧
𝐾2
𝑍= 𝑋 −−− −(1)
𝑀1 𝑠 2 + 𝐵1𝑠 + 𝐾1 + 𝐾2
5
5
Steps 3-4 (Mass 2)
3. Use free-body diagrams to write down the equation of motion
𝑧 𝑥
𝐾1𝑧 + 𝐵1𝑧ሶ 𝐾2 (𝑥 − 𝑧) 𝐾0(𝑥 − 𝑦)
𝑀1 𝑀2
𝐾2 𝑥 − 𝑧
𝑧ሷ + 𝐵2𝑥ሶ 𝑥ሷ
𝐾2
𝑍= 𝑋 −−− −(1)
𝑀1 𝑠 2 + 𝐵1𝑠 + 𝐾1 + 𝐾2
𝐾2𝑧 + 𝐾0 𝑦 = 𝑀2 𝑥ሷ + 𝐵2𝑥ሶ + 𝐾0 + 𝐾2 𝑥
𝐾22
𝐾0 𝑌 = 𝑀2 𝑠 2 + 𝐵2𝑠 + 𝐾0 + 𝐾2 − 𝑋
𝑀1 𝑠 2 + 𝐵1𝑠 + 𝐾1 + 𝐾2
𝑋 𝐾0
= = 𝐺(𝑠)
𝑌 𝐾22
𝑀2 𝑠 2 + 𝐵2𝑠 + 𝐾0 + 𝐾2 −
𝑀1 𝑠 2 + 𝐵1𝑠 + 𝐾1 + 𝐾2
Y(s)
G(s) X(s) 7
7
Linear & Rotary Systems
Springs Linear Rotary
𝜃1 𝜃2
𝐾𝐿 𝜃1 𝐾𝑅 𝜃2
Scenario 1
𝜃2 > 𝜃1
𝐾𝐿 (𝜃2 −𝜃1 ) 𝐾𝐿 (𝜃2 −𝜃1 ) 𝐾𝑅 (𝜃2 −𝜃1 ) 𝐾𝑅 (𝜃2 −𝜃1 )
𝜃1 𝜃2
𝐾𝐿 𝜃1 𝐾𝑅 𝜃2
Scenario 2
𝜃2 < 𝜃1
𝐾𝐿 (𝜃1 −𝜃2 ) 𝐾𝐿 (𝜃1 −𝜃2 ) 𝐾𝑅 (𝜃1 −𝜃2 ) 𝐾𝑅 (𝜃1 −𝜃2 )
8
Example (PYP Aug 2019)
Question 2 (modified): Find the transfer function of the system
Given: Damping coefficient of air = C, mass = m, initial velocity = 𝑣𝑜
𝐶𝑣
𝑣 𝐶𝑣
𝑚𝑔 𝐶𝑣
𝑣ሶ
𝑚𝑔
Steps
1. Separate the springs, dampers and mass
2. Analyze forces on springs and dampers
9
9
Example (PYP Aug 2019)
Question 2 (modified): Find the transfer function of the system
Given: Damping coefficient of air = C, mass = m, initial velocity = 𝑣𝑜
𝑓 = 𝑚𝑣ሶ + 𝐶𝑣
𝑣ሶ
Step 4: Laplace Transform: 𝐹(𝑠) = 𝑚(𝑠𝑉 − 𝑣0 ) + 𝐶𝑉
𝑚𝑔 = 𝑓 𝑉 1
𝐹 𝑠 + 𝑚𝑣0 = 𝑚𝑠 + 𝐶 𝑉 → = = 𝐺(𝑠)
𝐹 𝑠 + 𝑚𝑣0 𝑚𝑠 + 𝐶
𝑚𝑔
𝐹= 1 𝑉
𝑠
𝑚𝑠 + 𝐶
𝑚𝑣0 10
10
Summary
11
D(s)
R(s) +
C(s)
+
-
Controller + Plant
1
Teaching Plan (Part I)
LAMS and Live Short Review Lectures
Week Lecture Topics Tutorial
1 Introduction to Systems and Laplace Transformation
2 Mathematical Modelling of Dynamic Systems 1
3 Mathematical Modelling of Mechanical Systems 2
4 Response and Stability 3
5 First-Order and Second-Order Systems 4
6 Transient Response 5
7 Basic Control Actions (Quiz Week)
2
Poles and Stability
𝑁 𝑠
Transfer function: 𝐺(𝑠) =
𝐷(𝑠)
Objectives
1. Understand what are poles
2. The relationship between poles and stability of a transfer function
3. Routh–Hurwitz stability criterion
3
3
Transfer Function Poles
Differential Equation Laplace Transformation
𝑀𝑥ሷ + 𝐶 𝑥ሶ + 𝐾𝑥 = 𝑓 𝑀𝑠 2 + 𝐶𝑠 + 𝐾 𝑋(𝑠) = 𝐹(𝑠)
𝑋(𝑠) 1
Homogeneous solution: 𝑀 𝑥ሷ + 𝐶 𝑥ሶ + 𝐾𝑥 = 0 =
𝐹(𝑠) 𝑀𝑠 2 + 𝐶𝑠 + 𝐾
𝑀𝑑 2 + 𝐶𝑑 + 𝐾 = 0 Transfer Function Poles: 𝑀𝑠 2 + 𝐶𝑠 + 𝐾 = 0
-2 -1 Re
𝑠 = −1 𝑠 = −2 Time
Pole #1 Pole #2
Transient response decays
5
Partially-Stable Systems
Transfer function poles dictate stability
𝑋(𝑠) 1
= 2
𝐹(𝑠) 𝑠 +4
Re
-2
𝑠 = ±𝑗2 Time
Complex Poles Transient response oscillates
6
Unstable Systems
Transfer function poles dictate stability
𝑋(𝑠) 1
= 2
𝐹(𝑠) 𝑠 +𝑠−2
-2 1 Re
𝑠=1 𝑠 = −2 Time
Pole #1 Pole #2
Transient response → ∞
s-plane 𝐴, 𝐵 are constants unstable system
7
Stability
Three types of poles
1. Real poles (e.g. s = a) Stable systems require
Transient response 𝐴𝑒 𝑎𝑡 𝑒 𝑎𝑡 → 0, when 𝑡 → ∞
𝑎<0
2. Pure complex poles (e.g. s = ±jb)
Left hand s-plane
Transient response 𝐴 cos(𝑏𝑡 + ∅) Im
(always partially-stable)
Stable Unstable
3. Complex poles with real parts (e.g. s = a ± jb)
Re
Transient response 𝐴𝑒 𝑎𝑡 cos(𝑏𝑡 + ∅)
𝐴, ∅ are constants
s-plane 8
Stability
9
9
Example
Characteristics equation: 𝑠 4 + 8𝑠 3 + 322 + 80𝑠 + 100 = 0
s4: 1 32 100
s3: 8 80
s2: 8 × 32 − 1 × 80 8 × 100
8 8
s1:
s0:
10
10
Example
Characteristics equation: 𝑠 4 + 8𝑠 3 + 322 + 80𝑠 + 100 = 0
s4: 1 32 100
s3: 8 80
s2: 22 100
s1: 22 × 80 − 8 × 100
22
s0:
11
11
Example
Characteristics equation: 𝑠 4 + 8𝑠 3 + 322 + 80𝑠 + 100 = 0
s4: 1 32 100
s3: 8 80
s2: 22 100
s1: 43.6
s3: 1 5
s2: 1 5
s1: 0 𝜀
s0: 5𝜀 − 1 0
=5
𝜀 NB: 𝜀 is small positive number
13
13
Special Case II
Entire row of elements are 0
s5: XX XX XX
s4: 1 5 20
s3: 0 0
s2:
Auxiliary polynomial: 𝑃 𝑠 = 𝑠 4 + 5𝑠 2 + 20
d𝑃 𝑠
= 4𝑠 3 + 10𝑠
d𝑠
d𝑃 𝑠
Use the coefficients of to replace the 0 elements
d𝑠
14
14
Special Case II
Entire row of elements are 0
s5: XX XX XX
s4: 1 5 20
s3: 4 10
s2:
Auxiliary polynomial: 𝑃 𝑠 = 𝑠 4 + 5𝑠 2 + 20
d𝑃 𝑠
= 4𝑠 3 + 10𝑠
d𝑠
d𝑃 𝑠
Use the coefficients of to replace the 0 elements
d𝑠
15
15
Special Case II
Entire row of elements are 0
s5: XX XX XX
s4: 1 5 20
s3: 4 10
s2: 2.5 20
Continue as per normal and check for sign changes in first numerical column
16
16
PYP Dec 2017 Qn 1
R(s) + 1 C(s) 𝐶 𝐺
𝐺CL = =
- 𝑠 3 + 𝑠 2 + 2𝑠 + 23 𝑅 1+𝐺
FLTF: G(s) 1
= 3
𝑠 + 𝑠 2 + 2𝑠 + 24
17
17
PYP Dec 2017 Qn 1
Characteristic Equation (CE): 𝑠 3 + 𝑠 2 + 2𝑠 + 24 = 0
s3: 1 2
s2: 1 24
s1: 1 × 2 − 1 × 24 = −22
1
s0: 24
Two sign changes -> Two roots with positive real parts -> Two unstable poles
18
18
Summary
19
D(s)
R(s) +
C(s)
+
-
Controller + Plant
1
Teaching Plan (Part I)
LAMS and Live Short Review Lectures
Week Lecture Topics Tutorial
1 Introduction to Systems and Laplace Transformation
2 Mathematical Modelling of Dynamic Systems 1
3 Mathematical Modelling of Mechanical Systems 2
4 Response and Stability 3
5 First-Order and Second-Order Systems 4
6 Transient Response 5
7 Basic Control Actions (Quiz Week)
2
Transfer Function
𝑠+3
R(s) 𝑠 3 + 2𝑠 2 + 5𝑠 + 10 C(s)
System Order: Highest power of ‘s’ in the denominator (e.g., 3rd-order system)
Poles of transfer function: Dictate transient response
DC gain of transfer function: Dictate steady-state response (step inputs)
Objectives
1. First order, second order and higher order systems
2. Step, impulse, ramp and parabolic responses
3. Pole-zero cancellation
3
3
First Order Systems
𝑘 Find: c(t) when r(t) is a step input with magnitude p
𝑝
R(s) 𝜏𝑠 + 1 C(s) 𝑟 𝑡 = 𝑝𝑢(𝑡) 𝑅 𝑠 =
𝑠
𝑝 𝑘 𝐴 𝐵
𝐶(𝑠) = = +
𝑠 𝜏𝑠+1 𝑠 𝜏𝑠 + 1
4
First Order Systems
𝑘 Find: c(t) when r(t) is a step input with magnitude p
𝑝
R(s) 𝜏𝑠 + 1 C(s) 𝑟 𝑡 = 𝑝𝑢(𝑡) 𝑅 𝑠 =
𝑠
𝑝 𝑘 𝐴 𝐵
𝐶(𝑠) = = +
𝑠 𝜏𝑠+1 𝑠 𝜏𝑠 + 1
𝑝𝑘 𝑝𝑘𝜏
= −
𝑠 𝜏𝑠 + 1
𝑡
−𝜏
𝑐 𝑡 = 𝑝𝑘 − 𝑝𝑘e
Steady-state output
Transient output
5
First Order Systems
𝑘 Find: c(t) when r(t) is a step input with magnitude p
𝑝
R(s) 𝜏𝑠 + 1 C(s) 𝑟 𝑡 = 𝑝𝑢(𝑡) 𝑅 𝑠 =
𝑠
𝑡
−
Solution: 𝑐 𝑡 = 𝑝𝑘 − 𝑝𝑘e 𝜏
e.g., p = k = 1 Steady-state
value
2% settling time: 𝑡𝑠 = 4𝜏
2% settling
time
6
Key Parameters
𝑘 Find: r(t) when c(t) is a step input with magnitude p
𝐺(𝑠)
𝑘
DC gain of 𝐺 𝑠 = lim =𝑘
𝑠→0 𝜏𝑠+1
𝑐 𝑡 = 𝑐𝑠𝑠 + 𝑐𝑡𝑟
7
s-plane
Second Order Systems
𝑘𝜔𝑛2
Find: 𝑐 𝑡 when r(t) is a step
R(s) 𝑠 2 + 2𝜁𝜔𝑛 𝑠 + 𝜔𝑛2 C(s) input with magnitude p
𝐺(𝑠)
2
𝑘𝜔𝑛
DC gain of 𝐺 𝑠 = lim 2 =𝑘
𝑠→0 𝑠 2 +2𝜁𝜔𝑛 𝑠+𝜔𝑛
Poles of 𝐺 𝑠 : 𝑠 = −𝜁𝜔𝑛 ± 𝜔𝑛 𝜁 2 − 1
Poles: 𝑠 = 𝑎, 𝑏 → 𝑐𝑡𝑟 = 𝐴𝑒 𝑎𝑡 + 𝐵𝑒 𝑏𝑡
Im
Two first order poles
b a Re
Pole ‘a’ is dominant
because it decays slower
than pole ‘b’
s-plane
𝑐 𝑡 = 𝑐𝑠𝑠 + 𝑐𝑡𝑟
e.g., p = k = 1 9
Critically Damped Systems
𝑘𝜔𝑛2 Find: 𝑐 𝑡 when r(t) is a step
input with magnitude p
R(s) 𝑠 2 + 2𝜁𝜔𝑛 𝑠 + 𝜔𝑛2 C(s)
𝑐𝑠𝑠 = 𝑝𝑘, = 1
𝐺(𝑠)
Re
−𝜁𝜔𝑛
Critically damped systems
are faster than
overdamped systems
s-plane
𝑐 𝑡 = 𝑐𝑠𝑠 + 𝑐𝑡𝑟
e.g., p = k = 1
10
Underdamped Systems
𝑘𝜔𝑛2 Poles
𝑠 = −𝜁𝜔𝑛 ± 𝑗𝜔𝑛 1 − 𝜁 2 ,
R(s) 𝑠 2 + 2𝜁𝜔𝑛 𝑠 + 𝜔𝑛2 C(s) Transient
𝐴𝑒 −𝜁𝜔𝑛 𝑡 cos(𝜔𝑛 1 − 𝜁 2 𝑡 + ∅)
Step Response (p = k = 1)
Im 𝜋𝜁
−
%OS = 𝑒 1−𝜁 2
𝜁𝜔𝑛
𝜔𝑛
𝜔𝑛 1 − 𝜁2 𝛽
Re
4
𝑡𝑠 = steady-state
𝜁𝜔𝑛
cos 𝛽 = 𝜁 value
s-plane
11
𝑐 𝑡 = 𝑐𝑠𝑠 + 𝑐𝑡𝑟
Higher Order Systems
• Higher order systems can be decomposed into multiple first and second
order systems
12
Output Responses
Unit Impulse Unit Step Unit Ramp Unit Parabolic
𝑡2
𝑟 𝑡 = 𝛿(𝑡) 𝑟 𝑡 = 𝑢(𝑡) 𝑟 𝑡 = 𝑡. 𝑢(𝑡) 𝑟 𝑡 = . 𝑢(𝑡)
2
r r r r
t-domain
t t t t
1 1 1
s-domain 1
𝑠 𝑠2 𝑠3
𝑡 𝑡 𝑡
d𝑐 𝑡
න 𝑐(𝑡) d𝑡 න න 𝑐(𝑡) d𝑡 d𝑡
Output d𝑡 𝑐(𝑡) 0 0 0
13
Example (I)
𝑅(𝑠) 𝐸(𝑠) 1 𝐶(𝑠)
𝐴 Find K, A such that the unit step response:
𝑠+𝐵
2% settling time = 8 s, ess = 0.1
1
Time constant of 𝐺𝐶𝐿 : Comparison
𝐴+𝐵
1 𝐴
DC gain of 𝐺𝐶𝐿 :
𝐴 =2 = 0.9
𝐴+𝐵 𝐴+𝐵 𝐴+𝐵
𝐴 = 0.45, 𝐵 = 0.05 14
14
Example (II)
0.9 Aim: Find unit impulse and ramp response
R(s) 2𝑠 + 1 C(s) −
𝑡
Given unit step response: 𝑐 𝑡 = 0.9 − 0.9e 2
𝑡
−2
𝑐 𝑡 = 0.45e
15
15
Pole-Zero Cancellation
𝑁 𝑠
Transfer function: 𝐺(𝑠) =
G(s) 𝐷(𝑠)
Pole-zero cancellation
A phenomenon in which the effects of a pole will be cancelled
when its location in the s-plane is very near a zero
16
Example
𝑠 + 0.99 Effects of pole s = 1 is minimized due to
R(s) (𝑠 + 1)(𝑠 + 5) C(s) pole-zero cancellation
1 𝑠 + 0.99
Unit step response: 𝐶(𝑠) =
𝑠 (𝑠 + 1)(𝑠 + 5)
𝐴1 𝐵1 𝐵2
= + +
𝑠 𝑠+1 𝑠+5
𝐺𝑐 = 𝑠 + 𝐴 ± 𝜖
18
Summary
19
MA3005: Control Theory
Email: [email protected]
Phone: (+65)6790 4952
Office: N3-02c-68
Week 7 – Basic Control Actions
Part I – Lecture Map
2. Laplace
Transform
3. Modelling
1. Introduction to Systems
5. Routh Stability
8. Transient 7. Second-Order
Response
9. Basic
Control PART II. CONTROLLER DESIGN
Actions
Week 7 3
Learning Objectives
At the end of this week, you should be able to describe different types of controller.
+q
Target
Current position
Week 7 4
Control System
A control system can be:
• Open loop
R(s) C(s)
G(s)
• Closed-loop
Plant/
R(s) Controller
System C(s)
+-
Week 7 5
Open Loop Control System
Advantages:
• Stability is not a problem if plant is stable
• Less expensive
• Easier to control, especially if output cannot be measured
Disadvantages:
• Sensitive to disturbance and modelling errors
• Periodic calibration is required
Week 7 6
Closed-Loop Control System
Advantages:
• Reduced sensitivity to disturbance inputs
• Reduced sensitivity to changes in plant (modelling errors)
• Ability to stabilise an open loop unstable plant
• Ability to change dynamics of system to get the required system performance
Disadvantages:
• Need to use a sensor, which adds complexity and cost
• Risk of instability
Week 7 7
Block Diagram of an Industrial Control System
Automatic controller
Error detector
Reference
input Output
Amplifier Actuator Plant
Set point +-
Actuating
error signal
Sensor
Week 7 8
Simplified Feedback Block Diagram
Considering unity feedback system i.e. H(s) = 1:
R E U C
Controller Plant
+-
Week 7 9
Classification of Industrial Controllers
This includes:
• Two-position or on-off controller
• Proportional (P) controller
• Integral (I) controller
• Proportional-plus-Integral (P+I, PI) controller
• Proportional-plus-Derivative (P+D, PD) controller
• Proportional-plus-Integral-plus-Derivative (P+I+D, PID) controller
Week 7 10
On-Off Control Action
Characteristics:
• Two fixed positions, either on or off
• Relatively simple and inexpensive
• Output signal from controller u(t) remains at a minimum U2 or maximum U1 value,
depending on whether the actuating error signal e(t) is positive or negative
U1
e u e u
+- U2 +-
Week 7 11
Controller
Week 7 12
On-Off Controller Logic
R E Controller
U Plant
C
+-
Owing to the air conditioning (AC) concept, the controller will activate the plant (e.g. heat
pump) when C > R (or E < 0) and deactivate it when E > 0.
U
1
Note:
• 1 means activation of the plant.
0 E • 0 means deactivation of the plant.
Week 7 13
On-Off Controller Logic (Cont’d.)
R E Controller
U Plant
C
+-
+q
Target
Current position
Week 7 14
Controlling Servo System
U
+q 1
Target
Current position 0 E
–1
E = target - current
Note:
• 1 means to rotate the motor counterclockwise (ccw) in full speed.
• –1 means to rotate the motor clockwise (cw) in full speed.
Week 7 15
Controlling Servo System (Cont’d.)
U
+q 1
Target
0.5
Current position 0 E
–0.5
–1
E = target - current
Note:
• 1 means to rotate the motor ccw in full speed.
• –1 means to rotate the motor cw in full speed.
Week 7 16
Controlling Servo System (Cont’d.)
U
+q 1
Target
0.5
Current position 0 E
–0.5
–1
Note:
• 1 means to rotate the motor ccw in full speed.
• –1 means to rotate the motor cw in full speed.
Week 7 17
Controlling Servo System (Cont’d.)
U
+q 1
Target
0.5
Current position 0 E
–0.5
–1
E = target - current
19
P Control Action
The output signal of the controller u(t) is proportional to the error signal e(t) i.e.:
U (s)
u(t) = Kp e(t) or Kp
E (s)
• Kp is called the proportional gain.
• P controller is just an amplifier with an adjustable gain.
Week 7 20
Block Diagram for P Controller
E(s) U(s)
Kp
+-
e(t) u(t)
0 t 0 t
The plot of u(t) has the same shape as that of e(t) and is just scaled by the value of Kp.
Week 7 21
Effects of P Controller
A high value of Kp will result in:
• High system sensitivity and improved transient response
• Better disturbance rejection
• Lower steady-state error
Week 7 22
I Control Action
Controller output u(t) is changed at a rate proportional to the actuating error signal e(t) i.e.:
du (t ) t
K i e(t ) or u (t ) K i e(t )dt
dt 0
t
u (t ) . K i e(t )dt
where Ki is an adjustableorconstant
0
Week 7 23
Block Diagram of an I Controller
E(s) Ki U(s)
+- s
e(t) u(t)
Area = A u(t1) = KI A
0 t1 t2 t 0 t1 t2 t
In general, even if e(∞) = 0, there can be a non-zero actuation signal, i.e., u(∞) = constant
value ≠ 0.
Week 7 24
Effects of I Controller
There can be a constant u(∞) even when e(∞) = 0.
It is able to eliminate steady-state error due to step reference and disturbance inputs.
If e(t) does not change sign, u(t) will increase and become very large. For physical controller,
the output will saturate.
If e(t) changes sign, a larger KI value results in oscillatory u(t), which may result in a more
oscillatory response.
Week 7 25
PI Control Action
Control action of a PI controller is defined by:
t
u (t ) K p e(t ) K I e(t )dt
0
It is common practice to express integral control gain, in terms of integral time Ti, as:
U ( s) 1
K p 1
E (s) Ti
s
Week 7 26
Block Diagram of PI Controller
E(s) K p (1 Ti s ) U(s)
+- Ti s
where Kp is the proportional gain and Ti is the integral time (1/Ti is the reset rate).
Both Kp and Ti are adjustable.
Week 7 27
Effects of PI Controller
Its main effect is similar to I controller.
Both proportional and integral controllers contribute to u(t), whose larger value accelerates
the output towards the set point.
However, larger u(t) can result in the system to overreact, oscillate and may result in
instability (similar to I controller).
The I term allows for the elimination of steady-state error that may occur with P controller
alone.
Week 7 28
P, I and D Controllers
29
PD Control Action
Control action of a PD controller is defined as:
de(t )
u(t ) K p e(t ) K pTd
dt
and the transfer function is:
U ( s)
K p 1 Td s
E ( s)
Week 7 30
Block Diagram of PD controller
E(s) U(s)
Kp(1+Td s)
+-
Week 7 31
Effects of PD Controller
PD controller is able to anticipate error to improves stability, i.e., to increase the damping of
the system.
It tends to amplify high frequency signals, which may lead to saturation of system.
D controller is always combined with a P or PI controller.
Week 7 32
PID Control Action
PID control action is the combination of P, I, and D control actions. It has the advantages of
each of the three individual control actions.
The combine action is given as:
Kp t de(t )
u ( t ) K p e( t )
Ti 0
e(t )dt K pTd
dt
Transfer function representation:
U ( s) 1
K p 1 Td s
E ( s) Ti s
where Kp is the proportional gain, Ti is the integral time, and Td is the derivative time.
Week 7 33
Remarks on PID controller
PID control is extremely common in process industry.
It maintains controlled variables such as temperature, pressures, and levels at constant values
despite disturbances and parameters variation.
Gains of PID controller are set by established procedure such as Ziegler-Nichols method
(Section 8-2: Tuning Rules for PID controllers).
Week 7 34
Summary
Proportional control improves speed of response and disturbance rejection.
Integral control can remove steady-state error. However, it may also lead to oscillatory
response or instability.
Derivative control adds damping to the system and tends to increase the stability of the
system.
Derivative control permits the use of a larger proportional gain, which will result in an
improvement in the steady-state accuracy.
Week 7 35
Lesson Summary (Cont’d.)
At the end of this week, you should be able to describe different types of controller.
+q
Target
Current position
Week 7 36
D(s)
R(s) +
C(s)
+
-
Controller + Plant
1
Background
▪ Educational Background (Mechanical Engineering)
➢ B.Eng. with first class honors from NTU (2006 – 2010)
➢ Dual Ph.Ds. from NTU and CMU (2011 – 2016)
➢ Post-Doctoral Researcher at MPI (2016 – 2017)
CMU – Carnegie Mellon University (USA), MPI – Max Planck Institute for Intelligent Systems (Germany)
▪ Contact Details
➢ Email: [email protected]
➢ Office: N3.2-01-22
2
Teaching Plan
3
Continuous Assessment
Homework 2 (20%)
• Released in Week 10
• Two weeks to complete
4
Motivation
1. A method to unify sub-systems across different disciplines
For example:
Desired Electrical System Mechanical System Actual
Velocity Voltage Torque Velocity
Controller
Sensors
5
Laplace Transformation
Converting differential equations (t) algebraic equations (s)
𝑑𝑓 0
ℒ 𝑓(𝑡) = 𝐹(𝑠), ℒ = 𝑠𝐹 𝑠 − 𝑓(𝑡 = 0)
𝑑𝑡
6
Transfer Function Poles
Differential Equation Laplace Transformation
𝑀𝑥ሷ + 𝐶 𝑥ሶ + 𝐾𝑥 = 𝑓 𝑀𝑠 2 + 𝐶𝑠 + 𝐾 𝑋(𝑠) = 𝐹(𝑠)
𝑋(𝑠) 1
Homogeneous solution: 𝑀 𝑥ሷ + 𝐶 𝑥ሶ + 𝐾𝑥 = 0 =
𝐹(𝑠) 𝑀𝑠 2 + 𝐶𝑠 + 𝐾
𝑀𝑑 2 + 𝐶𝑑 + 𝐾 = 0 Transfer Function Poles: 𝑀𝑠 2 + 𝐶𝑠 + 𝐾 = 0
-2 -1 Re
𝑠 = −1 𝑠 = −2 Time
Pole #1 Pole #2
Transient response decays
8
Partially-Stable Systems
Transfer function poles dictate stability
𝑋(𝑠) 1
= 2
𝐹(𝑠) 𝑠 +4
Re
-2
𝑠 = ±𝑗2 Time
Complex Poles Transient response oscillates
9
Unstable Systems
Transfer function poles dictate stability
𝑋(𝑠) 1
= 2
𝐹(𝑠) 𝑠 +𝑠−2
-2 1 Re
𝑠=1 𝑠 = −2 Time
Pole #1 Pole #2
Transient response → ∞
s-plane 𝐴, 𝐵 are constants unstable system
10
Stability
Three types of poles
1. Real poles (e.g. s = a) Stable systems require
Transient response 𝐴𝑒 𝑎𝑡 𝑒 𝑎𝑡 → 0, when 𝑡 → ∞
𝑎<0
2. Pure complex poles (e.g. s = ±jb)
Left hand s-plane
Transient response 𝐴 cos(𝑏𝑡 + ∅) Im
(always partially-stable)
Stable Unstable
3. Complex poles with real parts (e.g. s = a ± jb)
Re
Transient response 𝐴𝑒 𝑎𝑡 cos(𝑏𝑡 + ∅)
𝐴, ∅ are constants
s-plane 11
Dominant Poles
Dominant poles are the
rightmost poles (slowest) Step Response
12
Transient Response
E.g., Underdamped Second Order System
Poles
𝑋(𝑠) 𝜔𝑛2 𝑠 = −𝜁𝜔𝑛 ± 𝑗𝜔𝑛 1 − 𝜁 2 ,
= 2 2, 𝜁<1 Transient
𝐹(𝑠) 𝑠 + 2𝜁𝜔𝑛 𝑠 + 𝜔𝑛 𝐴𝑒 −𝜁𝜔𝑛 𝑡 cos(𝜔𝑛 1 − 𝜁 2 𝑡 + ∅)
Im Step Response
𝜁𝜔𝑛 𝜋𝜁
−
%OS = 𝑒 1−𝜁 2
𝜔𝑛
𝜔𝑛 1 − 𝜁2 𝛽
Re
4
cos 𝛽 = 𝜁 𝑡𝑠 =
𝜁𝜔𝑛 steady-state
value
s-plane
13
Closed-Loop System
Software
Programming
15
Microcontroller
D(s)
R(s) +
C(s)
+
-
Controller + Plant
System Types
16
Unity feedback systems
R(s) + E(s) G (s) P(s)
C(s)
c
-
𝐶 𝐺
𝐸 =𝑅−𝐶 → 𝐸 =𝑅− 𝑅 → 𝐸 =𝑅 1−
𝑅 1+𝐺
𝑅
𝐸(𝑠) =
(1 + 𝐺)
Compute steady-state error ess via final value theorem:
sR( s )
= lim
s →0 1 + G ( s ) 19
Step Input ess
𝑠𝑅
General formula: 𝑒𝑠𝑠 = lim
s→0 (1 + 𝐺)
1 s 1 1
For step input: 𝑅 = → ess = lim ∙ =
s s→0 1 + 𝐺 𝑠 1 + 𝐺(𝑠 = 0)
We define Kp to be static position error constant, such that
𝐾𝑝 = lim 𝐺 𝑠 = 𝐺(𝑠 = 0)
𝑠→0
Using this definition, the step input ess can be expressed as:
1
ess =
1+ K p 20
Kp vs System Types
For type 0 systems
K (Ta s + 1)(Tb s + 1)
K p = lim =K
s →0 (T1s + 1)(T2 s + 1)
1 1
→ 𝑒𝑠𝑠 = =
1 + 𝐾𝑝 1 + 𝐾 (Non-zero error)
For type 1 or higher systems
K (Ta s + 1)(Tb s + 1)
K p = lim N → , for N 1
s →0 s (T s + 1)(T s + 1)
1 2
1
𝑒𝑠𝑠 = → 𝑒𝑠𝑠 = 0
1 + 𝐾𝑝
(steady-state error eliminated) 21
Observation (I)
For step inputs, the steady-state error ess:
1. Type 0 systems
1
ess = ( Non-zero value)
1+ K
2. Type 1 or higher systems
22
Ramp Input ess
𝑠𝑅
General formula: 𝑒𝑠𝑠 = lim
s→0 (1 + 𝐺)
1 s 1 1
For ramp input: 𝑅 = 2 → ess = lim ∙ 2=
s s→0 1 + 𝐺 𝑠 lim𝑠𝐺
s→0
We define Kv to be static velocity error constant, such that
K v = lim sG( s )
s→0
Using this definition, the ramp input ess can be expressed as:
1
ess =
Kv
23
Kv vs System Types
For type 0 systems
sK (Ta s + 1)(Tb s + 1) 1
K v = lim = 0 → 𝑒𝑠𝑠 = → ∞ (can’t follow input)
s →0 (T1s + 1)(T2 s + 1) 𝐾𝑣
2. Type 1 systems
1
𝑒𝑠𝑠 = (non-zero value)
𝐾𝑣
3. Type 2 or higher systems
𝑒𝑠𝑠 = 0 (steady-state error eliminated)
25
Unit Parabolic Input ess
𝑠𝑅
General formula: 𝑒𝑠𝑠 = lim
s→0 (1 + 𝐺)
1 s 1 1
Parabolic input: 𝑅 = 3 → ess = lim ∙ 3=
s s→0 1 + 𝐺 𝑠 lim𝑠 2 𝐺
s→0
We define Ka to be static acceleration error constant:
K a = lim s G ( s )
2
s →0
Using this definition, the parabolic input ess can be expressed as:
1
ess =
Ka 26
Ka vs System Types
For type 0 systems:
1
→ 𝑒𝑠𝑠 = →∞ (can’t follow input)
𝐾𝑎
27
Ka vs System Types
For type 2 systems:
s K (Ta s + 1)(Tb s + 1)
2
K a = lim 2 =K
s→0 s (T s + 1)(T s + 1)
1 2
1
→ 𝑒𝑠𝑠 = (non-zero error)
𝐾
For type 3 or higher systems
s 2 K (Ta s + 1)(Tb s + 1)
K a = lim N → , for N 3
s →0 s (T s + 1)(T s + 1)
1 2
1
→ 𝑒𝑠𝑠 = = 0 (steady-state error eliminated)
𝐾𝑎 28
Observation (III)
For parabolic inputs, the steady-state error ess:
1. Type 0 and 1 systems:
2. Type 2 systems
1
𝑒𝑠𝑠 = (non-zero value)
𝐾𝑎
3. Type 3 or higher systems
𝑒𝑠𝑠 = 0 (steady-state error eliminated)
29
Parabolic response of Type 2
30
Summary
Input “level”
Type 0 ∞ ∞
1 + 𝐾𝑝
1
Type 1 0 ∞
𝐾𝑣
1
Type 2 0 0
𝐾𝑎
Type 3 0 0 0
Input “Level” higher than System “level” 𝑒𝑠𝑠 → ∞
Input “Level” equal to System “level” 𝑒𝑠𝑠 is non-zero
Input “Level” lower than System “level” 𝑒𝑠𝑠 = 0
31
Discussion
▪ Steady-state errors are related to Kp, Kv, and Ka
32
Acknowledgement
33
D(s)
R(s) +
C(s)
+
-
Controller + Plant
1
Teaching Plan
Week Lecture Topics Tutorial
2
Closed Loop System
Purpose: Create desired Changing the system’s
transient and steady-state pole locations
response
Sensors
3
Root Locus
Using a proportional controller, i.e., Controller = K
H(s)
4
Illustration
c(t) K= 0.01
R(s) C(s)
+- K G(s)
jw
t
K=0.01 c(t) K=1
K=1
K→ b
× × × × × s t
K=10
K = 10
c(t)
s-plane
5
t
Motivation
Learning root locus allows you to:
6
Recap: Complex Numbers
𝜎
Im 𝜎 + 𝑗𝜔 = 𝑟𝑒 𝑗𝜃
𝑟 −1 𝜔
𝜔 where 𝑟 = 𝜎2 + 𝜔2 ,𝜃= tan
𝜎
𝜃 𝜎1 + 𝑗𝜔1 𝑟1 𝑒 𝑗𝜃1
Re =
𝜎2 + 𝑗𝜔2 𝑟2 𝑒 𝑗𝜃2
complex plane
𝑟1 𝑗(𝜃 −𝜃 )
= 𝑒 1 2
𝑟2
Phase
Magnitude 7
Recap: Complex Numbers
Im 𝑠 + 𝑧 = 𝑟𝑧 𝑒 𝑗𝜃𝑧 ,
where 𝑟𝑧 = |𝑠 + 𝑧 |
𝑠+𝑝
𝑠 𝑠 + 𝑝 = 𝑟𝑝 𝑒 𝑗𝜃𝑝 ,
𝑟𝑝 𝑟𝑧 𝑠 + 𝑧
where 𝑟𝑝 = |𝑠 + 𝑝 |
𝜃𝑝 𝜃𝑧
−𝑝 −𝑧 Re 𝑠+𝑧 𝑟𝑧 𝑗(𝜃 −𝜃 )
= 𝑒 𝑧 𝑝
𝑠+𝑝 𝑟𝑝
complex plane
Phase
Magnitude
8
D(s)
R(s) +
C(s)
+
-
Controller + Plant
9
Characteristic Equation
R(s) C(s) C (s ) KG (s )
+- K G(s) =
R(s ) 1 + KG (s )H (s )
H(s) Closed-loop
characteristic equation
10
Required Conditions
CE: 1 + KG(s)H(s) = 0
𝑁 𝑠 𝑁 𝑠
𝐾 = 1𝑒 ±𝑗(𝜋±2𝑞𝜋) 𝐾 𝑒𝑗 ∠𝑁−∠𝐷
= 1𝑒 ±𝑗(𝜋±2𝑞𝜋)
𝐷(𝑠) 𝐷(𝑠)
12
Infinity Open-Loop Zeros
𝑠 + 𝑧1 𝑠 + 𝑧2 … 𝑠 + 𝑧𝑚
1+𝐾 =0
𝑠 + 𝑝1 𝑠 + 𝑝2 … (𝑠 + 𝑝𝑛 )
𝑠 + 𝑧1 𝑠 + 𝑧2 … 𝑠 + 𝑧𝑚
𝐾 = 1𝑒 −𝑗𝜋(1+2𝑞)
𝑠 + 𝑝1 𝑠 + 𝑝2 … (𝑠 + 𝑝𝑛 )
𝑠 + 𝑧1 𝑠 + 𝑧2 … 𝑠 + 𝑧𝑚
∠ = ±𝜋
𝑠 + 𝑝1 𝑠 + 𝑝2 … (𝑠 + 𝑝𝑛 )
𝑚 𝑛
-p3
−𝜃 ∠ 𝑠 + 𝑧𝑖 − ∠ 𝑠 + 𝑝𝑗 = ±𝜋
… s + p3
s 𝑖=1 𝑗=1
s + p4
-p2 -z2 -p1 -z1 Re
𝜃
-p4 Angle contributions Angle contributions
from all OL zeros from all OL poles
Region 1
Ignore complex open-loop poles/zeros
Test point of s
Conjugate pairs cancel their angle
Starting points (OL POLES) contributions
16
Ending points (OL ZEROS)
Locus on the Real Axis
Im Phase Condition
𝑚 𝑛
∠ 𝑠 + 𝑧𝑖 − ∠ 𝑠 + 𝑝𝑗 = ±𝜋
𝑖=1 𝑗=1
∠ 𝑠 + 𝑧𝑖 = ∠ 𝑠 + 𝑝𝑗 = 0
… s+p2→ ∠ 𝑠 + 𝑝2 = 0 s
No locus in Region 1!
Region 1
Test point of s
∠ 𝑠 + 𝑧𝑖 − ∠ 𝑠 + 𝑝𝑗 = ±𝜋
𝑖=1 𝑗=1
Only vector ∠ 𝑠 + 𝑧1 = 𝜋
Region 2
Region 2: LHS angles = 𝜋 = RHS
Test point of s
∠ 𝑠 + 𝑧𝑖 − ∠ 𝑠 + 𝑝𝑗 = ±𝜋
𝑖=1 𝑗=1
∠ 𝑠 + 𝑧𝑖 − ∠ 𝑠 + 𝑝𝑗 = ±𝜋
𝑖=1 𝑗=1
Locus in Region 4!
Test point of s
∠ 𝑠 + 𝑧𝑖 − ∠ 𝑠 + 𝑝𝑗 = ±𝜋
𝑖=1 𝑗=1
…
Regions with odd number of
-p2 -z2 -p1 -z1 Re and that are on the right of
will satisfy the phase condition
3𝜋 Finding Asymptote
𝜋
2 2 𝜋(1 + 2𝑞)
Angle: ∠𝑠 =
3−1
-5 -3 -2 -1 -0.5 Re 𝜋 3𝜋
∠𝑠 = , , 𝑞 = 0, 1
2 2
−1 − 2 − 3 − (−5)
Location: 𝜎𝑎 = = −0.5
3−1
rejected because
not on locus
rejected because
not on locus
Asymptote
𝜋(1 + 2𝑞)
𝜋 Angle: ∠𝑠 =
2−1
∠𝑠 = 𝜋, 𝑞=0
-3 -2 -1 Re
−1 − 2 − (−3)
Location: 𝜎𝑎 = =0
2−1
𝑠+1 𝑠+2
𝐾=−
𝑠+3
𝑑𝐾
= 0 (max and min point)
-3 -2 -1 Re 𝑑𝑠
→ 𝑠 = −1.58, −4.41
-4 -1 0.5 Re 𝜋 3𝜋
3𝜋 ∠𝑠 = , , 𝑞 = 0, 1
2 2
2
−1 − 1 − 1 − (−4)
-1-j Location: 𝜎𝑎 = = 0.5
3−1
𝑑𝐾
-4 -1 0.5 Re =0
𝑑𝑠
No break-out points
-1-j
Phase: ∠ 𝑠 + 𝑧𝑖 − ∠ 𝑠 + 𝑝𝑗 = ±𝜋
−1
1 𝜋 𝑖=1 𝑗=1
tan
3 2
-4 -1 0.5 Re 1 𝜋 𝜋
tan−1 − − − 𝛼 = −𝜋
3 2 2
𝜋
2 1
-1-j 𝛼= tan−1
3
(−3𝜔2 + 2 + 4𝐾 ) + 𝑗( 4 + 𝐾 𝜔 − 𝜔3 ) = 0
-1-j
−𝜔
Real parts Imaginary parts
𝑑𝐾
-5 -1 Re =0
𝑑𝑠
1 Phase: ∠ 𝑠 + 𝑧𝑖 − ∠ 𝑠 + 𝑝𝑗 = ±𝜋
tan−1 𝜋 𝑖=1 𝑗=1
4 2
𝜋 𝜋 −1
1
-5 -1 Re + 𝛼 − − tan =𝜋
2 2 4
𝜋
1
2 𝛼=𝜋+ tan−1
4
-1-j
Phase: ∠ 𝑠 + 𝑧𝑖 − ∠ 𝑠 + 𝑝𝑗 = ±𝜋
𝑖=1 𝑗=1
𝜋 𝜋 −1
1
-5 -1 Re + 𝛼 − − tan =𝜋
2 2 4
1
𝛼=𝜋+ tan−1
4
-1-j
35
MATLAB Functions
Explore root locus with MATLAB:
𝑠+2
The mathematical expression of G is: 𝐺 𝑠 = 5𝑠 2 + 6𝑠 + 7
36
D(s)
R(s) +
C(s)
+
-
Controller + Plant
1
Teaching Plan
Week Lecture Topics Tutorial
2
Root Locus
R(s)
C (s ) KG (s )
C(s)
+- K G(s)
=
R(s ) 1 + KG (s )H (s )
Controller Plant
H(s)
Sensor
Key Question
Could we use the root locus technique if Controller ≠ 𝐾?
Answer: Yes
3
Basic Controllers
R(s) C(s)
+- E Gc A G(s)
Controller Plant
H(s)
Sensor
PD Controller PI Controller
Time Domain
d𝑒 𝑡
𝑎 = 𝐾𝑝 𝑒 + 𝐾𝐷 𝑎 = 𝐾𝑝 𝑒 + 𝐾𝐼 න 𝑒 d𝑡
d𝑡 0
Laplace Domain
𝐾𝐼
𝐴 = 𝐾𝑝 𝐸 + 𝐾𝐷 𝑠𝐸 𝐴 = 𝐾𝑝 𝐸 + 𝐸
𝑠
= 𝐸 𝐾𝑝 + 𝐾𝐷 𝑠 𝐾𝐼
= 𝐸 𝐾𝑝 +
𝑠
𝐺𝑐 for PD 𝐺𝑐 for PI
4
Root Locus for PD Controller
R(s) C(s)
+ Kp +𝐾𝐷 𝑠 G(s)
- 𝐾𝑝
PD Controller Plant PD controller: 𝐾𝐷 𝑠 + 𝐾𝑝 = 𝐾𝐷 𝑠+
𝐾𝐷
H(s)
Sensor 𝑧𝑐
For example
jw
G1(s)
R(s) C(s)
+ KD (𝑠 + 𝑧𝑐 ) G(s)
-
s
H(s)
s-plane 5
Root Locus for PD Controller
R(s) C(s)
+ Kp +𝐾𝐷 𝑠 G(s)
- 𝐾𝑝
PD Controller Plant PD controller: 𝐾𝐷 𝑠 + 𝐾𝑝 = 𝐾𝐷 𝑠+
𝐾𝐷
H(s)
Sensor 𝑧𝑐
For example
jw
G1(s)
R(s) C(s)
+ KD (𝑠 + 𝑧𝑐 ) G(s)
-
-zc s
H(s)
KD and zc change
closed-loop poles s-plane 6
Root Locus for PI Controller
R(s) 𝐾 C(s)
𝑧𝑐
+
-
𝐾𝑝 + 𝑠𝐼 G(s)
𝐾𝐼
𝑠+
PI Controller Plant 𝐾𝐼 𝐾𝑝
H(s)
PI controller: 𝐾𝑝 + 𝑠 = 𝐾𝑝 𝑠
Sensor
For example
jw
G1(s)
R(s) 𝑠 + 𝑧𝑐 C(s)
+ Kp G(s)
- 𝑠
s
H(s)
s-plane 7
Root Locus for PI Controller
R(s) 𝐾 C(s)
𝑧𝑐
+
-
𝐾𝑝 + 𝑠𝐼 G(s)
𝐾𝐼
𝑠+
PI Controller Plant 𝐾𝐼 𝐾𝑝
H(s)
PI controller: 𝐾𝑝 + 𝑠 = 𝐾𝑝 𝑠
Sensor
For example
jw
G1(s)
R(s) 𝑠 + 𝑧𝑐 C(s)
+ Kp G(s)
- 𝑠
-zc s
H(s)
PI controller eliminates
steady-state error s-plane 8
Comparison
PD controller PI controller
Increase speed + stability Eliminate Ess
Transient Response Steady-state Response
Controllers 𝐾𝐼
𝐾𝑝 𝐾𝐷 𝑠
𝑠
Properties Proportional Derivative Integral
Stability
Noise rejection
9
Improving Transient
Response
10
Design of PD Controllers
R(s) C(s) Recall: closed-loop poles define
+ Kp+KDs G(s)
- transient response!
PD Controller Plant
H(s) Aim: Find Kp and KD to achieve
Sensor desired closed-loop poles
General Steps
Step 1: Determine the DESIRED closed-loop poles
Step 4: Solve the real and imaginary parts of the characteristic equation to
obtain the required Kp and KD
11
Example: Step 1
R(s) 1 C(s)
+ Kp+KDs Desired Transient Response
-
𝑠 2 + 2𝑠 + 2
10% overshoot,
2% settling time of 0.5 s
Step 1: Determine the DESIRED closed-loop poles
Criterion 1: 10% OS Criterion 2: 2% settling time
−
𝜋𝜁 4
𝑒 1−𝜁 2 = 0.1 = 0.5
𝜁𝜔𝑛
𝜋𝜁 4
− = ln 0.1 = 0.5
1 − 𝜁2 (0.59)𝜔𝑛
4
ln 0.1 2 𝜔𝑛 = = 13.5
𝜁= = 0.59 (0.59) (0.5)
ln 0.1 2 + 𝜋 2
𝐾𝑝 + 𝐾𝐷 𝑠
𝐺cl =
𝑠 2 + (2 + 𝐾𝐷 )𝑠 + (2 + 𝐾𝑝 )
Characteristic equation: 𝑠 2 + 2 + 𝐾𝐷 𝑠 + 2 + 𝐾𝑝 = 0
13
Example: Steps 3 & 4
R(s) 1 C(s)
+
-
Kp+KDs Desired Poles: 𝑠 = −8 ± 11𝑗
𝑠 2 + 2𝑠 + 2
CE: 𝑠 2 + 2 + 𝐾𝐷 𝑠 + 2 + 𝐾𝑝 = 0
Step 4: Solve the real and imaginary parts of the characteristic equation
𝐾𝐷 = 14, 𝐾𝑝 = 183
𝐾𝑝 + 𝐾𝐷 𝑠 = 183 + 14𝑠 = 14(𝑠 + 13.1) 14
Example: Root Locus
R(s) 1 C(s)
+
-
𝐾𝑝 +𝐾𝐷 𝑠 𝐾𝑝 + 𝐾𝐷 𝑠 = 14(𝑠 + 13.1)
𝑠 2 + 2𝑠 + 2
Desired Poles: 𝑠 = −8 ± 11𝑗
PD controller Im
-8+11j
P Controller Characteristic Equation
𝐾𝑝 -1+j
1+ 2 =0
𝑠 + 2𝑠 + 2 Re
-13.1
-1- j
PD Controller Characteristic Equation
-8-11j
𝐾𝐷 (𝑠 + 13.1)
1+ 2 =0
𝑠 + 2𝑠 + 2
𝐾𝐷 = 14 S-plane
15
Drawbacks of PD Controllers
PD controller: 𝐺𝑐 = 𝐾𝐷 𝑠 + 𝐾𝑝 = 𝐾𝐷 (𝑠 + 𝑧𝑐 )
lim |𝐺𝑐 𝑠 = 𝑗𝜔 |
Noise Amplification: 𝜔→∞
= lim 𝐾𝐷 𝑗𝜔 + 𝑧𝑐 →∞
𝜔→∞
16
Lead Compensator
R(s) 1 C(s) 𝑠 + 𝑧𝑐
+ 𝐺𝑐 𝐺𝑐 = 𝐾
-
𝑠 2 + 2𝑠 + 2 𝑠 + 𝑝𝑐
Additional pole
lim |𝐺𝑐 𝑠 = 𝑗𝜔 |
Noise Amplification: 𝜔→∞
𝐾 𝑗𝜔 + 𝑧𝑐
= lim
𝜔→∞ (𝑗𝜔 + 𝑝𝑐 )
𝐾 𝑗𝜔
= lim =𝐾
𝜔→∞ (𝑗𝜔)
General Steps
Step 1: Design the desired transient response with a PD controller
𝐾𝐷 𝑠 + 𝐾𝑝 = 𝐾𝐷 (𝑠 + 𝑧𝑐′ )
Step 2: Using the obtained PD controller, specify a value of zc such that:
𝑧𝑐 < 𝑧𝑐′
Step 3: Use the characteristic equation to determine
𝐾, 𝑝𝑐
18
Example: Steps 1 and 2
R(s) 𝑠 + 𝑧𝑐 1 C(s)
+ 𝐾
- (𝑠 + 𝑝𝑐 ) 𝑠 2 + 2𝑠 + 2
Lead compensator
Desired Poles: 𝑠 = −8 ± 11𝑗
𝐾𝐷 𝑠 + 𝐾𝑝 = 14 𝑠 + 13.1 = 𝐾𝐷 (𝑠 + 𝑧𝑐′ )
𝑧𝑐 < 𝑧𝑐′ → 𝑧𝑐 = 10
𝑠 + 10
Lead compensator: 𝐾
(𝑠 + 𝑝𝑐 )
19
Example: Step 3
R(s) 𝑠 + 10 1 C(s)
+ 𝐾
- (𝑠 + 𝑝𝑐 ) 𝑠 2 + 2𝑠 + 2
Lead compensator
Desired Poles: 𝑠 = −8 ± 11𝑗
Characteristic Equation: 1 + 𝐺𝑐 𝐺 = 0
𝑠 + 10 1
1+𝐾 2
=0
(𝑠 + 𝑝𝑐 ) 𝑠 + 2𝑠 + 2
(𝑠 + 𝑝𝑐 )(𝑠 2 + 2𝑠 + 2) + 𝐾 𝑠 + 10 = 0
𝑠 3 + (2 + 𝑝𝑐 )𝑠 2 + (2 + 2𝑝𝑐 + 𝐾)𝑠 + (10𝐾 + 2𝑝𝑐 ) = 0
20
Example: Step 3 (cont)
R(s) 𝑠 + 10 1 C(s)
+ 𝐾
- (𝑠 + 𝑝𝑐 ) 𝑠 2 + 2𝑠 + 2
Lead compensator
Desired Poles: 𝑠 = −8 ± 11𝑗
-8+11j Im
PD Controller Characteristic Equation
14(𝑠 + 13.1) 1
1+ 2 = 0,
𝑠 + 2𝑠 + 2 -1+j
(𝑠 + 13.1) (𝑠 + 13.1)
14 2 = 1𝑒 𝑗𝜋 → ∠ =𝜋 -13.1 2 Re
𝑠 + 2𝑠 + 2 2
𝑠 + 2𝑠 + 2
-1- j
2
→ ∠ 𝑠 + 13.1 − ∠ 𝑠 + 2𝑠 + 2 = 𝜋
Phase condition
𝛼 − 𝛽1 − 𝛽2 = 𝜋 S-plane
22
Example: S-plane
R(s) 669 𝑠 + 10 1 C(s)
+
- 𝑠 + 50.7 𝑠 2 + 2𝑠 + 2 Desired Poles: 𝑠 = −8 ± 11𝑗
Lead compensator
-8+11j Im
Characteristic Equation
669 𝑠 + 10 1 1
1+ = 0,
𝑠 + 50.7 𝑠 2 + 2𝑠 + 2
3 new -1+j
𝛼new − 𝛽1 − 𝛽2 − 𝛽3 = 𝜋 S-plane
23
Improving Steady-State
Response
24
Design of PI Controllers
R(s) 𝐾𝐼 C(s)
+ 𝐾𝑝 + G(s)
- 𝑠
PI Controller Plant
H(s)
Sensor
Im
Characteristic Equation for Kp controller
𝑠+5
1 + 𝐾𝑝 2 = 0,
𝑠 + 8 𝑠 + 10
-10 -8 -5 Re
-11.5
26
Example: Root Locus
R(s) 𝑠+5 C(s)
+ Gc 2
- 𝑠 + 8 𝑠 + 10
Controller Plant
Im
Characteristic Equation for Kp controller
𝑠+5
1 + 𝐾𝑝 2 = 0,
𝑠 + 8 𝑠 + 10
PI controller
-11.5 -11.25
28
Lag Compensator ~ pole/zero
cancellation
R(s) C(s) 𝑠 + 𝑧𝑐
+
-
𝐺𝑐 𝐺 𝐺𝑐 = 𝐾
𝑠 + 𝑝𝑐
𝑝𝑐 ≪ 𝑧𝑐 ≪ 1
Objective: Enhance position error constant Kp
𝑠 + 𝑧𝑐
𝐾𝑝 = lim 𝐺𝑐 𝐺 = lim 𝐾 𝐺(𝑠)
𝑠→0 𝑠→0 𝑠 + 𝑝𝑐
𝑧𝑐
= 𝐾 𝐺(0) 𝑧
𝐾 𝑐 factor
𝑝𝑐 𝑝𝑐
1
𝑒𝑠𝑠 =
1 + 𝐾𝑝
1
𝑒𝑠𝑠 =
1 + 𝐾𝑝
Uncompensated
Lag compensator
31
PID Controllers
R(s) E(s) 𝐾𝐼 A(s) C(s)
+- 𝐾𝑝 + 𝐾𝐷 𝑠 +
𝑠
G(s) Time Domain
𝑡
PID Controller d𝑒
𝑎 = 𝐾𝑝 𝑒 + 𝐾𝐷 + 𝐾𝐼 න 𝑒 d𝑡
d𝑡 0
H(s)
S-plane Domain
𝐾𝐼 𝐾𝐷 𝑠 2 + 𝐾𝑝 𝑠 + 𝐾𝐼 𝐾𝐷 𝑠 + 𝑧1 𝑠 + 𝑧2
PID: 𝐾𝑝 + 𝐾𝐷 𝑠 + = =
𝑠 𝑠 𝑠
𝑠 + 𝑧2
= 𝐾𝐷 𝑠 + 𝑧1
𝑠
PD controller PI controller
32
Lead-Lag Compensators
R(s) 𝐾1 𝑠 + 𝑧1 𝐾2 𝑠 + 𝑧2 C(s)
+ (𝑠 + 𝑝1 ) (𝑠 + 𝑝2 ) G(s)
-
Lead-lag compensator
H(s)
𝐾1 𝑠 + 𝑧1 𝐾2 𝑠 + 𝑧2
Lead-lag compensator:
(𝑠 + 𝑝1 ) (𝑠 + 𝑝2 )
33
Summary
Active Passive
Transient Response PD Lead
Steady-state Response PI Lag
Transient and steady-state PID Lead-Lag
34
D(s)
R(s) +
C(s)
+
-
Controller + Plant
1
Teaching Plan
Week Lecture Topics Tutorial
2
Harmonic Inputs
Time Domain
𝑅(𝑠) 𝐶(𝑠)
𝐺(𝑠) Input: 𝑟 = 𝑟0 cos 𝜔𝑡
Transfer
Function Steady-state: 𝑐 = 𝑟0 |𝐺 𝑠 = 𝑗𝜔 | cos 𝜔𝑡 + ∠𝐺 𝑠 = 𝑗𝜔
1
Output 0.5
0
-1
-2
-3 3
T time
Example
𝑅(𝑠) 2 𝐶(𝑠)
𝑠+2
Transfer Function
2 2 2 −𝑗(tan −1 5)
𝐺 𝑠 = 10𝑗 = = −1 5) = 𝑒
10𝑗 + 2 104𝑒 𝑗(tan 104
𝑐𝑠𝑠 𝑡 = 𝑟0 𝐺 𝑠 = 𝑗𝜔 cos(10𝑡 + ∠𝐺 𝑠 = 𝑗𝜔 )
2
− tan−1 5
104 4
Bode Plot
𝑅(𝑠) 𝐶(𝑠)
𝐺(𝑠) Frequency response of the
Transfer
transfer function
Function
20 lg 𝐺 (dB)
1. Magnitude plot
One decade
20log10(|𝐺(𝑠 = 𝑗)|) against lg 𝜔
x-axis is lg 𝜔
∠𝐺 (degrees)
2. Phase plot
∠𝐺(𝑠 = 𝑗) against lg 𝜔
rad
𝜔( ) 5
𝑠
Motivation
1. Together with Fourier series analysis, it can compute the output of periodic inputs
▪ Example, 𝑟 = 2 sin 3𝑡 + 6 cos 100𝑡 + 𝜋
2. Analysis:
▪ Resonance
▪ Filtering
4. Reverse engineering:
▪ Identify the transfer function of the system
6
D(s)
R(s) +
C(s)
+
-
Controller + Plant
7
Superposition Principle (I)
Objective: Plot two log-scale plots
𝑅(𝑠) 𝐶(𝑠) ς𝑛𝑖=1(𝑠 + 𝑧𝑖 )
𝐺(𝑠) 𝐺 𝑠 =𝐾 𝑚
ς𝑗=1(𝑠 + 𝑝𝑗 )
Transfer Function
Frequency Response
𝑗tan −1 (𝜔 )
𝐺 𝑠 = 𝑗𝜔 = 𝐾 𝑚 =𝐾 𝜔
ς𝑗=1(𝑗𝜔 + 𝑝𝑗 ) ς𝑚
𝑗tan−1 ( )
𝑝𝑗
𝑗=1 𝜔2 + 𝑝𝑗2 𝑒
ς𝑛𝑖=1 𝜔 2 + 𝑧𝑖2 −1 𝜔 −1 𝜔
𝑗 σ𝑛 𝑚
𝑖=1 tan (𝑧 )−σ𝑗=1 tan (𝑝 )
=𝐾 𝑒 𝑖 𝑗
ς𝑚
𝑗=1 𝜔 2 + 𝑝𝑗2
∠𝐺(𝑠 = 𝑗)
|𝐺(𝑠 = 𝑗)| 8
Superposition Principle (II)
Transfer function ∠𝑮 (Phase)
𝑛 𝑚
ς𝑛𝑖=1(𝑠 + 𝑧𝑖 ) 𝜔 𝜔
𝐺 𝑠 =𝐾 𝑚 tan−1 − tan −1
𝑧𝑖 𝑝𝑗
ς𝑗=1(𝑠 + 𝑝𝑗 ) 𝑖=1 𝑗=1
Linear combination of angles
𝑮 (Magnitude)
ς𝑛𝑖=1 ς𝑛𝑖=1 𝜔 2 + 𝑧𝑖2
𝜔2 + 𝑧𝑖2 Log-scale
𝐾 20 lg 𝐾
ς𝑚 ς𝑚 𝜔 2 + 𝑝𝑗2
𝑗=1 𝜔 2 + 𝑝𝑗2 𝑗=1
𝑛 𝑚
𝑎
4. First order systems
𝑠+𝑎
2
𝜔𝑛
5. Second order systems 2
𝑠+2𝜁𝜔𝑛 𝑠+𝜔𝑛
10
20 lg 𝐺 (dB)
Plotting Constants
𝑅(𝑠) 𝐶(𝑠)
20 lg 𝐾 𝐾
Transfer Function
𝐺 𝑠 = 𝑗𝜔 = 𝐾𝑒 𝑗0
∠𝐺 (rad)
Magnitude
20 lg |𝐺 𝑗𝜔 | = 20 lg 𝐾
0.01 0.1 1 10 100 𝜔(rad/s)
Phase
∠𝐺 𝑗𝜔 = 0
11
20 lg 𝐺 (dB)
Plotting Differentiator
+20 dB/dec 𝑅(𝑠) 𝐶(𝑠)
𝑠
Transfer Function
𝑅(𝑠) 𝑎
𝐶(𝑠)
𝑠+𝑎
Transfer Function
𝑅(𝑠) 𝑎
𝐶(𝑠)
𝑠+𝑎
Transfer Function
𝑎
0.01 0.1 1 𝑎 10 100 𝜔(rad/s) 𝐺 𝑠 = 𝑗𝜔 =
𝑗𝜔 + 𝑎
−20 dB/dec
𝜔(rad/s)
∠𝐺 (degrees)
−45°/dec
16
𝜔(rad/s)
Plotting First Order Zero (I)
20 lg 𝐺 (dB)
𝑅(𝑠) 𝑠 + 𝑎 𝐶(𝑠)
𝑎
Transfer Function
𝜔(rad/s) 𝑗𝜔 + 𝑎
𝐺 𝑠 = 𝑗𝜔 =
0.01 0.1 1 𝑎 10 100 𝑎
When << a
𝑎
∠𝐺 (rad) 𝐺 𝑠 = 𝑗𝜔 = = 1𝑒 𝑗0
𝑎
Magnitude
20 lg |𝐺 𝑗𝜔 | = 0
0.01 0.1 0.1𝑎 1 𝑎 10 10𝑎 100 𝜔(rad/s)
Phase
∠𝐺 𝑗𝜔 = 0
17
Plotting First Order Zero (II)
20 lg 𝐺 (dB)
𝑅(𝑠) 𝑠 + 𝑎 𝐶(𝑠)
+20 dB/dec 𝑎
Transfer Function
𝜔(rad/s) 𝑗𝜔 + 𝑎
𝐺 𝑠 = 𝑗𝜔 =
0.01 0.1 1 𝑎 10 100 𝑎
When >> a
𝑗𝜔 𝜔 𝑗(𝜋)
∠𝐺 (rad) 𝐺 𝑠 = 𝑗𝜔 = = 𝑒 2
𝜋 𝑎 𝑎
𝜋
2 + rad/dec
𝜋 4 Magnitude
4
𝜔
20 lg |𝐺 𝑗𝜔 | = 20 lg
𝑎
0.01 0.1 0.1𝑎 1 𝑎 10 10𝑎 100 𝜔(rad/s)
= 20 lg 𝜔 − 20 lg 𝑎
Phase
𝜋
∠𝐺 𝑗𝜔 = 18
2
First Order Zero: Example
𝑅(𝑠) 𝑠 + 10 𝐶(𝑠) 𝑎 = 10
Corner Frequencies
10
Transfer Function 𝜔 = 1, 10, 100
20 lg 𝐺 (dB)
+20 dB/dec
𝜔(rad/s)
∠𝐺 (degrees)
+45°/dec
19
𝜔(rad/s)
Plotting Second Order Pole (I)
20 lg 𝐺 (dB)
𝑅(𝑠) 𝜔𝑛2 𝐶(𝑠)
𝑠 2 + 2𝜁𝜔𝑛 𝑠 + 𝜔𝑛2
Transfer Function
𝜔(rad/s)
𝜔𝑛2
0.01 0.1 1 𝜔𝑛 10 100 𝐺 𝑠 = 𝑗𝜔 =
−𝜔 2 + 𝑗2𝜁𝜔𝑛 𝜔 + 𝜔𝑛2
When << n
𝜔𝑛2
∠𝐺 (rad) 𝐺 𝑠 = 𝑗𝜔 = 2 = 1𝑒 𝑗0
𝜔𝑛
Magnitude
0.01 0.1 0.1𝜔𝑛 1 𝜔𝑛 10 10𝜔𝑛 100 𝜔(rad/s) 20 lg |𝐺 𝑗𝜔 | = 0
Phase
∠𝐺 𝑗𝜔 = 0
20
Plotting Second Order Pole (II)
20 lg 𝐺 (dB)
𝑅(𝑠) 𝜔𝑛2 𝐶(𝑠)
𝑠 2 + 2𝜁𝜔𝑛 𝑠 + 𝜔𝑛2
Transfer Function
𝜔(rad/s)
𝜔𝑛2
0.01 0.1 1 𝜔𝑛 10 100 𝐺 𝑠 = 𝑗𝜔 =
−𝜔 2 + 𝑗2𝜁𝜔𝑛 𝜔 + 𝜔𝑛2
−40 dB/dec When >> n
𝜔𝑛2 𝜔𝑛2 𝑗(−𝜋)
∠𝐺 (rad) 𝐺 𝑠 = 𝑗𝜔 = 2
= 2𝑒
−𝜔 𝜔
Magnitude 2
𝜔𝑛
𝜋 0.01 0.1 0.1𝜔𝑛 1 𝜔𝑛 10 10𝜔𝑛 100 𝜔(rad/s) 20 lg |𝐺 𝑗𝜔 | = 20 lg 2
−
𝜔
2 𝜋
− rad/dec
2 = 40 lg 𝜔𝑛 − 40 lg 𝜔
−𝜋
Phase 21
∠𝐺 𝑗𝜔 = −𝜋
Second Order Pole: Example
𝑅(𝑠) 1 𝐶(𝑠) 𝜔𝑛 = 1
Corner Frequencies
𝑠 2 + 2𝜁𝑠 + 1
Transfer Function 𝜔 = 0.1, 1, 10
20 lg 𝐺 (dB)
−40 dB/dec
∠𝐺 (degrees)
−90°/dec
22
Second Order Pole: Example
𝑅(𝑠) 1 𝐶(𝑠) 𝜔𝑛 = 1
Corner Frequencies
𝑠 2 + 2𝜁𝑠 + 1
Transfer Function 𝜔 = 0.1, 1, 10
20 lg 𝐺 (dB)
𝜁 = 0.01
𝜁 = 0.1
𝜁 = 0.3
𝜔(rad/s)
∠𝐺 (degrees)
𝜁 = 0.01
𝜁 = 0.1
𝜁 = 0.3
23
𝜔(rad/s)
Plotting Second Order Zero (I)
20 lg 𝐺 (dB)
𝑅(𝑠) 𝑠 2 + 2𝜁𝜔 𝑠 + 𝜔2 𝐶(𝑠)
𝑛 𝑛
𝜔𝑛2
Transfer Function
−𝜔2 + 𝑗2𝜁𝜔𝑛 𝜔 + 𝜔𝑛2
0.01 0.1 1 𝜔𝑛 10 100 𝐺 𝑠 = 𝑗𝜔 =
𝜔𝑛2
𝜔(rad/s)
When << n
𝜔𝑛2
∠𝐺 (rad) 𝐺 𝑠 = 𝑗𝜔 = 2 = 1𝑒 𝑗0
𝜔𝑛
Magnitude
0.01 0.1 0.1𝜔𝑛 1 𝜔𝑛 10 10𝜔𝑛 100 20 lg |𝐺 𝑗𝜔 | = 0
𝜔(rad/s)
Phase
∠𝐺 𝑗𝜔 = 0
24
Plotting Second Order Zero (II)
20 lg 𝐺 (dB)
𝑅(𝑠) 𝑠 2 + 2𝜁𝜔 𝑠 + 𝜔2 𝐶(𝑠)
𝑛 𝑛
+40 dB/dec 𝜔𝑛2
Transfer Function
−𝜔2 + 𝑗2𝜁𝜔𝑛 𝜔 + 𝜔𝑛2
0.01 0.1 1 𝜔𝑛 10 100 𝐺 𝑠 = 𝑗𝜔 =
𝜔𝑛2
𝜔(rad/s)
When >> n
−𝜔2 𝜔2 𝑗𝜋
∠𝐺 (rad) 𝐺 𝑠 = 𝑗𝜔 = 2 = 2 𝑒
𝜋 𝜔𝑛 𝜔𝑛
𝜋 𝜋
2
+
2
rad/dec Magnitude
0.01 0.1 0.1𝜔𝑛 1 𝜔𝑛 10 10𝜔𝑛 100
𝜔2
20 lg |𝐺 𝑗𝜔 | = 20 lg 2
𝜔(rad/s)
𝜔𝑛
= 40 lg 𝜔 − 40 lg 𝜔𝑛
Phase
25
∠𝐺 𝑗𝜔 = 𝜋
Second Order Zero: Example
𝑅(𝑠) 𝑠 + 2𝜁𝑠 + 1 𝐶(𝑠) 𝜔𝑛 = 1
Corner Frequencies
1
Transfer Function 𝜔 = 0.1, 1, 10
20 lg 𝐺 (dB)
∠𝐺 (degrees)
26
Second Order Zero: Example
𝑅(𝑠) 𝑠 + 2𝜁𝑠 + 1 𝐶(𝑠) 𝜔𝑛 = 1
Corner Frequencies
1
Transfer Function 𝜔 = 0.1, 1, 10
20 lg 𝐺 (dB)
𝜁 = 0.3 𝜁 = 0.1
𝜁 = 0.01
∠𝐺 (degrees)
𝜁 = 0.1
𝜁 = 0.3
27
D(s)
R(s) +
C(s)
+
-
Controller + Plant
28
Complex Function: Asymptotes
20 lg 𝐺 (dB)
+20 dB/dec
+20 dB/dec
−20 dB/dec
20
Generate Bode plot:
0.01 0.1 1 10 100 1000
−20 𝜔(rad/s)
1000𝑠
−40 𝐺=
𝑠 2 + 𝑠 + 100
−40 dB/dec
∠𝐺 (rad) 1000 100
𝐺= (𝑠) 2
100 𝑠 + 𝑠 + 100
𝜋
2 𝜔(rad/s)
0.01 0.1 1 10 100 1000
π
−𝜋 − rad/dec
2
29
Complex Function: Sketch
20 lg 𝐺 (dB)
+20 dB/dec
−20 dB/dec
30
Complex Function: MATLAB
20 lg 𝐺 (dB)
𝜔(rad/s)
∠𝐺 (deg)
𝜔(rad/s)
31
Complex Function: Reading
𝑅(𝑠) 𝐶(𝑠)
𝐺(𝑠)
Transfer Function
𝑐 𝑡 = 2|𝐺 𝑠 = 𝑗 | cos(𝑡 + ∠𝐺 𝑠 = 𝑗 )
32
Complex Function: MATLAB
20
20 lg 𝐺 (dB)
𝐺 = 1020 = 10 60 dB
60
20 dB 𝐺 = 1020 = 1000
𝜔(rad/s)
𝜋 0 rad
∠𝐺 (deg)
rad
2
𝜔(rad/s)
33
Complex Function: Reading
𝑅(𝑠) 𝐶(𝑠)
𝐺(𝑠)
Transfer Function
𝑐 𝑡 = 2|𝐺 𝑠 = 𝑗 | cos(𝑡 + ∠𝐺 𝑠 = 𝑗 )
𝜋
10
2
+5|𝐺 𝑠 = 10𝑗 | cos(10𝑡 + ∠𝐺 𝑠 = 10𝑗 )
1000 0
𝜋
𝑐 𝑡 = 20 cos(𝑡 + ) + 5000 cos(10𝑡) 34
2
Summary
1. Bode plot is the frequency response of the system
a) Read the bode plot
2. Sketching techniques
a) Superposition principle
b) Sketch the principal components
c) Combine all the components together
35
D(s)
R(s) +
C(s)
+
-
Controller + Plant
1
Teaching Plan
Week Lecture Topics Tutorial
2
Bode Plot Recap
𝑅(𝑠) 𝐶(𝑠)
𝐺(𝑠) Frequency response of the
Transfer
transfer function
Function
20 lg 𝐺 (dB)
1. Magnitude plot
One decade
20log10(|𝐺(𝑠 = 𝑗)|) against lg 𝜔
x-axis is lg 𝜔
∠𝐺 (degrees)
2. Phase plot
∠𝐺(𝑠 = 𝑗) against lg 𝜔
rad
𝜔( ) 3
𝑠
D(s)
R(s) +
C(s)
+
-
Controller + Plant
4
Second Order System
𝑅(𝑠) 1 𝐶(𝑠) 𝜔𝑛 = 1
Corner Frequencies
𝑠 2 + 2𝜁𝑠 + 1
Transfer Function 𝜔 = 0.1, 1, 10
20 lg 𝐺 (dB)
𝜁 = 0.01
𝜁 = 0.1
𝜁 = 0.3
𝜔(rad/s)
∠𝐺 (degrees)
𝜁 = 0.01
𝜁 = 0.1
𝜁 = 0.3
5
𝜔(rad/s)
Second Order System
𝑅(𝑠) 1 𝐶(𝑠) 𝜔𝑛 = 1
Corner Frequencies
𝑠 2 + 2𝜁𝑠 + 1
Transfer Function 𝜔 = 0.1, 1, 10
20 lg 𝐺 (dB)
Resonance frequency 𝜔𝑟
𝜔𝑟 = 𝜔𝑛 1 − 2𝜁 2
𝜔(rad/s)
∠𝐺 (degrees)
𝜁 = 0.01
𝜁 = 0.1
𝜁 = 0.3
6
𝜔(rad/s)
D(s)
R(s) +
C(s)
+
-
Controller + Plant
7
𝑋 dB
Low-Pass Filter
20 lg |𝐺| (dB)
𝑋 − 3 dB line
Pass band No pass band
𝜔c = 20
𝜔 (rad/s)
≪ 𝐺 𝑠 = 𝑗𝜔low , 𝜔 ≥ 𝜔𝑐
𝐺 𝑠 = 𝑗𝜔 =ቊ
~ 𝐺 𝑠 = 𝑗𝜔low , 𝜔 < 𝜔𝑐 8
High-Pass Filter
𝑋 dB
20 lg |𝐺| (dB)
𝑋 − 3 dB line
𝜔 (rad/s)
~ 𝐺 𝑠 = 𝑗𝜔high , 𝜔 ≥ 𝜔𝑐
𝐺 𝑠 = 𝑗𝜔 =ቐ 9
≪ 𝐺 𝑠 = 𝑗𝜔high , 𝜔 < 𝜔𝑐
D(s)
R(s) +
C(s)
+
-
Controller + Plant
10
Reverse Engineering
AIM: Use the Bode plots to approximate the transfer function
63 dB
20 lg |𝐺| (dB)
𝜔=3
–60 dB/dec
No slope
𝜔 = 400
No differentiator
2nd order
and integrator –40 dB/dec
pole
0 degree 𝜔 (rad/s)
1st order zero
∠𝐺 (degree)
𝜔 = 0.3
180 deg
270 deg 𝜔 = 4000
𝜔 (rad/s)
Estimated transfer function
302 3 𝑠 + 400
𝐺 𝑠 = 2 𝐾 11
𝑠 + 2 0.01 30 𝑠 + 302 𝑠+3 400
Reverse Engineering (cont..)
Estimated transfer function DC gain from plot
900𝐾 3 𝑠 + 400
𝐺 𝑠 = 63.5 dB
𝑠 2 + 0.6𝑠 + 900 𝑠 + 3 400
63.5
20 lg |lim 𝐺 𝑠 | = 63.5 |lim 𝐺 𝑠 | = 10 20
𝑠→0 𝑠→0
Estimated Actual
10125(𝑠 + 400) 15000(𝑠 + 450)
𝐺 𝑠 = 𝐺 𝑠 =
(𝑠 2 + 0.6𝑠 + 900)(𝑠 + 3) (𝑠 2 + 𝑠 + 900)(𝑠 + 5)
12
Example
Use the Bode plots to approximate the transfer function
𝜔𝑟 = 11.5, ≈ 0.3
20 lg |𝐺| (dB)
-60 dB/dec
An integrator
𝜔 (rad/s)
∠𝐺 (degree)
-90 deg
-270 deg
𝜔 (rad/s)
Estimated transfer function
1
𝐺 𝑠 = 𝐺 𝐾 13
𝑠 1
Example (cont..)
Estimated transfer function r Low freq gain
1
𝐺 𝑠 = 𝐺 𝐾 11.5 rad ~0.3 16.5 dB
𝑠 1
Resonance Frequency Analysis
12.72
𝜔𝑟 = 𝜔𝑛 1 − 2𝜁 2 = 11.5 → 𝜔𝑛 = 12.7 → 𝐺1 = 2
𝑠 + 2 0.3 12.7 𝑠 + 12.72
Low Frequency Gain Analysis
16.5
20 lg |lim 𝐺 𝑠 | = 16.5 → |lim 𝐺 𝑠 | = 10 20
𝑠→𝑗 𝑠→𝑗
𝐾 161 16.5
→ = 10 20
𝑗 −1 + 7.6𝑗 + 161 → 𝐾 = 6.6
Estimated Actual
1065 1000
𝐺 𝑠 = 2 𝐺 𝑠 = 2
𝑠 + 7.6𝑠 + 161 𝑠 𝑠 + 5𝑠 + 150 𝑠
14
D(s)
R(s) +
C(s)
+
-
Controller + Plant
15
Closed-Loop Response
R(s) + C(s)
Gc(s) P(s)
- Controller Plant
G (open-loop)
16
Gain and Phase Margins
20 lg |𝐺| (dB)
𝛾 = +70° = 0 − 𝐺 𝑠 = 𝑗𝜔gm
dB
𝜔 (rad/s)
Phase Margin (Stable GOL)
Stability
1. Occurs at the frequency
Unity feedback is stable if and only if: when |𝐺| = 0 dB (𝜔pm )
𝛾 > 0 & GM > 0
2. Phase Margin (𝛾)
Closed-loop 𝜻𝐜𝐥 = ∠𝐺 𝑠 = 𝑗𝜔pm − (−𝜋)
17
𝛾 ↑ implies that 𝜁cl ↑
Bandwidth
𝑋 dB
20 lg |𝐺| (dB)
X-3 dB
𝜔BW = 16 rad/s
Bandwidth
𝜔 (rad/s)
The frequency when 𝐺 = 𝑋 − 3 dB.
∠𝐺 (degree)
We denote it as 𝜔BW
𝜔 (rad/s)
18
Steady-State Errors (Type 0)
20 lg |𝐺| (dB)
𝜔 (rad/s)
Type 0 Systems
1
Steady-state error ess (step inputs): 1 + 𝐾𝑝
0 dB line
ω𝑣 = 𝐾𝑣
𝜔 (rad/s)
Type 1 Systems
1
Steady-state error ess (ramp inputs): 𝐾𝑣
e.g., 𝐾𝑣 = 𝜔𝑣 = 21
1
𝑒𝑠𝑠 =
21
20
Steady-State Errors (Type 2)
−40 dB/dec
20 lg |𝐺| (dB)
0 dB line
ω𝑎 = 𝐾𝑎
𝜔 (rad/s)
Type 2 Systems
1
Steady-state error ess (parabolic inputs): 𝐾𝑎
2. Reverse engineering
22