S919 of 55
0 XP
  1. Hook
  2. Play
  3. Predict
  4. Name it
  5. Check
  6. Explain

S9 · Lesson 19 · Feedforward and two-degree-of-freedom control

Acting before the error appears: disturbance feedforward and its limits, inverse-model reference feedforward in motion control, prefilters and setpoint weighting

Feedback has a built-in handicap: it can't act until an error has already appeared. If a disturbance can be measured, or a reference is known in advance, there's no need to wait. A furnace controller that sees the door open can add heat before the temperature falls; a motion controller that knows the planned trajectory can supply the torque to accelerate before any position error builds up. That's feedforward. It relies on a model, so it's never perfect, but feedback cleans up what it misses: together they do far better than either alone.

  • The curve is the output's deviation after a step disturbance at a plant's input, 1/(10s+1), with a PI loop of crossover 1 rad/s acting alone: the response from lesson 8, peaking at 0.077 and lingering for tens of seconds.
  • The dashed curve adds a feedforward that cancels a fraction g of the disturbance. By superposition, what's left is (1 − g) times the feedback-only deviation.
  • A feedforward 80% right removes 80% of the deviation; feedback handles the rest without ever seeing the part that was cancelled.

Predict

A disturbance feedforward is built from a model whose gain is 20% too low. How much of the disturbance's effect does it remove?

Name it

Disturbance feedforward

A measured disturbance d reaches the output through Pd, and the input reaches it through P. A feedforward uff=Fd adds PFd, so the disturbance's net path is (Pd+PF), zero for

F=−PdP

That ideal F must be stable and causal: if P has more delay than Pd, or a right-half-plane zero, it can't be inverted exactly, and a static feedforward F=−Pd(0)/P(0) is the usual fallback. With feedback too, what's left reaches the output as (Pd+PF)S: feedforward shrinks the disturbance, feedback attenuates the remainder.

Reference feedforward and two degrees of freedom

A one-degree-of-freedom loop acts only on the error, so the response to the reference and the rejection of disturbances are tied together through the same C. A two-degree-of-freedom controller separates them:

  • inverse-model feedforward: u=Frr+C(r−y) with Fr=P−1 makes the output follow r exactly when the model is right, and feedback corrects the error when it isn't;
  • prefilter: shape the reference before the loop, rf=Fpr, so the overall response is FpT, for instance to cancel a slow or overshoot-causing zero of T;
  • setpoint weighting in PI control, u=Kp(br−y)+Ki∫(r−y), with 0≤b≤1, puts only a fraction b of a setpoint step into the proportional term, which reduces overshoot without changing disturbance rejection.

Motion control

For a motor of inertia J, viscous friction b and torque constant Kt, a trajectory with acceleration a(t) and velocity v(t) needs current

iff=Ja+bvKt

Supplying it ahead of time lets the position loop handle only modeling errors and disturbances, which is why motion controllers carry acceleration and velocity feedforward gains.

Worked example

A rotary stage has J = 2 × 10⁻⁴ kg·m², b = 10⁻³ N·m·s and Kt = 0.05 N·m/A. Its planned move accelerates at 500 rad/s² while at 100 rad/s. What feedforward current does that moment need?

Show the solution
  1. The two torques. One accelerates the inertia and one overcomes friction at this speed: Ja=2×10−4×500=0.1N·mbv=10−3×100=0.1N·m
  2. Feedforward current. iff=Ja+bvKt=0.1+0.10.05=4A
  3. Without feedforward. The position loop would have to build up a tracking error large enough for its gain to command those 4 A, and the error during every acceleration would be proportional to them.

Answer the feedforward current at that moment is 4 A.

Worked example

A furnace's temperature rises 2 °C per watt of heater and 1 °C per °C of ambient. What static feedforward on the measured ambient cancels it, and what's left if the real heater gain is 2.4 °C/W?

Show the solution
  1. Static feedforward. F=−Pd(0)/P(0)=−1/2 Cut the heater by 0.5 W for each °C the ambient rises.
  2. With the true gain. The feedforward removes 2.4×0.5=1.2°C per °C overcorrecting by 20%.
  3. Residual. 1−1.2=−0.2°C per °C of ambient change, a fifth of the original, which the feedback loop then reduces further.

Answer cut the heater by 0.5 W per °C of ambient rise; with a true gain of 2.4 °C/W, −0.2 °C per °C remains, a fifth of the original.

Worked example

A PI loop around 1/(s+1) with Kp = 3 and Ki = 8 gives T=(3s+8)/(s2+4s+8): ζ = 0.707, but with a zero at −2.67. What does the zero do to a step, and how does a prefilter fix it?

Show the solution
  1. Without the zero. ζ = 0.707 alone would overshoot 4.3%.
  2. With the zero. The zero adds a multiple of the derivative to the response, and a simulation of T gives 11.9% overshoot.
  3. The prefilter. This cancels the zero: Fp=83s+8
  4. What the reference sees. FpT=8s2+4s+8 which overshoots 4.3% again.
  5. Disturbances. Disturbance rejection is unchanged, since the prefilter sits outside the loop.

Answer the zero raises the overshoot from 4.3% to 11.9%, and the prefilter 8/(3s+8) cancels it, bringing the overshoot back to 4.3%.

Check

A motor with J = 0.0001 kg·m², viscous friction b = 0.001 N·m·s and Kt = 0.03 N·m/A follows a trajectory accelerating at 200 rad/s² while turning at 300 rad/s.

(a)

What feedforward current does it need at that moment?

Write units the way you normally would: 1.5 A, 1500 mA and 0.0015 kA are the same answer.

(b)

What fraction of it goes to acceleration?

Check

A process gains 2 units per unit of input and 0.3 units per unit of a measured disturbance; a static feedforward is designed with a model gain for the input that's off by 20%.

(a)

What feedforward gain does the model give?

(b)

How much disturbance reaches the output per unit, before feedback?

Check

A PI controller (Kp = 3, Ki = 4) runs around the plant 1/(s+1).

(a)

Where is the closed loop's zero?

(b)

What is the closed-loop damping ratio?

(c)

What time constant must a first-order prefilter have to cancel the zero?

Write units the way you normally would: 1.5 s and 1500 ms are the same answer.

Check

A PI zero cancels the plant pole of 1/(τs+1), τ = 10 s, for a loop L=1/(τcs) with τc = 0.5 s; a feedforward cancels a fraction 0.95 of a unit step disturbance at the plant's input.

(a)

What peak deviation remains?

Check

A PI controller with setpoint weight b = 0.3 and Kp = 2 sees a setpoint step of 10 while the output is still at rest.

(a)

How big is the proportional term's initial jump?

Check

A plant has a dead time of 2 s from its input, while a measured disturbance reaches the output after 0.5 s.

(a)

How far in advance would an ideal feedforward need to act?

Write units the way you normally would: 1.5 s and 1500 ms are the same answer.

Check

Why does a plant with a right-half-plane zero rule out exact inverse-model feedforward?

Check

A static feedforward uses an input gain p(1+e) where the truth is p, to cancel a disturbance with gain d.

Step 1

What is the feedforward gain?

Type it the way you would write it, like 3sin(2πft) or 3*sin(2*pi*f*t). Angles can be in radians or carry a degree sign, like 45°.

Check

Write peak_deviation(g, T, dt): simulate a unit step disturbance at the input of 1/(10s+1) under PI control C=(10s+1)/s, so that L = 1/s (forward Euler, step dt, for T seconds), with a feedforward that subtracts g times the disturbance at the plant's input, and return the largest output deviation.

Python 3.14 with numpy and matplotlib, running in your browser. Tab indents; press Esc and then Tab to move on.

Explain why

Why are feedforward and feedback combined rather than used alone?

Practice

Keep practicing

9 kinds of problem on this topic, dealt one at a time with new numbers every time, for as long as you like.