Climate under Cover
Digital Dynamic Simulation in Plant Bio-Engineering

Control Toolset

PID and Feedforward Control Models

This page presents CUC120 and CUC122 as browser-based control tools for comparing standard greenhouse control responses.

The control logic remains discrete-time, preserving the original PID, PI, PD, feedback, and feedforward comparisons from the Matlab examples.

MATLAB sources are preserved in matlab-source/cuc70_122, including cuc120.m, cuc122.m, and feedf.m.

CUC120

PID control variants

Recreates the textbook PID, PI, and PD examples, including the long-delay PID case and the under/overshoot comparisons.

CUC122

Feedback versus feedforward floor-heating control

Compares the feedback response and the feedforward integral response for a sinusoidal set-point signal over 48 hours.

Numerics

Discrete-time translation

  • CUC120 and CUC122 keep their original discrete-time structure rather than being rewritten as differential equations.
  • Case 1 of CUC120 is plotted in days to match the long simulation horizon of the Matlab example.
  • The feedforward response uses numerical quadrature in place of MATLAB quadl.

Formula Notes

Key control equations

  • P(t) = KK * ER(t-1) is the proportional control term.
  • I(t) = KK * ΣER / TL is the integral control term.
  • D(t) = KK * TD * (ER(t-1) - ER(t-2)) / Δt is the derivative control term.
  • PVP(t) = P(t), PVPI(t) = P(t) + I(t), PVPD(t) = P(t) + D(t).
  • PVPID(t) = P(t) + I(t) + D(t) is the full discrete PID control signal used in CUC120.
  • CV(t) = exp(-(t-TAU)/DELA) / DELA * ΣPV is the delayed process response used in CUC120.
  • SP(t) = sin(2πt / 24) is the set-point signal used in CUC122.
  • CVF(t) = exp(-(t-TAU)/DELA) / DELA * integrateFeedf(t-TAU) describes the feedforward response in CUC122.
  • ER is control error, KK is controller gain, TL and TD are integral and derivative times (hr), TAU and DELA are process-delay parameters (hr), Δt is the time step, and Σ denotes discrete accumulation.