MATLAB and Simulink Files

by

 

MATLAB and Simulink files for textbook Nise/Controls 6e.

ch10p4.m
% Nise, N.S. 
% Control Systems Engineering, 6th ed. 
% John Wiley & Sons, Hoboken, NJ, 07030
%
% Control Systems Engineering Toolbox Version 6.0 
% Copyright  2011 by John Wiley & Sons, Inc.
%
% (ch10p4) Example 10.9: We can use MATLAB to determine the range of K for 
% stability using frequency response methods. Let us look at Example 10.9 in the 
% text.

'(ch10p4) Example 10.9'             % Display label.
numg=1;                             % Define numerator of G(s).
deng=poly([-2 -4 -5]);              % Define denominator of G(s).
'G(s)'                              % Display label.
G=tf(numg,deng)                     % Create and display G(s).
[Gm,Pm,Wcg,Wcp]=margin(G);          % Find margins and margin
                                    % frequencies.
K=Gm                                % Display K for stability.

Contact us