The basics of control system design: Part 2 - Tuning a Proportional ControllerTuning a proportional controller is straightforward: Raise the gain until instability appears. The flowchart in Figure 6-2 below shows just that. Raise the gain until the system begins to overshoot.
The loss of stability is a consequence of phase loss in the loop, and the proportional gain will rise to press that limit. Be aware, however, that other factors, primarily noise, often ultimately limit the proportional gain below what the stability criterion demands.
|Figure 6-2. Tuning a P controller.|
Noise in a control system may come from many sources. In analog controllers, it is often from electromagnetic interference (EMI), such as radio frequency interference (RFI) and ground loops, which affects signals being connected from one device to another.
Noise is common in digital systems in the form of limited resolution, which acts like random noise with an amplitude of the resolution of the sensor. Independent of its source, noise will be amplified by the high-frequency gains in the controller, such as the proportional gain.
Noise is a nonlinear effect and one that is generally difficult to characterize mathematically. Usually, the person tuning the system must rely on experience to know how much noise can be tolerated.
Noise at some level is acceptable in every control system. Higher gain amplifies noise, so setting the gain low will relieve the noise problem but at the expense of degrading the control system performance.
In cases of substantial noise, setting the proportional gain requires balancing the need for performance and the elimination of noise. Things are simpler for tuning the examples in this chapter; these systems deal only with the small numerical noise in the model.
Figure 6-1 earlier in Part 1
shows the step response of the P
controller tuned according to the procedure of Figure 6-2 above. The result was Kp
= 1.2. The step response has almost no overshoot. Using the illustrated
the closed- and open-loop responses can be measured.
|Figure 6-3. Closed-loop Bode plot for proportional system (186 Hz bandwidth, 0 dB peaking)|
As shown in Figure 6-3 above, the closed-loop response has a comparatively high bandwidth (186 Hz) without peaking. The open-loop plot in Figure 6-4 below shows 65° Phase Margin (PM) and 12 dB Gain Margin(GM).
|Figure 6-4. Open-loop Bode plot of proportional system (65° PM, 12.1 dB GM)|
Using the Integral Gain
The primary shortcoming of the P controller, tolerance of DC error, is readily corrected by adding an integral gain to the control law. Because the integral will grow ever larger with even small DC error, any integral gain (other than zero) will eliminate DC droop. This single advantage is why PI is so often preferred over P control.
Integral gain provides DC and low-frequency stiffness. When a DC error occurs, the integral gain will move to correct it. The higher the gain, the faster the correction. Fast correction implies a "stiffer" system.
In other words, higher integral gain translates to higher DC stiffness. Don't confuse DC stiffness with dynamic stiffness. A system can be at once quite stiff at DC and not stiff at all at high frequencies. Be aware that higher integral gains will provide higher DC stiffness but will not substantially improve stiffness near or above the system bandwidth.
Integral gain does bring a certain amount of baggage. PI controllers are more complicated to implement; the addition of a second gain is part of the reason. Also, saturation becomes more complicated.
In analog controllers, clamping diodes must be added; in digital controllers, saturation algorithms must be coded. The reason is that the integral must be clamped during saturation to avoid the problem of "windup."
Integral gain also causes instability. In the open loop, the integral, with its 90° phase lag, reduces phase margin. In the time domain, the common result of adding integral gain is overshoot and ringing.
With PI control, the P gain provides similar operation to that in the P controller, and the I gain provides DC stiffness. Larger I gain provides more stiffness and, unfortunately, more overshoot. The controller is shown in Figure 6-5 below. Note that the KI is in series with Kp; this is common, although it's also common to place the two gains in parallel.
|Figure 6-5. Experiment 6B, a PI Controller.|
It should be noted that the implementation of is for illustrative purposes. The PI controller lacks a windup function to control the integral value during saturation. The standard control laws supported by Visual ModelQ provide windup control and so would normally be preferred. (In addition, they take less space on the screen.)
However, Experiment 6B and other experiments illustrated here break out the control law gains to make clear their functions. Because the purpose of the series to this point is to compare similar control laws, the clarity provided by explicitly constructed control laws outweighs the need for wind-up control or compact representation.
Editor's Note: Experiments 6A-6F
All the examples in this series of articles were run on Visual Mode1Q. Each of the six experiments, 6A-6F, models one of the six methods, P, PI, PI+, PID, PID+, and PD, respectively.
These are models of digital systems, with sample frequency defaulting to 2 kHz. If you prefer experimenting with an analog controller, set the sample time to 0.0001 second, which is so much faster than the power converter that the power converter dominates the system, causing it to behave like an analog controller.
The default gains reproduce the results shown in this series, but you can go further. Change the power converter bandwidth and investigate the effect on the different controllers.
Assume noise is a problem, reduce
the low-pass filter on the D gain (fD), and observe how this reduces
the benefit available from the derivative-based controllers (PID, PID+,
and PD). Adjust the power converter bandwidth and the sample time, and
observe the results.
Next in Part 3: How to Tune a PI
To read Part 1, go to "Moving beyond PID"
This series of articles was excerpted from Control System Design Guide by George Ellis with the permission of the publisher - Elsevier/Academic Books - and can be purchased online which retains all copyrights.
George Ellis is senior scientist at Danaher Motion. He has designed and applied motion control systems for over 20 years and has written for Machine Control Magazine, Control Engineering, Motion Systems Design, Power Control and Intelligent Motion, EDN Magazine. In addition to Control System Design Guide, he is also the author of Observers in Control Systems (Academic Press).
Currently no items