Professional Documents
Culture Documents
>> [AR,def,w]=bode(num,den);
>> subplot(211);
>> loglog(w,AR);
>> subplot(212);
>> semilogx(w,def)
>> clear
>> num=[5];
>> [AR,def,w]=bode(num,den);
>> subplot(211);
>> loglog(w,AR);
>> subplot(212);
>> semilogx(w,def)
>>
>>
>> clear
>> num=[5];
>> [AR,def,w]=bode(num,den);
>> subplot(211);
>> loglog(w,AR);
>> subplot(212);
>> semilogx(w,def)
>>
>>
>> k=1;
>> td=0;
>> G1=tf([1],[2 1]);
>> G=k*G1*G2;
>> [AR,defa,w]=bode(G);
>> AR=AR(1,:);
>> defa=defa(1,:);
>> subplot(211);
>> loglog(w,AR);
>> subplot(212);
>> semilogx(w,defa);
>> ylabel('Defasamiento');
>> xlabel('Frecuencia');
>>
>>
>>
>> k=1;
>> td=1;
>> G1=tf([1],[0 1]
??? G1=tf([1],[0 1]
Transfer function:
1
>> G1=tf([1],[1 1])
Transfer function:
-----
s+1
>> clear
>> k=1;
>> td=1;
>> G=k*G1*G2;
>> [AR,defa,w]=bode(G);
>> AR=AR(1,:);
>> defa=defa(1,:);
>> subplot(211);
>> loglog(w,AR);
>> subplot(212);
>> semilogx(w,defa);
>> ylabel('Defasamiento');
>> xlabel('Frecuencia');
>> xlabel('Frecuencia');
>>
>>
>>
>> k=1;
>> td=1;
>> G=k*G1*G2;
>> [AR,defa,w]=bode(G);
>> AR=AR(1,:);
>> defa=defa(1,:);
>> subplot(211);
>> grid
>> loglog(w,AR);
>> subplot(212);
>> grid
>> semilogx(w,defa);
>> ylabel('Defasamiento');
>> xlabel('Frecuencia');
>> grid
>>
>>
>>
>> num=[5];
>> [AR,def,w]=bode(num,den);
>> subplot(211);
>> loglog(w,AR);
>> subplot(212);
>> semilogx(w,def);
>> semilogx(w,def);
>> clear
>>
>>
>> num=[5];
>> [AR,def,w]=bode(num,den);
>> subplot(211);
>> loglog(w,AR);
>> subplot(212);
>> semilogx(w,def);
>>
>>
>> k=1;
>> td=2;
>> G1=tf([1],'inputdelay',td);
>> G=G2
>> G=G1
Transfer function:
exp(-2*s) * (1)
>> [AR,defa,w]=bode(G);
>> AR=AR(1,:);
>> defa=defa(1,:);
>> subplot(211);
>> grid
>> loglog(w,AR);
>> ylabel('Diagrama de Amplitud');
>> subplot(212);
>> semilogx(w,defa);
>> ylabel('Defasamiento');
>> xlabel('Frecuencia');
>>
>>
>> k=1;
>> td=0;
>> G=k*G1*G2;
>> [AR,defa,w]=bode(G);
>> AR=AR(1,:);
>> defa=defa(1,:);
>> subplot(211);
>> loglog(w,AR);
>> subplot(212);
>> semilogx(w,defa);
>> ylabel('Defasamiento');
>> xlabel('Frecuencia');
>> semilogx(w,defa);
>> xlabel('Frecuencia');
>> ylabel('Defasamiento');
>>
>>
>>
>> k=1;
>> td=0;
>> G=k*G1*G2;
>> [AR,defa,w]=bode(G);
>> AR=AR(1,:);
>> defa=defa(1,:);
>> subplot(211);
>> loglog(w,AR);
>> subplot(212);
>> semilogx(w,defa);
>> ylabel('Defasamiento');
>> xlabel('Frecuencia');
>>
>>
>> k=1
k=
>> g1=tf([1],[1])
Transfer function:
>> g2=tf([1],[2])
Transfer function:
0.5
Transfer function:
---
2s
Transfer function:
2s
>> k=5
k=
>> gt=k*g1*g2*g3
Transfer function:
10 s
----
2s
>> [AR,defa,w]=bode(G);
>> AR=AR(1,:);
>> defa=defa(1,:);
>> subplot(211);
>> loglog(w,AR);
>> subplot(212);
>> semilogx(w,defa);
>> ylabel('Defasamiento');
>> xlabel('Frecuencia');
>> ga=k*g1
Transfer function:
>> gb=k*g2
Transfer function:
---
2s
>> gc=k*g3
Transfer function:
10 s
>> gt=ga+gb+gc
Transfer function:
20 s^2 + 10 s + 5
-----------------
2s
>> [AR,defa,w]=bode(G);
>> AR=AR(1,:);
>> defa=defa(1,:);
>> subplot(211);
>> loglog(w,AR);
>> subplot(212);
>> semilogx(w,defa);
>> ylabel('Defasamiento');
>> xlabel('Frecuencia');
>>
>>
>>
>>
>> num=[10];
>> G=tf(num,den);
>> grid;
>>
>>
>> num=[5];
>> G=tf(num,den);
>> plot(re,img)
>> grid;
>>
>>
>>
>> num=[5];
>> G=tf(num,den);
>> plot(re,img)
>> grid;
>>
>>
>>
>>
>>
>> k=1;
>> td=0;
-----
s+3
>> G=k*G1*G2
Transfer function:
10
----------------
5 s^2 + 16 s + 3
>> re=re(1,:);
>> img=img(1,:);
>> plot(re,img)
>> grid;
>>
>>
>>
>> k=1;
>> td=1;
Transfer function:
10
-----
s+1
>> G2=tf([1],[1 3],'inputdealy',td);
>> G=k*G1*G2
Transfer function:
10
exp(-1*s) * -------------
s^2 + 4 s + 3
>> re=re(1,:);
>> img=img(1,:);
>> plot(re,img)
>> k=1;
>> grid;
>>
>>
>> k=1;
>> td=0.2;}
??? td=0.2;}
>> clear
>> k=1;
>> td=0.2;
>> ga=4
ga =
4
>> gb=1
gb =
>> gc=tf([1],[0.25])
Transfer function:
Transfer function:
Transfer function:
--------
s + 0.25
Transfer function:
1
----------
0.25 s + 1
Transfer function:
------
0.25 s
>> gt=ga(gb+gc)
>> gt=ga*gb+gc
Transfer function:
s+1
------
0.25 s
>> gt=gb+gc
Transfer function:
0.25 s + 1
----------
0.25 s
>> gs=ga*gt
Transfer function:
s+4
------
0.25 s
>> clear
>> k=1;
>> td=0.2;
Transfer function:
s+4
------
0.25 s
Transfer function:
10
---------
0.1 s + 1
Transfer function:
-------
2s+1
>> Go=tf([1],[1 1],'inputdelay',td)
Transfer function:
exp(-0.2*s) * -----
s+1
Transfer function:
---------
0.5 s + 1
>> gol=Gm*Go*Gp*Gf*Gc
Transfer function:
100 s + 400
exp(-0.2*s) * ------------------------------------------------------
>> re=re(1,:);
>> img=img(1,:);
??? Undefined variable img.
>> plot(re,img)
>> re=re(1,:);
>> img=img(1,:);
>> plot(re,img)
>> grid;
>> k=1;
>> k=1;
>> k=1;
>> k=1;
>> clear
>>
>>
>>
>> k=1;
>> td=0.2;
Transfer function:
s+4
------
0.25 s
10
---------
0.1 s + 1
Transfer function:
-------
2s+1
Transfer function:
exp(-0.2*s) * -----
s+1
Transfer function:
---------
0.5 s + 1
>> gol=Gm*Go*Gp*Gf*Gc
Transfer function:
100 s + 400
exp(-0.2*s) * ------------------------------------------------------
>> [AR,def,w]=bode(gol);
>> AR=AR(1,:);
>> defa=defa(1,:);
>> def=def(1,:);
>> subplot(211);
>> loglog(w,AR);
>> subplot(212);
>> semilogx(w,defa);
>> ylabel('Defasamiento');
>> xlabel('Frecuencia');
>> semilogx(w,def);
>> ylabel('Defasamiento');
>> xlabel('Frecuencia');
>>