Professional Documents
Culture Documents
z=
-4
p=
-2.0000 + 4.0000i
-2.0000 - 4.0000i
k=
num =
5 20
den =
4 20
>> G = tf(num,den);
>> G = zpk(z,p,k)
Zero/pole/gain:
5 (s+4)
--------------(s^2 + 4s + 20)
>> p = [1 4 4 1 20]
p=
1 20
r=
-2.6545 + 1.2595i
-2.6545 - 1.2595i
0.6545 + 1.3742i
0.6545 - 1.3742i
>> p=poly([p1,p2,p3,p4]
??? p=poly([p1,p2,p3,p4]
|
Error: Expression or statement is incorrect--possibly unbalanced (, {, or [.
>> p=poly([p1,p2,p3,p4])
??? Undefined function or variable 'p1'.
>> Res{
??? Res{
|
Error: Expression or statement is incorrect--possibly unbalanced (, {, or [.
>> [res,p]=residue(num,den)
res =
2.5000 - 1.2500i
2.5000 + 1.2500i
p=
-2.0000 + 4.0000i
-2.0000 - 4.0000i
>> [res,p,k
>> [res,p,k]=residue(num,den)
res =
2.5000 - 1.2500i
2.5000 + 1.2500i
p=
-2.0000 + 4.0000i
-2.0000 - 4.0000i
k=
[]
>> [num,den]=residue(res,p,k)
num =
5 20
den =
4 20
>> numg1=0.4;
deng1=1
deng1 =
>> numg1=0.4;
deng1=1;
>> numg2=100;
deng2=[1 2 0];
denh2=[1 20];
numvc =
100
2000
denvc =
1 22 140
numec =
0 40 800
denec =
1 22 140
>> [num,den]=cloop(numec,denec,-1)
num =
0 40 800
den =
1 22 180 800
>> impulse(num,den)
>> step(num,den);
>> y=step(num,dent)
??? Undefined function or variable 'dent'.
>> step(num,den)
>> den = [1 0.8 4 0];
>> step(num,den)
PRACTICA 3 Parte2
This is a Classroom License for instructional use only.
Research and commercial use is prohibited.
>> num=[40 800];
>> den[1 22 180 800];
??? den[1 22 180 800];
|
Error: Unbalanced or unexpected parenthesis or bracket.
>> y = step(num,den,t);
>> plot (t,y);
>> title('Respuesta al escalon unitario');
>> xlabel('Tiempo(seg.)');
>> xlabel('Salida del sistema');
>> text (0.5,1.1,'maximo valor');
>> grid
>> t=0:pi/20:2*pi;
>> y1=sin(t);
>> y2=sin(t-pi/2);
>> y3=sin(t-pi);
>> plot (t,y1);
>> hold on;
>> plot (t,y2);
>> plot (t,y3);
>> hold off
>> plot (t,y1,'-.rx');
>> plot (t,y2,'--mo');
>> plot (t,y3,':bs')
>> plot (t,y3,':bs');
>> plot (t,y2,'--mo');
>> plot (t,y1,'-.rx');
>> legend('sin(t)','sin(t-pi/2)','sin(t-pi)')
Warning: Ignoring extra legend entries.
> In legend at 293