Mercurial > hg > octave-lyh
diff scripts/control/base/rldemo.m @ 4771:b8105302cfe8
[project @ 2004-02-16 17:45:50 by jwe]
author | jwe |
---|---|
date | Mon, 16 Feb 2004 17:45:50 +0000 |
parents | 7923abdeb4e5 |
children | bdbee5282954 |
line wrap: on
line diff
--- a/scripts/control/base/rldemo.m +++ b/scripts/control/base/rldemo.m @@ -44,7 +44,7 @@ clc disp("Display continuous system's open loop poles and zeros (pzmap)\n"); disp("Example #1, Consider the following continuous transfer function:"); - cmd = "sys1 = tf2sys([1.5, 18.5, 6], [1, 4, 155, 302, 5050]);"; + cmd = "sys1 = tf([1.5, 18.5, 6], [1, 4, 155, 302, 5050]);"; disp(cmd); eval(cmd); cmd ="sysout(sys1);"; @@ -61,7 +61,7 @@ clc disp("Example #2, Consider the following set of poles and zeros:"); - cmd = "sys2 = zp2sys([-1, 5, -23],[-1, -10, -7+5i, -7-5i],5);"; + cmd = "sys2 = zp([-1, 5, -23],[-1, -10, -7+5i, -7-5i],5);"; disp(cmd); eval(cmd); cmd = "sysout(sys2);"; @@ -76,7 +76,7 @@ clc disp("Example #3, Consider the following state space system:\n"); - cmd = "sys3=ss2sys([0, 1; -10, -11], [0; 1], [0, -2], 1);"; + cmd = "sys3=ss([0, 1; -10, -11], [0; 1], [0, -2], 1);"; disp(cmd); eval(cmd); cmd = "sysout(sys3);"; @@ -105,7 +105,7 @@ cmd = "Tsam = 1;"; run_cmd; disp("Example #1, Consider the following discrete transfer function:"); - cmd = "sys1 = tf2sys([1.05, -0.09048], [1, -2, 1],Tsam);"; + cmd = "sys1 = tf([1.05, -0.09048], [1, -2, 1],Tsam);"; disp(cmd); eval(cmd); cmd ="sysout(sys1);"; @@ -122,7 +122,7 @@ clc disp("Example #2, Consider the following set of discrete poles and zeros:"); - cmd = "sys2 = zp2sys(-0.717, [1, -0.368], 3.68, Tsam);"; + cmd = "sys2 = zp(-0.717, [1, -0.368], 3.68, Tsam);"; disp(cmd); eval(cmd); cmd = "sysout(sys2);"; @@ -137,7 +137,7 @@ clc disp("Example #3, Consider the following discrete state space system:\n"); - cmd = "sys3=ss2sys([1, 0.0952; 0, 0.905], [0.00484; 0.0952], [1, 0], 0, Tsam);"; + cmd = "sys3=ss([1, 0.0952; 0, 0.905], [0.00484; 0.0952], [1, 0], 0, Tsam);"; disp(cmd); eval(cmd); cmd = "sysout(sys3);"; @@ -163,7 +163,7 @@ clc disp("Display root locus of a continuous SISO system (rlocus)\n") disp("Example #1, Consider the following continuous transfer function:"); - cmd = "sys1 = tf2sys([1.5, 18.5, 6],[1, 4, 155, 302, 5050]);"; + cmd = "sys1 = tf([1.5, 18.5, 6],[1, 4, 155, 302, 5050]);"; disp(cmd); eval(cmd); cmd ="sysout(sys1);"; @@ -186,7 +186,7 @@ clc disp("Example #2, Consider the following set of poles and zeros:"); - cmd = "sys2 = zp2sys([],[0, -20, -2, -0.1],5);"; + cmd = "sys2 = zp([],[0, -20, -2, -0.1],5);"; disp(cmd); eval(cmd); cmd = "sysout(sys2);"; @@ -201,7 +201,7 @@ clc disp("Example #3, Consider the following state space system:\n"); - cmd = "sys3=ss2sys([0, 1; -10, -11], [0; 1], [0, -2], 0);"; + cmd = "sys3=ss([0, 1; -10, -11], [0; 1], [0, -2], 0);"; disp(cmd); eval(cmd); cmd = "sysout(sys3);"; @@ -233,7 +233,7 @@ cmd = "Tsam = 1;"; run_cmd; disp("Example #1, Consider the following discrete transfer function:"); - cmd = "sys1 = tf2sys([1.05, -0.09048],[1, -2, 1],Tsam);"; + cmd = "sys1 = tf([1.05, -0.09048],[1, -2, 1],Tsam);"; disp(cmd); eval(cmd); cmd ="sysout(sys1);"; @@ -256,7 +256,7 @@ clc disp("Example #2, Consider the following set of discrete poles and zeros:"); - cmd = "sys2 = zp2sys(-0.717, [1, -0.368], 3.68, Tsam);"; + cmd = "sys2 = zp(-0.717, [1, -0.368], 3.68, Tsam);"; disp(cmd); eval(cmd); cmd = "sysout(sys2);"; @@ -273,7 +273,7 @@ clc disp("Example #3, Consider the following discrete state space system:\n"); - cmd = "sys3=ss2sys([1, 0.0952; 0, 0.905], [0.00484; 0.0952], [1, 0], 0, Tsam);"; + cmd = "sys3=ss([1, 0.0952; 0, 0.905], [0.00484; 0.0952], [1, 0], 0, Tsam);"; disp(cmd); eval(cmd); cmd = "sysout(sys3);";