Page 148 - MATLAB an introduction with applications
P. 148
Control Systems ——— 133
where w is the frequency vector.
MATLAB bode commands with left hand arguments commonly used are:
[mag, phase, w] = bode (num, den)
[mag, phase, w] = bode (num, den, w)
[mag, phase, w] = bode (A, B, C, D)
[mag, phase, w] = bode (A, B, C, D, w) ...(3.21)
[mag, phase, w] = bode (A, B, C, D, iu, w)
[mag, phase, w] = bode (sys)
The MATLAB commands given in Eq. (3.21) returns the frequency response of the system in matrices mag,
phase and w. The plot is not drawn on the screen. The matrices mag, phase provide the magnitudes and
phase angles of frequency response of the system, computed at the specified frequency points.
The magnitude may be converted into decibels using the MATLAB statement
magdB = 20 * log 10 (mag) ...(3.22)
In MATLAB, the following command
logspace (d1, d2) ...(3.23)
or
logspace(d1, d2, n). logspace(d1, d2) ...(3.24)
are used to specify the frequency range that will generate a vector of 50 points logarithmically equally
d2
d1
speed between decades 10 and 10 .
The MATLAB command
w = logspace (–1, 2) ...(3.25)
may be used to generate 50 points between 0.1 and 100 rad/sec.
Similarly, the MATLAB command
logspace (d1, d2, n) ...(3.26)
d1
d2
generates n points logarthimatically equally spaced between 10 and 10 where by the n points include
both the endpoints.
3.14 NYQUIST PLOTS
Nyquist plots are also used in the frequency-response representation of linear, time invariant, continuous
time feedback control systems. Nyquist plots are polar plots.
The MATLAB command
nyquist (num, den) ...(3.27)
Draw the Nyquist plot of the transfer function
s
num ()
() =
Gs ...(3.28)
s
den ()
where num and den contain the polynomial coefficients in descending powers of s. The other MATLAB
command uses for drawing Nyquist plots are:
F:\Final Book\Sanjay\IIIrd Printout\Dt. 10-03-09