Simulink Control Design™ - MathWorks

(Tuis.) #1

bdclose('scdsaturationDF');
scdsaturationDFcl
mdl = 'scdsaturationDFcl';


L = zpk([],[0 -1 -10],1);
w = logspace(-2,2,50);
A_DF = zeros(numel(A),numel(w));
for ct_amp = 1:numel(A)
for ct_freq = 1:numel(w)
% Compute the amplitude to nonlinearity solving the analytical
% equation
A_DF(ct_amp,ct_freq) = fzero(@(A_DF) solveForSatAmp(A_DF,L,w(ct_freq),A(ct_amp)),A(ct_amp),...
optimset('Display','off'));
end
end


Next, compute the analytical frequency response of the closed loop from reference to
output with describing function for each amplitude and store it in an FRD-array.


L_w = freqresp(L,w);
for ct = 1:numel(A)
N_A = saturationDF(0.5./A_DF(ct,:));
cl_resp = N_A(:).L_w(:)./(1+N_A(:).L_w(:));
cl(1,1,ct) = frd(cl_resp,w);
end


You can obtain frequency response for the closed loop from reference to input using
FRESTIMATE in a similar way to the describing function analysis of saturation above.


Describing Function Analysis of Nonlinear Simulink Models
Free download pdf