Design a Smith Predictor for a Tank Reactor
Design a Smith Predictor for a Tank Reactor
An isothermal continuous stirred-tank reactor (CSTR) can be modeled by a first-order-plus-time-delay system:
reactor = TransferFunctionModel[Unevaluated[{{(E^-δ s/1 + s)}}], s, SamplingPeriod -> None, SystemsModelLabels -> None];pi = PIDTune[reactor /. δ -> 0, "PI"];
closedloop = SystemsModelFeedbackConnect[SystemsModelSeriesConnect[pi, reactor]]OutputResponse[closedloop /. δ -> 2, UnitStep[t - 1], {t, 0, 12}];
Plot[%, {t, 0, 12}, PlotRange -> All, ImageSize -> Medium]Use SmithDelayCompensator to create a stabilizing controller for the time-delay system:
smith = SmithDelayCompensator[reactor, pi];
closedloopSmith = SystemsModelFeedbackConnect[SystemsModelSeriesConnect[smith, reactor]]OutputResponse[closedloopSmith /. δ -> 2, UnitStep[t - 1], {t, 0, 12}];
Plot[%, {t, 0, 12}, PlotRange -> All, ImageSize -> Medium]