Control theory
Control theory is the study of how to make a dynamic system (one whose behavior changes over time), such as an engine, an aircraft or a chemical plant, behave as desired. Its main tool is feedback, in which a controller measures what the system is doing, compares it with what it should be doing, and uses the difference to correct it.[1][2] Thermostats, car cruise control and aircraft flight systems all use feedback, and living bodies use it to keep blood sugar steady.[2][1]
The field uses differential equations (equations that relate quantities to how fast they change), linear algebra (the math of vectors and matrices) and complex numbers (numbers with a real and an imaginary part) to predict how a controlled system will respond.[2] Engineers use these predictions to design controllers that are accurate and stable, meaning disturbances do not make errors grow without bound, even when the system is not perfectly known.[2]
The feedback loop
A feedback controller repeats three steps in a loop:[2]
- Sense how the system is running.
- Compare that with the desired behavior and compute a correction.
- Act on the system to make the change.
The rule that turns sensor readings into control actions is called the control law.[2]
The loop has a few standard parts and signals:
- The plant, or process, is the system being controlled.[3]
- The reference is the desired value of the output, such as the speed a driver sets.
- The output is the measured quantity, and the error is .[1] The error is formed at a summing junction, a point where signals are added or subtracted.[4]
- The controller computes a control signal , and an actuator applies it to the plant.[2]
- Disturbances push the plant away from the desired behavior, and noise corrupts the sensor readings.[2]
Open and closed loops
A system is closed loop when its parts are connected in a cycle, so each part affects the others. Break that cycle and the system is open loop.[1] An open-loop controller acts without measuring the result, while a feedback controller keeps checking it.
Feedforward control is a common partner to feedback. It measures a disturbance and acts before the disturbance shows up in the output. Because it relies on a model of the plant, it is usually combined with feedback, which is less sensitive to modeling errors.[5]
Example: cruise control
A car's cruise control shows why feedback is useful. The controller adjusts the fuel flow based on the speed error and its running total. Åström and Murray simulate a change in the set speed for car masses that vary by a factor of 3, and in every case the car reaches the desired speed within about 5 seconds.[2]
The controller does not need to know the mass, because it reacts to the measured speed.[2]
Why feedback is used
Feedback makes a system able to handle things the designer cannot predict.[1] Its main uses are:
- Robustness to uncertainty. When something changes the output, the controller senses it and pushes the system back toward its desired operating point, the condition at which it is meant to run.[2]
- Rejecting disturbances. Feedback makes a system much less sensitive to outside disturbances and to changes in its own parts.[1]
- Shaping dynamics. Unstable systems can be stabilized, slow systems made faster, and drifting operating points held constant.[2]
- Linear behavior from nonlinear parts. Feedback can make a system built from nonlinear parts behave linearly, meaning effects add together and scale in proportion to the inputs. Electronics often uses feedback this way.[1]
The negative feedback amplifier is a classic case. In 1927 Harold S. Black of Bell Labs fed part of an amplifier's output back to its input. This lowered the gain but made the amplifier much less affected by changes in its vacuum tubes, so long telephone lines could use stable, linear amplifiers.[2]
Drawbacks
The main risk of feedback is instability. A microphone that howls when the volume is turned up too high is an example of feedback instability.[2]
Feedback also feeds sensor noise into the system, so measurements must be filtered. A control system also adds cost and complexity to a product.[2]
Simple controllers
Most controllers in practice follow a few simple rules. Each one below computes the control signal from the error .
On-off control
The simplest rule uses full corrective action whenever there is any error:[1]
Here and are the largest and smallest control signals available. On-off control has no settings to tune and is used in simple thermostats. It often makes the output swing back and forth, because a tiny change in error swings the control signal over its full range.[1]
Proportional control
Proportional control makes the control signal grow with the error, , where is the controller gain, a number that sets how much the control signal changes for each unit of error.[1] Small errors get small corrections, which avoids the over-reaction of on-off control.
PID control
The proportional-integral-derivative (PID) controller adds two more terms to proportional control:[1]
- is the proportional term. It reacts to the present error.
- is the integral term, with integral gain . It reacts to the past, through the total error built up over time.
- is the derivative term, with derivative gain . It predicts the future error by extending the current trend.[1]
Integral action removes the steady-state error, the error that remains after the output settles. This holds only if the loop settles, since a loop that keeps swinging back and forth has no steady state.[1]
Åström and Murray report a commonly quoted figure that about 90% of control problems can be solved by PID control. Many of these controllers are really PI controllers, because the derivative term is often left out.[1]
Describing systems with models
Control design starts from a mathematical model of the plant. A model predicts how the outputs respond to the inputs over time.[3]
State and state-space models
The state of a system is a list of numbers that sums up the effect of everything that happened to it in the past. Given the present state and the future inputs, the future behavior is fully determined.[3] For a linear time-invariant system, the state-space model is:[6]
- is the state vector, and is its rate of change over time.
- is the input vector, and is the output vector.
- , , and are constant matrices that describe how the state evolves and what the sensors see.
Transfer functions
A transfer function describes how a linear system turns input signals into output signals. It uses the Laplace transform, with complex frequency variable . A state-space model with matrices has the transfer function:[6]
Here is the identity matrix, a square matrix with 1s on its main diagonal and 0s elsewhere. The values of where becomes infinite are its poles, and they set the character of the response.[4]
Closed-loop transfer functions
In a feedback loop, the loop transfer function is the product of everything around the loop. For a plant and controller , .[4] Two closed-loop transfer functions matter most:[4]
- The sensitivity function measures how strongly a disturbance at the plant output affects the output.
- The complementary sensitivity is the transfer function from the reference to the output in the standard loop.
Because at every frequency, the two cannot both be made small at the same frequency.[4] Block diagrams and signal-flow graphs help keep track of these relations.
Models from data
When physics alone cannot give a good model, engineers measure one. System identification builds mathematical models of dynamic systems from observed data.[7]
Measuring performance
Engineers often judge a control loop by its step response. This is how the output reacts when the reference jumps suddenly from one value to another. The first three measures below use the default definitions in MATLAB's stepinfo tool.[8]
- Rise time is the time the response takes to go from 10% to 90% of the way to its final value.[8]
- Overshoot is how far the peak goes above the final value, as a percentage of the total change.[8]
- Settling time is the time after which the error stays within 2% of the total change.[8]
- Steady-state error is the error that remains after the output settles.[4]
Stability
A closed loop is stable when bounded disturbances give bounded errors. Making sure of this is the first job of control design.[2] Stability theory gives several ways to check it.
Poles and eigenvalues
The complex plane is a graph of complex numbers, with the real part on one axis and the imaginary part on the other. A linear state-space model is internally stable if every eigenvalue of lies in the left half of this plane, meaning it has a negative real part.[9] For a feedback loop, the closed-loop poles are the roots of the characteristic equation .[4]
The Routh-Hurwitz criterion grew out of 19th-century work on judging stability from such equations.[10] For nonlinear systems, Aleksandr Lyapunov studied stability in 1892.[11] His methods underlie the modern idea of Lyapunov stability.
The Nyquist criterion
The Nyquist criterion judges closed-loop stability from the frequency response of the open loop, which is how a system responds to input signals at different frequencies. The method plots in the complex plane as the frequency varies, then counts how many times the curve circles the critical point .[12]
- is the number of closed-loop poles in the right half-plane.
- is the number of open-loop poles of in the right half-plane.
- is the net number of counterclockwise circles the curve makes around .
The closed loop is stable when , so that . This basic form assumes that has no poles on the imaginary axis and that the curve does not pass through .[12] The method also works with frequency responses measured in experiments, as long as is known.[12]
Stability margins
It is not enough for a loop to be stable; it also needs margins that show how far it is from losing stability.[13] The common measures read off the Nyquist curve are:[13]
- The gain margin is 1 divided by the distance from the origin to the point where the curve crosses the negative real axis between and .
- The phase margin is the smallest angle, measured on the unit circle (the circle of radius 1 around the origin), between and the curve.
- The stability margin is the shortest distance from the curve to .
The gain and phase margins must both be given to guarantee that the curve stays away from . The stability margin does this with a single number.[13]
Fundamental limits
Feedback cannot improve everything at once. Hendrik Bode showed that the integral of the logarithm of the size of the sensitivity function is constant, under conditions on the loop, so pushing sensitivity down at some frequencies raises it at others.[10]
This result is Bode's sensitivity integral. Bode also showed that the limits are stricter for non-minimum phase systems.[10]
Classical and modern control
The field is often split into two toolkits. They overlap, and modern practice uses both.[2]
| Classical control | Modern (state-space) control | |
|---|---|---|
| Main model | Transfer function | State-space equations |
| Key tools | Frequency response, Bode plots, Nyquist criterion, root locus, loop shaping, PID | Controllability, observability, state feedback, estimators, optimal control |
| Main period of origin | 1930s to 1950s | From about 1960 |
The dates follow the history given below.[10] The modern tools in the table are explained in the subsections that follow.
Controllability and observability
Rudolf Kálmán introduced controllability and observability in 1960.[14]
A system is controllable if the input can steer its state to any desired value, and observable if the state can be worked out from the measured outputs.[14] For the linear model with states, both are tested by the rank of a matrix, which is the number of its independent rows or columns:[14]
The first condition means the system is controllable, and the second means it is observable.[14]
State feedback chooses the input from the current state. With , using a gain matrix , the closed-loop poles are the eigenvalues of .[15] For a controllable system, these poles can be placed at any chosen locations, provided complex poles come in conjugate pairs (pairs with the same real part and opposite imaginary parts).[15][16]
Estimating the state
In practice, not every state variable can be measured exactly and at once, so control usually needs a second task, estimating the state from the measurements.[3] A state observer, or estimator, is a dynamic system that produces this estimate from the plant's inputs and outputs.[14]
For a linear system with Gaussian (normally distributed) noise, the Kalman filter gives the optimal estimate, in the sense that it minimizes the mean square error (the average squared difference between the estimates and the true values). When the noise is not Gaussian, it is still the best linear estimator.[17]
In principle, the problem then splits into two steps:[3]
- Build an optimal filter to estimate the state.
- Feed that estimate into an optimal control law.
This split is the idea behind the separation principle.
Optimal control
Optimal control picks the input that minimizes a cost. The linear-quadratic regulator (LQR) minimizes:[18]
- is a symmetric weighting matrix that sets the cost of state errors. It is positive semidefinite, meaning for every .
- is a symmetric weighting matrix that sets the cost of control effort. It is positive definite, meaning for every nonzero .[18]
The best input is the state feedback with . The matrix is the unknown in the algebraic Riccati equation:[18]
The LQR uses a symmetric, positive semidefinite solution . Under stabilizability and detectability conditions, which mean that every unstable part of the system can be controlled and shows up in the cost, this solution is unique and the resulting feedback makes the closed loop stable.[19] The solution is positive definite exactly when the system is stabilizable and every part of the state shows up in the cost (complete observability).[19]
Model predictive control
Model predictive control (MPC) repeats an optimization at every time step. It works in four steps:[20]
- Measure or estimate the current state of the plant.
- Use a model to predict the plant's output over the prediction horizon, the number of future time steps over which the controller tries to minimize the cost.
- Solve for the control moves that minimize the cost and respect limits on inputs and outputs. The number of free moves is the control horizon, which is usually shorter than the prediction horizon.
- Apply only the first move, then repeat at the next step.
MPC's main strengths are that it handles constraints directly and handles plants with several inputs and outputs. Its main cost is the computing power needed to solve an optimization in real time.[20]
Branches of the field
Control theory has many branches, each aimed at a kind of system or difficulty:
- Robust control designs loops that stay stable and perform well under all expected changes in the plant, not only for the model the designer assumed.[2] Bode's design method was an early example.[10] H-infinity methods are a modern form.
- Adaptive control uses a controller with adjustable parameters and a mechanism for adjusting them.[21]
- Digital control runs the control law on a computer, with converters between analog signals (which vary continuously) and digital numbers.[2]
- Nonlinear control deals with systems that the linear models above do not describe well, often using Lyapunov methods.[11]
- Stochastic control handles random disturbances and noise, as in Kalman filtering.[3]
Other branches include:
- multivariable control;
- distributed control;
- hybrid systems;
- supervisory control of discrete-event systems;
- fuzzy control;
- intelligent control;
- data-driven control;
- learning-based control.
Applications
Control systems are everywhere but mostly hidden from view, often inside the code of small processors built into devices.[1] Examples include:[2][1]
- Feedback loops in electronic amplifiers.
- Setpoint controllers, which hold a quantity at a chosen target value, in chemical and materials processing and in industrial process control in general.
- Fly-by-wire aircraft, whose controls send commands electronically, along with cars and transport and communication systems.
- Router protocols that control traffic on the Internet.
- Precision instruments such as atomic force microscopes, which map a surface with a tiny probe, and telescopes.
- Robots, autonomous vehicles and engineered biological systems.
Biology is full of feedback. When blood glucose rises, the pancreas releases insulin, which makes the body store the excess, and when it falls, the hormone glucagon has the opposite effect. Together they keep blood glucose near about 90 mg per 100 ml of blood.[1]
More examples are covered in control theory in biology and homeostasis.
History
Feedback devices are more than 2000 years old, but a general theory of control came only in the 20th century.[22][3] The history of control theory has its own page.
Early devices
The earliest known examples are water clocks described by Vitruvius and credited to Ktesibios, around 270 BC.[22] The centrifugal governor of the 1780s regulated the speed of the Watt steam engine.[1]
Spinning flyballs swing outward as the engine speeds up, and a linkage then closes the throttle.[1] By 1868 there were more than 75,000 governors installed in England.[10]
Theory of governors
The mathematical theory began with James Clerk Maxwell in 1868. He analyzed linearized models of governors, which treat the system as linear near its operating condition, and found that stability depends on the roots of an algebraic equation. Ivan Vyshnegradskii did a similar analysis on his own in 1876.[10]
Edward Routh solved the general stability problem in 1877. Adolf Hurwitz reached a general criterion by other methods in 1895, unaware of Routh's work.[10]
Feedback amplifiers and frequency methods
Long-distance telephony drove the next advances. Black's patent on his 1927 amplifier took nine years to be granted, partly because patent officers refused to believe the amplifier would work.[10]
Harry Nyquist met the problem of unstable feedback amplifiers in 1932, and his criterion analyzes how sine waves travel around the loop. Bode introduced gain and phase margins in 1940 and summed up his methods in a 1945 book.[10]
World War II and after
World War II made control an established field, with servomechanism theory as its foundation.[10] A servomechanism is a closed-loop system that uses a motor to adjust a quantity based on the difference between its actual and desired values.[3]
Norbert Wiener published Cybernetics in 1948, about feedback in living things and machines.[23] In 1948, Walter R. Evans published the graphical methods behind root locus analysis.[24]
State space era
Around 1960 the field changed quickly.[10] Several things arrived together:[10]
- the digital computer;
- Richard Bellman's dynamic programming (1957);
- Kalman's state-space approach, the linear-quadratic regulator and the Kalman filter.
The International Federation of Automatic Control (IFAC) held its first World Congress in Moscow in 1960. The space race and computer control of industrial processes then pushed theory and applications forward.[10] Encyclopaedia Britannica dates control theory as a field in its own right to the late 1950s and early 1960s.[3]
References
- Feedback Systems: An Introduction for Scientists and Engineers (draft), Karl J. Åström and Richard M. Murray, 2006.
- Feedback Systems: An Introduction for Scientists and Engineers, Karl J. Åström and Richard M. Murray, Princeton University Press, 2008.
- Control theory, Encyclopaedia Britannica.
- Handout 5: An Introduction to Feedback Control Systems, University of Cambridge Department of Engineering.
- Lecture 5: Feedforward, EE392m, Stanford University, 2003.
- State-Space Realizations, MathWorks documentation.
- System Identification: Theory for the User, 2nd ed., Lennart Ljung, Prentice Hall, 1999.
- stepinfo: Rise time, settling time, and other step-response characteristics, MathWorks documentation.
- ECE 486 Control Systems, Lecture 20, University of Illinois Urbana-Champaign.
- Control: A perspective, Karl J. Åström and P. R. Kumar, Automatica, 2014.
- A Short History of Circuits and Systems, IEEE Circuits and Systems Society, 2022.
- Lecture 24: Nyquist Stability: Encirclements and the Nyquist Criterion, Xu Chen, University of Washington.
- Feedback Systems, Chapter 9: Frequency Domain Analysis, Karl J. Åström and Richard M. Murray, 2010.
- Chapter Five: Controllability and Observability, Zoran Gajić, Rutgers University.
- Pole Placement, MathWorks documentation.
- Pole placement using output feedback (NASA CR thesis, see Theorem 2.2 and Section 2.3), NASA Technical Reports Server, 1973.
- Understanding and Applying Kalman Filtering, Lindsay Kleeman, Monash University.
- Linear Quadratic Regulators, Russ Tedrake, Underactuated Robotics, MIT.
- 16.323 Lecture 4: HJB Equation and Continuous LQR, Jonathan How, MIT OpenCourseWare, 2008.
- What Is Model Predictive Control?, MathWorks documentation.
- Multirotors From Takeoff to Real-Time Full Identification (quoting Åström and Wittenmark, Adaptive Control), arXiv, 2020.
- A brief history of automatic control, Stuart Bennett, IEEE Control Systems Magazine, 1996.
- Cybernetics or Control and Communication in the Animal and the Machine, Norbert Wiener, MIT Press.
- Graphical Analysis of Control Systems, Walter R. Evans, Transactions of the AIEE, 1948.
