close all, clear all, clc
%planta
num=4;
den=[1 2 0];
planta=tf(num,den);
%requerimientos del diseño
kv=20;
mfd=50;
mg=10;
%se halla k del compensador
kva=polyval(num,0)/polyval(deconv(den,[1,0]),0);
k=kv/kva;
%se continua el diseño sobre planta ux=k*planta
numaux=k*num;
denaux=den;
plantaux=tf(numaux,denaux);
%se halla los vectores de ganancia(gandB) y fase
w=logspace(-1,2,500);
[gan,fase]=bode(numaux,denaux,w);
gandB=20*log10(gan);
% se halla el margen de fase : mf
vectIndices=find(gandB<0);
indice=vectIndices(1);
mf=180-(-fase(indice));
% sehalla la fase a compensar: fadic
fadic=mfd-mf+5;
%alfa
alfa=(1-sin(fadic*pi/180))/(1+sin(fadic*pi/180));
%ganancia del compensador
r=20*log10(sqrt(1/alfa));
%se halla la nueva frecuencia de cruce de ganancia: wm
vectIndice2=find(gandB

indice2=vectIndice2(1);
wm=w(indice2);
%T
T=(1/sqrt(alfa))/wm;
%parametros del compensador
zc=1/T;
pc=1/alfa/T;
kc=k/alfa;c
omp=tf(kc*[1 zc],[1 pc])
%planta compensada
plantacompensada=series(planta,comp)
%respuesta en el tiempo
figure(1), step(feedback(planta,1)), hold on, grid onstep(feedback(plantacompensada,1))
%respUEsta en frecuencia
figure(2), bode(planta), hold on, grid onbode(plantacompensada)
----------------------------------°-°--------------------------------
VALORES OBTENIDOS
Transfer function:
40.39 s + 85.58
---------------
s + 8.558
Transfer function:
161.5 s + 342.3
------------------------
-s^3 + 10.56 s^2 + 17.12 s


1 comentario:
My programmer is trying to convince me to move to .net from
PHP. I have always disliked the idea because of the expenses.
But he's tryiong none the less. I've been using WordPress on numerous websites for
about a year and am concerned about switching to another platform.
I have heard very good things about blogengine.net.
Is there a way I can import all my wordpress posts into it?
Any kind of help would be greatly appreciated!
Here is my web blog - junakigroups.com
Publicar un comentario