Design goals: stable, fast, accurate
About this lesson
Every feedback loop is judged by three questions: does it settle (stable), how quickly does it get there (fast), and how close to the goal does it end (accurate)? Follow one room heater whose thermometer reading is 8 minutes old, and turn up the gain of a simple proportional rule: it gets faster and more accurate, until it starts to swing for ever.
Three questions for every loop
Any feedback loop is judged by three questions. Stable: does it settle down? Fast: how quickly does it get there? Accurate: how close to the goal does it end up? Our loop keeps a room at 20 °C.
stable does the output settle, or swing
for ever?
fast how quickly does it get close?
accurate how far from the goal does it
end up?
The example: a room, a heater (0 to 3 kW),
a thermometer and a proportional rule.
Goal 20 °C, outside 10 °C.Read the lesson step by step
Three questions for every loop
Any feedback loop is judged by three questions. Stable: does it settle down? Fast: how quickly does it get there? Accurate: how close to the goal does it end up? Our loop keeps a room at 20 °C.
stable does the output settle, or swing for ever? fast how quickly does it get close? accurate how far from the goal does it end up? The example: a room, a heater (0 to 3 kW), a thermometer and a proportional rule. Goal 20 °C, outside 10 °C.Every reading is old
The thermometer hangs far from the heater, so warm air takes 8 minutes to reach it. Every reading the controller gets is 8 minutes old. A delay like this is called dead time, and almost every real loop has some.
sensor thermometer across the room delay 8 min (dead time) reading at time t = room temperature at time t − 8 min The controller always acts on old news.A gentle rule: K = 0.1
The rule is proportional: power = K × error, kept between 0 and 3 kW. K, the gain, says how hard to push per °C of error. With a gentle K = 0.1, the room warms smoothly and levels off.
# K = 0.1: the reading is 8 min (80 updates) old import math TAU, R, K, goal = 40, 7.5, 0.1, 20.0 temp, log, dt = 10.0, [], 0.1 for n in range(1801): # 0 to 180 min log.append(temp) reading = log[max(0, n - 80)] power = min(max(K * (goal - reading), 0), 3) target = 10.0 + R * power temp = target + (temp - target) * math.exp(-dt / TAU) print(round(temp, 1)) # 14.3Stable: it settles
Stable means that after a push, the output settles to one steady value instead of swinging or running away. This loop is stable: by about 74 minutes it has settled for good.
stable yes settles at 14.3 °C settling time 74 min (from then on it stays within 2% of the way from 10 °C to 14.3 °C) Stability comes first: an unstable loop is useless however fast it is.Accurate: the gap at the end
It settles at 14.3 °C, not 20. The gap left once everything has settled is the steady-state error: 5.7 °C here. A proportional rule needs an error to make any heat, so a gentle K leaves a big gap.
steady-state error = goal − final = 20 − 14.3 = 5.7 °C To hold the room warm, the heater needs power, and K × error is the only power this rule makes. Small K → big error.Fast: the rise time
Speed is measured by the rise time: how long the output takes to go from 10% to 90% of the way to its final value. Here it takes 41 minutes. Stable, but slow and inaccurate.
rise time 10% → 90% of the way from 10 °C to 14.3 °C = 41 min K = 0.1 stable yes rise 41 min error 5.7 °CMore gain: K = 0.4
Four times the gain pushes harder on the same error. The rise time drops to 13 minutes and the room ends at 17.5 °C, only 2.5 °C short. More gain: faster and more accurate.
# K = 0.4: the reading is 8 min (80 updates) old import math TAU, R, K, goal = 40, 7.5, 0.4, 20.0 temp, log, dt = 10.0, [], 0.1 for n in range(1801): # 0 to 180 min log.append(temp) reading = log[max(0, n - 80)] power = min(max(K * (goal - reading), 0), 3) target = 10.0 + R * power temp = target + (temp - target) * math.exp(-dt / TAU) print(round(temp, 1)) # 17.5 K = 0.4 rise 13 min (was 41) error 2.5 °C (was 5.7)The first warning: overshoot
But the room now overshoots: it climbs to 18.2 °C, past where it ends up, then falls back. The old readings still said too cold, so the heater kept pushing. Overshoot warns that the loop is getting closer to instability.
peak 18.2 °C final 17.5 °C overshoot 9% of the rise The heater reacts to what the room was 8 minutes ago, so it stops too late. Still stable: it settles in 36 min.Too much gain: K = 1.5
At K = 1.5 the room never settles. It swings between 17.9 and 21.0 °C for ever, while the heater keeps hitting off and full power. This loop is unstable: it fails the first goal.
# K = 1.5: the reading is 8 min (80 updates) old import math TAU, R, K, goal = 40, 7.5, 1.5, 20.0 temp, log, dt = 10.0, [], 0.1 for n in range(1801): # 0 to 180 min log.append(temp) reading = log[max(0, n - 80)] power = min(max(K * (goal - reading), 0), 3) target = 10.0 + R * power temp = target + (temp - target) * math.exp(-dt / TAU) print(round(min(log[900:]), 1), round(max(log[900:]), 1)) # 17.9 21.0 Without the 0 to 3 kW limit the swings would grow without end.Why: pushing hard on old news
By the time a reading says too cold, the room is already warm, and a strong rule still blasts heat. Then it overshoots the other way. Above K = 1.13, each late correction is bigger than the error it chases.
gain limit for this room K = 1.13 kW/°C (where the 8 min delay plus the room's slow warming make a correction arrive half a swing late; at that gain one swing takes 30 min) K = 1.5 > 1.13 → unstable K = 0.4 < 1.13 → stableThe trade-off
More gain bought speed and accuracy but cost stability. With a proportional rule you cannot have all three. Choosing the balance is control design. Later lessons in this course add parts that get all three.
K stable rise error 0.1 yes 41 min 5.7 °C 0.4 yes 13 min 2.5 °C 1.5 no never settles limit K = 1.13: more gain → faster, more accurate, less stable.
5 quick questions
Choose one answer per question. You can change your choices before checking them.
01Which of the three design goals must a loop meet before the other two mean anything?
An unstable loop never settles, so it has no final value to be accurate about and no settling time to be fast about. Stability comes first.
02With K = 0.1 the room settles at 14.3 °C while the goal is 20 °C. What is the steady-state error?
Steady-state error is the goal minus where the output finally settles: 20 − 14.3 = 5.7 °C.
03What does the rise time measure?
Rise time is a speed measure: the time from 10% to 90% of the way from the start to the final value. The first option is overshoot, the third is steady-state error and the last is the delay.
04Going from K = 0.1 to K = 0.4, what happened to the loop?
The rise time fell from 41 to 13 minutes and the error from 5.7 to 2.5 °C, but the room overshot to 18.2 °C before settling.
05Why does K = 1.5 make this loop swing for ever?
With dead time in the loop, a strong rule keeps acting on old news. Above about K = 1.13 kW/°C each late correction is bigger than the error it chases, so the swings do not die away.
Glossary
- Stable
- A loop is stable if, after a change, its output settles to a steady value instead of swinging for ever or running away.
- Rise time
- How long the output takes to go from 10% to 90% of the way from its start to its final value. A measure of speed.
- Settling time
- How long until the output stays within a small band (here 2% of the change) around its final value.
- Overshoot
- How far the output goes past its final value before coming back, often given as a percentage of the change.
- Steady-state error
- The gap between the goal and where the output finally settles. A measure of accuracy.
- Gain (K)
- In a proportional rule, how much the controller pushes for each unit of error: here kW of heat per °C.
- Dead time (delay)
- A delay between something happening in the plant and the controller seeing it. Here every reading is 8 minutes old.
Notes and sources
- The room is a simple model with illustrative numbers: it heads towards the outside temperature plus 7.5 °C for every kW of heat, with a 40-minute time constant, and the thermometer's reading is 8 minutes old. Every curve and number in the figure is computed from that model.
- Rise time (10% to 90%), settling time (staying within 2% of the change, around the final value) and percent overshoot are the standard step-response measures in Nise's and Ogata's textbooks. They are defined more carefully, with formulas, in the Time response module of this course.
- The gain limit 1.13 kW/°C comes from the continuous-time model of this loop: it is where the delay plus the room's lag make a correction arrive half a swing late. The heater's 0 to 3 kW limits stop the K = 1.5 swings growing; without them they would grow for ever.
- The Python on each step is plain Python 3 with the math module. It updates the controller every 0.1 minutes with a reading 80 updates (8 minutes) old and moves the room forward with the exact solution of its equation between updates, just as the figure does.
- N. S. Nise, Control Systems Engineering, 8th ed., Wiley (ch. 1 design objectives; ch. 4 rise time, settling time, overshoot; ch. 7 steady-state error)
- K. Ogata, Modern Control Engineering, 5th ed., Pearson (ch. 4 thermal systems; ch. 5 transient and steady-state response; ch. 7 transport lag)
- G. F. Franklin, J. D. Powell, A. Emami-Naeini, Feedback Control of Dynamic Systems, 8th ed., Pearson (ch. 4 A First Analysis of Feedback; time delay in ch. 5 and 6)
- MIT OpenCourseWare 16.06 Principles of Automatic Control (S. Hall): performance measures, stability and degree of stability
- MIT OpenCourseWare 6.302 Feedback Systems (Roberge, Dawson, Lundberg)
- python-control: control.step_info (rise time 10% to 90%, settling time 2%, overshoot)
- Python Control Systems Library (python-control) documentation
Quiz Unlocks after the last step.