[Kp1_grid, Ki1_grid] = ndgrid(Kp1_range,Ki1_range);
params(1).Name = 'Kp1';
params(1).Value = Kp1_grid;
params(2).Name = 'Ki1';
params(2).Value = Ki1_grid;
sllin.Parameters = params;
Similar to the workflow for configuring the parameter grid for inner-loop analysis, create
the structure, params, that specifies a 6 x 4 parameter grid. Reconfigure
sllin.Parameters to use the new parameter grid. sllin now uses the default values
for Kp2 and Ki2.
Analyze Closed-Loop Transfer Function from Reference to Plant Output
Remove e1 from the list of permanent openings for sllin before proceeding with outer-
loop analysis.
removeOpening(sllin,'e1');
To obtain the closed-loop transfer function from the reference signal, r, to the plant
output, y1m, add r and y1m as analysis points to sllin.
addPoint(sllin,{'r','y1m'});
Obtain the transfer function from r to y1m.
r2yo = getIOTransfer(sllin,'r','y1m');
Plot the step response for r2yo.
stepplot(r2yo);
Vary Parameter Values and Obtain Multiple Transfer Functions