Está en la página 1de 5

Prácticas de Regulación Automática I 2º ITI Electrónica

Curso 2007/08
http://www.unirioja.es/cu/rasaenl

PRACTICA 7. ESTABILIDAD EN EL DOMINIO DE LA FRECUENCIA. BODE-


NYQUIST.

Conocimientos previos:
1. Trazado de diagrama de Bode.
2. Trazado de diagrama de Nyquist.
3. Concepto de Margen de Ganancia.
4. Concepto de Margen de Fase.
5. Frecuencia de resonancia.
6. Pico de Resonancia.
7. Ancho de Banda.
8. Sistema de fase mínima.
9. Funciones de MATLAB: bode, margin, nyquist, num2str

1. Determinar para un sistema de segundo orden de cadena abierta


Vo( s ) ω n2
G (s ) = =K* 2 , con K=1, Wn=3.1623 rad/seg y
Vi ( s ) s + 2 ⋅ δ ⋅ ω n ⋅ s + ω n2
delta=0.0949 el diagrama de Bode para el rango de pulsaciones ω=0.1 hasta
1000 rad /s, (vector logarítmicamente equiespaciado) del sistema.

A partir del diagrama de Bode representado obtén de forma gráfica:


a. Pico de resonancia Mp.
b. Frecuencia de resonancia. Wr.

Realiza la programación adecuada para obtener:


c. Ancho de banda Wd del sistema en lazo cerrado.
d. Comprobar los resultados de los apartados a y b a partir de los
argumentos de salida de la función bode.

2. Utilizando la función margin, obtener para la f.d.t. de cadena abierta del


apartado anterior:
a. Margen de ganancia.
b. Margen de fase.
c. Frecuencia correspondiente al margen de ganancia.
d. Frecuencia correspondiente al margen de fase.
e. Representar el margen de ganancia y de fase en un diagrama de Bode
(margin).

PRÁCTICA 7- ESTABILIDAD EN EL DOMINIO DE LA FRECUENCIA Página 1


Prácticas de Regulación Automática I 2º ITI Electrónica
Curso 2007/08
http://www.unirioja.es/cu/rasaenl

3. Determinar los márgenes de ganancia y de fase a partir de los siguientes


diagramas (en todos los casos debes considerar el sistema de cadena abierta
GH3):
a. Traza el Diagrama de Bode indicando los márgenes de ganancia y de
fase.
b. Traza el Diagrama de Nyquist y obtén a partir de él, el margen de
ganancia y de fase.
c. Traza el Diagrama de Nichols y obtén a partir de el los márgenes
anteriores.

0.5
GH 3 =
s + 2 s 2 + s + 0.5
3

4. Determinar la estabilidad en lazo cerrado de los siguientes sistemas de cadena


abierta aplicando el Criterio de Nyquist:
1
a. GH 4a =
( s + 1)(2 s + 1)
K
b. GH 4b =
s( s + 1) 2
i. K=1
ii. K=2
iii. K=10
1
c. GH 4c =
( s )( s − 1)
1+ 2⋅ s
d. GH 4d =
s( s − 1)
K ⋅ ( s − 2)
e. GH 4e =
( s + 1) 2
i. K=0.25
ii. K=1

PRÁCTICA 7- ESTABILIDAD EN EL DOMINIO DE LA FRECUENCIA Página 2


Prácticas de Regulación Automática I 2º ITI Electrónica
Curso 2007/08
http://www.unirioja.es/cu/rasaenl

FUNCIONES DE MATLAB

BODE. Calcula el diagrama de Bode de un sistema.

bode(sys) Representa el diagrama de Bode del sistema

bode(sys,wmin,wmax) Representa el diagrama de Bode entre dos


frecuencias

w=logspace(-1,4,100)
bode(sys,w). Representa el diagrama de Bode para el vector especificado.

w=logspace(-1,4,100)
[mag,fase]=bode(sys,w). Devuelve el módulo y argumento del sistema.

MARGIN. Cálcula los margenes de ganancia y fase de un sistema.


Primera forma
[Mg,Mf,Wg,Wf]=margin(sys)

Segunda forma
w=logspace(-1,4,100)
[Mag,Fas]=bode(sys,w)
[Mg,Mf,Wg,Wf]=margin(Mag,Fas,w)

NYQUIST . Calcula el diagrama de Nyquist del sistema

[real,imag,w]=nyquist(sys,w)

sin argumentos de salida representa el diagrama


nyquist(sys)

NICHOLS. Calcula la magnitud y fase y representa la carta de Nichols.


[mag,phase,w]=nichols(sys,w)

sin argumentos de salida representa el diagrama


nichols(sys)

NGRID. Crea un mallado sobre la Carta de Nichols.

NUM2STR Convierte un número en una cadena


cadena = num2str(numero)

PRÁCTICA 7- ESTABILIDAD EN EL DOMINIO DE LA FRECUENCIA Página 3


Prácticas de Regulación Automática I 2º ITI Electrónica
Curso 2007/08
http://www.unirioja.es/cu/rasaenl

BODE Bode frequency response of LTI models.

BODE(SYS) draws the Bode plot of the LTI model SYS (created with
either TF, ZPK, SS, or FRD). The frequency range and number of
points are chosen automatically.

BODE(SYS,{WMIN,WMAX}) draws the Bode plot for frequencies


between WMIN and WMAX (in radians/second).

BODE(SYS,W) uses the user-supplied vector W of frequencies,


in radian/second, at which the Bode response is to be evaluated.
See LOGSPACE to generate logarithmically spaced frequency vectors.

BODE(SYS1,SYS2,...,W) plots the Bode response of multiple LTI


models SYS1,SYS2,... on a single plot. The frequency vector W
is optional. You can also specify a color, line style, and marker
for each system, as in
bode(sys1,'r',sys2,'y--',sys3,'gx').

[MAG,PHASE] = BODE(SYS,W) and [MAG,PHASE,W] = BODE(SYS)


return the
response magnitudes and phases in degrees (along with the frequency
vector W if unspecified). No plot is drawn on the screen.
If SYS has NY outputs and NU inputs, MAG and PHASE are arrays of
size [NY NU LENGTH(W)] where MAG(:,:,k) and PHASE(:,:,k)
determine
the response at the frequency W(k). To get the magnitudes in dB,
type MAGDB = 20*log10(MAG).

For discrete-time models with sample time Ts, BODE uses the
transformation Z = exp(j*W*Ts) to map the unit circle to the
real frequency axis. The frequency response is only plotted
for frequencies smaller than the Nyquist frequency pi/Ts, and
the default value 1 (second) is assumed when Ts is unspecified.

See also NICHOLS, NYQUIST, SIGMA, FREQRESP, LTIVIEW,


LTIMODELS.

Overloaded methods
help lti/bode.m

PRÁCTICA 7- ESTABILIDAD EN EL DOMINIO DE LA FRECUENCIA Página 4


Prácticas de Regulación Automática I 2º ITI Electrónica
Curso 2007/08
http://www.unirioja.es/cu/rasaenl

MARGIN Gain and phase margins and crossover frequencies.

[Gm,Pm,Wcg,Wcp] = MARGIN(SYS) computes the gain margin Gm, the


phase margin Pm in degrees, and the associated frequencies
Wcg and Wcp, for a SISO open-loop LTI model SYS (continuous or
discrete). The gain margin Gm is defined as 1/G where G is
the gain at the -180 phase crossing. The gain margin in dB
is 20*log10(Gm). By convention, Gm=1 (0 dB) and Pm=0 when
the nominal closed loop is unstable.

[Gm,Pm,Wcg,Wcp] = MARGIN(MAG,PHASE,W) derives the gain and


phase
margins from the Bode magnitude, phase, and frequency vectors
MAG, PHASE, and W produced by BODE. Interpolation is performed
between the frequency points to estimate the values.

For a S1-by...-by-Sp array SYS of LTI models, MARGIN returns


arrays of size [S1 ... Sp] such that
[Gm(j1,...,jp),Pm(j1,...,jp)] = MARGIN(SYS(:,:,j1,...,jp)) .

When invoked without left hand arguments, MARGIN(SYS) plots


the open-loop Bode plot with the gain and phase margins marked
with a vertical line.

NUM2STR Convert number to string.


T = NUM2STR(X) converts the matrix X into a string representation T
with about 4 digits and an exponent if required. This is useful for
labeling plots with the TITLE, XLABEL, YLABEL, and TEXT
commands.

T = NUM2STR(X,N) converts the matrix X into a string representation


with a maximum N digits of precision. The default number of digits is
based on the magnitude of the elements of X.

T = NUM2STR(X,FORMAT) uses the format string FORMAT (see


SPRINTF for
details).

Example:
num2str(randn(2,2),3) produces the string matrix

'-0.433 0.125'
' -1.67 0.288'

PRÁCTICA 7- ESTABILIDAD EN EL DOMINIO DE LA FRECUENCIA Página 5

También podría gustarte