PID control and compensation
Đã giới thiệu| English | Ý nghĩa |
|---|---|
| PID controller | bộ điều khiển PID |
| proportional/prəˈpɔːʃənl/ | tỷ lệ |
| integral/ˈɪntɪɡrəl/ | tích phân |
| derivative/dɪˈrɪvətɪv/ | vi phân |
| anti-windup | chống bão hòa |
| lead compensator | bộ bù pha trước |
P reacts, I remembers, D anticipates
- The PID controller PID 控制器 computes $u = K_{p}e + K_{i}\int e\,dt + K_{d}\dot e$: the proportional 比例 term reacts, the integral 积分 term removes steady-state error, the derivative 微分 term anticipates and damps. Proportional means the term that pushes in proportion to the present error. Integral means the term that accumulates past error until the offset is gone. Derivative means the term that reacts to how fast the error is changing, adding damping.
- Every term charges a price: P leaves steady error, I adds phase lag, D amplifies noise and must act on the measurement, not the reference.
Series form $u = K_{p}(e + \frac{1}{T_i}\int e\,dt + T_d\dot e)$ with $T_i$, $T_d$ in seconds. Parallel conversion: $K_i = K_p/T_i$ and $K_d = K_p T_d$.
{exercise:uni-ee1047-terms}
A series-form PID has K_p = 10, T_i = 2 s, T_d = 0.5 s. The parallel gains are —
Độ khó 1/5 · 100 xu + phần thưởng nhỏ khi hoàn thành lần đầu tiên hôm nay
K_i = K_p/T_i = 10/2 = 5 and K_d = K_p·T_d = 10×0.5 = 5. Mixing the two forms is the classic tuning slip.
Ziegler-Nichols: tune from the instability itself
- Raise the gain until the loop just oscillates; record the ultimate gain $K_u$ and period $T_u$; the PID row gives $K_{p} = 0.6K_{u}$, $T_{i} = T_{u}/2$, $T_{d} = T_{u}/8$.
- On the running plant: $K_u = 48$, $\omega_u = 2.83$ rad/s, so $T_u = 2.22$ s and the row reads $K_p = 28.8$, $T_i = 1.11$ s, $T_d = 0.278$ s.

What you get: P alone at 28.8 gives 65% overshoot and ramp error $\frac{2}{K_p} = 0.069$; the ZN PID removes the error but rings at 60%, decaying to about a sixth each cycle. The table lands you in the neighbourhood; it does not finish the job.
{exercise:uni-ee1047-zn}
Ziegler-Nichols on a plant with K_u = 6 and T_u = 4.44 s gives PID K_p, T_i, T_d = —
Độ khó 1/5 · 100 xu + phần thưởng nhỏ khi hoàn thành lần đầu tiên hôm nay
PID row: K_p = 0.6K_u = 3.6, T_i = T_u/2 = 2.22 s, T_d = T_u/8 = 0.555 s. The table also has P (K_u/2) and PI (0.45K_u, T_u/1.2) rows.
Turn the two knobs yourself
- The PD characteristic polynomial is $s^{3}+6s^{2}+(8+K_{p}T_{d})s+K_{p}$: the D term literally adds damping, and Routh says stable exactly while $K_{p} < 6(8+K_{p}T_{d})$.
- Gain alone breaks the loop at $K_p = 48$; enough damping repairs any gain. At $K_p = 28.8$, $T_d = 0.5$ s the poles sit at $-2, -2\pm j3.22$ and the step shows no overshoot, settling in 2.1 s (derivative on the measurement; on the error the PD zero cancels $-2$ and the pair still rings at 14%).
{exercise:uni-ee1047-pd}
One knob for gain, one for damping
Move Kp and Td and watch overshoot, settling and the Routh verdict move together; gain alone breaks the loop at 48, and damping repairs it.
With PD control on 1/[s(s+2)(s+4)], K_p = 28.8 and T_d = 0.5 s, the closed-loop characteristic polynomial is —
Độ khó 1/5 · 100 xu + phần thưởng nhỏ khi hoàn thành lần đầu tiên hôm nay
The s-coefficient is 8 + K_p·T_d = 8 + 14.4 = 22.4. Its poles are −2 and −2 ± j3.22: no overshoot, settling 2.1 s, while the ramp error stays 2/K_p.
Lead, lag and anti-windup
- A lead compensator 超前校正装置 $\frac{1+\tau s}{1+\alpha\tau s}$ ($0<\alpha<1$) buys phase: max lift $\sin\phi_m = \frac{1-\alpha}{1+\alpha}$ at $\omega_m = \frac{1}{\tau\sqrt\alpha}$; a +45° lift needs $\alpha = 0.172$ and lifts high-frequency gain by $1/\alpha = 5.8$.
- Anti-windup 抗饱和 (clamp the integrator, or back-calculate) keeps a saturated actuator from dumping stored integral as one huge overshoot. Anti-windup means a safeguard that stops the integrator from overcharging while the actuator sits at its limit.
Why D acts on the measurement: a setpoint step has infinite slope, so derivative-on-error kicks the actuator at every reference change.
{exercise:uni-ee1047-lead}
A lead compensator must add a maximum +45° of phase. The ratio α = pole/zero distance is —
Độ khó 1/5 · 100 xu + phần thưởng nhỏ khi hoàn thành lần đầu tiên hôm nay
sin 45° = 0.707 = (1−α)/(1+α) gives α = 0.172. The same network multiplies high-frequency gain by 1/α = 5.8, which the design must absorb.