Simulink Control Design™ - MathWorks

(Tuis.) #1
BlockSubs = struct('Name','rct_CSTR/CSTR','Value',Gd);
ST0 = slTuner('rct_CSTR',{'Kp','Ki'},BlockSubs);

Finally, use the tunable surfaces to parameterize the lookup tables.

ST0.setBlockParam('Kp',Kp);
ST0.setBlockParam('Ki',Ki);

When you tune STO, systune tunes the coefficients of the tunable surfaces Kp and Ki, so
that each tunable surface represents the tuned relationship between Cr and the gain.
When you write the tuned values back to the block for validation, setBlockParam
automatically generates tuned lookup-table data by evaluating the tunable surfaces at the
breakpoints you specify in the corresponding blocks.

For more details about this example, see “Gain-Scheduled Control of a Chemical Reactor”
(Control System Toolbox).

Tunable Surfaces in MATLAB


For a control system modeled in MATLAB, use tunable surfaces to construct more
complex gain-scheduled control elements, such as gain-scheduled PID controllers, filters,
or state-space controllers. For example, suppose that you create two gain surfaces Kp and
Ki using tunableSurface. The following command constructs a tunable gain-scheduled
PI controller.

C0 = pid(Kp,Ki);

Similarly, suppose that you create four matrix-valued gain surfaces A, B, C, D. The
following command constructs a tunable gain-scheduled state-space controller.

C1 = ss(A,B,C,D);

You then incorporate the gain-scheduled controller into a generalized model of your
entire control system. For example, suppose G is an array of models of your plant sampled
at the design points that are specified in Kp and Ki. Then, the following command builds
a tunable model of a gain-scheduled single-loop PID control system.

T0 = feedback(G*C0,1);

When you interconnect a tunable surface with other LTI models, the resulting model is an
array of tunable generalized genss models. The design points in the tunable surface
determine the dimensions of the array. Thus, each entry in the array represents the

11 Gain-Scheduled Controllers

Free download pdf