summaryrefslogtreecommitdiff
path: root/1151/CH2
diff options
context:
space:
mode:
authorpriyanka2015-06-24 15:03:17 +0530
committerpriyanka2015-06-24 15:03:17 +0530
commitb1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch)
treeab291cffc65280e58ac82470ba63fbcca7805165 /1151/CH2
downloadScilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.gz
Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.bz2
Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.zip
initial commit / add all books
Diffstat (limited to '1151/CH2')
-rwxr-xr-x1151/CH2/EX2.1/example1.sce11
-rwxr-xr-x1151/CH2/EX2.10/example10.sce12
-rwxr-xr-x1151/CH2/EX2.11/example11.sce17
-rwxr-xr-x1151/CH2/EX2.12/example12.sce9
-rwxr-xr-x1151/CH2/EX2.13/example13.sce8
-rwxr-xr-x1151/CH2/EX2.14/example14.sce12
-rwxr-xr-x1151/CH2/EX2.15/example15.sce25
-rwxr-xr-x1151/CH2/EX2.16/example16.sce7
-rwxr-xr-x1151/CH2/EX2.17/example17.sce14
-rwxr-xr-x1151/CH2/EX2.18/example18.sce9
-rwxr-xr-x1151/CH2/EX2.19/example19.sce7
-rwxr-xr-x1151/CH2/EX2.20/example20.sce7
-rwxr-xr-x1151/CH2/EX2.22/example22.sce13
-rwxr-xr-x1151/CH2/EX2.23/example23.sce10
-rwxr-xr-x1151/CH2/EX2.24/example24.sce16
-rwxr-xr-x1151/CH2/EX2.25/example25.sce8
-rwxr-xr-x1151/CH2/EX2.3/example3.sce7
-rwxr-xr-x1151/CH2/EX2.4/example4.sce7
-rwxr-xr-x1151/CH2/EX2.5/example5.sce12
-rwxr-xr-x1151/CH2/EX2.6/example6.sce11
-rwxr-xr-x1151/CH2/EX2.8/example8.sce11
-rwxr-xr-x1151/CH2/EX2.9/example9.sce10
22 files changed, 243 insertions, 0 deletions
diff --git a/1151/CH2/EX2.1/example1.sce b/1151/CH2/EX2.1/example1.sce
new file mode 100755
index 000000000..b90889e7a
--- /dev/null
+++ b/1151/CH2/EX2.1/example1.sce
@@ -0,0 +1,11 @@
+//determine rise time,peak time,setlling time and peak overshoot
+delta=0.5 // damping ratio
+w=6//rad/sec
+rt=(%pi-atan(sqrt((1-delta)/delta)))/(w*sqrt(1-delta^2));
+disp(rt,"the rise time is ")//seconds
+pt=%pi/(w*sqrt(1-delta^2));
+disp(pt,"peak time is")//seconds
+st=4/(delta*w);
+mo=exp((-%pi*delta)/sqrt(1-delta^2))*100;
+disp(st,"settling time(in seconds)")
+disp(mo,"maximum overshoot(in %)")
diff --git a/1151/CH2/EX2.10/example10.sce b/1151/CH2/EX2.10/example10.sce
new file mode 100755
index 000000000..27edd2158
--- /dev/null
+++ b/1151/CH2/EX2.10/example10.sce
@@ -0,0 +1,12 @@
+printf("closed loop transfer function =K/(s^2+K*H*s+K))");
+printf("characterstic equation of the given system is s^2+K*H*s+K=0");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+d1=log(0.25);
+d=sqrt(d1^2/(d1^2+%pi^2));
+w=%pi/(2*sqrt(1-d^2));
+K=w^2;
+H=2*d*w/K;
+disp(d,"damping ratio=");
+disp(w,"undamped natural frequency(in rad/sec)=");
+disp(K,"value of K=");
+disp(H,"value of H=");
diff --git a/1151/CH2/EX2.11/example11.sce b/1151/CH2/EX2.11/example11.sce
new file mode 100755
index 000000000..1576d394f
--- /dev/null
+++ b/1151/CH2/EX2.11/example11.sce
@@ -0,0 +1,17 @@
+printf("the second order control system has transfer function Q(s)/T(s)=1/(J*s^2+f*s+k)");
+printf("given T(s)= 10/s");
+printf("Q(s)=1/(s*(J*s^2+f*s+k)");
+printf("characterstic equation of the given system is J*s^2+f*s+k =0");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+k=10/0.5;
+d1=log(0.06);
+d=sqrt(d1^2/(d1^2+%pi^2));
+w=%pi/sqrt(1-d^2);
+j=k/w^2;
+f=2*d*w*j;
+disp(d,"damping ratio=");
+disp(w,"undamped natural frequency(in rad/sec)=");
+disp(k,"value of K=");
+disp(j,"value of J=");
+disp(f,"value of f=");
+
diff --git a/1151/CH2/EX2.12/example12.sce b/1151/CH2/EX2.12/example12.sce
new file mode 100755
index 000000000..fdcd3ffaf
--- /dev/null
+++ b/1151/CH2/EX2.12/example12.sce
@@ -0,0 +1,9 @@
+printf("closed loop transfer function =16/(s^2+(4+16*K)*s+16)");
+printf("characterstic equation of the given system is 4+16*K)*s+16=0");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+w=sqrt(16);
+d=0.8;//given
+k=(2*d*w-4)/16;
+mo=exp((-%pi*d)/sqrt(1-d^2))*100;
+disp(k,"value of K=");
+disp(mo,"maximum overshoot(in %)");
diff --git a/1151/CH2/EX2.13/example13.sce b/1151/CH2/EX2.13/example13.sce
new file mode 100755
index 000000000..8ba6dd74a
--- /dev/null
+++ b/1151/CH2/EX2.13/example13.sce
@@ -0,0 +1,8 @@
+ clc;printf("closed loop transfer function =(K/T)/(s^2+s/T+K/T))");
+printf("characterstic equation of the given system is s^2+s/T+K/T=0");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+d2=0.9;
+d1=0.3;
+c=(d1/d2)^2;
+disp(c,"K1/K2=")
+printf("hence,the gain K1 at which d=0.3 should be multiplied by 1/9 in order to increase the damping ratio from 0.3 to 0.9");
diff --git a/1151/CH2/EX2.14/example14.sce b/1151/CH2/EX2.14/example14.sce
new file mode 100755
index 000000000..a158107f5
--- /dev/null
+++ b/1151/CH2/EX2.14/example14.sce
@@ -0,0 +1,12 @@
+ clc;printf("closed loop transfer function =(K/T)/(s^2+s/T+K/T))");
+printf("characterstic equation of the given system is s^2+s/T+K/T=0");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+d1=log(0.254);
+d=sqrt(d1^2/(d1^2+%pi^2));
+w=%pi/(3*sqrt(1-d^2));
+t=1/(2*d*w);
+k=w^2*t;
+disp(d,"damping ratio=");
+disp(w,"undamped natural frequency(in rad/sec)=");
+disp(k,"value of K=");
+disp(t,"value of T=");
diff --git a/1151/CH2/EX2.15/example15.sce b/1151/CH2/EX2.15/example15.sce
new file mode 100755
index 000000000..f468b1077
--- /dev/null
+++ b/1151/CH2/EX2.15/example15.sce
@@ -0,0 +1,25 @@
+printf("closed loop transfer function =16/(s^2+s+16)");
+printf("characterstic equation of the given system is s^2+s+16=0");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+w=sqrt(16);
+d=0.5/w;
+disp(d,"damping ratio=");
+disp(w,"undamped natural frequency(in rad/sec)=");
+printf("now consider H(s)=1+Ks");
+printf("characterstic equation of this system is s^2+(1+16K)*s+16=0");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+d1=0.6;
+k=(2*w*d1-1)/16;
+disp(k," value of K when d=0.6 is")
+pt1=%pi/(w*sqrt(1-d^2));
+pt2=%pi/(w*sqrt(1-d1^2));
+mo1=exp((-%pi*d)/sqrt(1-d^2))*100;
+mo2=exp((-%pi*d1)/sqrt(1-d1^2))*100;
+st1=4/(d*w);
+st2=4/(d1*w);
+disp(pt1,"peak time (in sec) when damping ratio is 0.125:");
+disp(pt2,"peak time(in sec) when damping ratio is 0.6:");
+disp(mo1,"mAXIMUM OVERSHOOT (in %) when damping ratio is 0.125:");
+disp(mo2,"mAXIMUM OVERSHOOT (in %) when damping ratio is 0.6:");
+disp(st1,"setlling time(in sec) when damping ratio is 0.125:");
+disp(st2,"setlling time (in sec) when damping ratio is 0.:");
diff --git a/1151/CH2/EX2.16/example16.sce b/1151/CH2/EX2.16/example16.sce
new file mode 100755
index 000000000..429dea3c3
--- /dev/null
+++ b/1151/CH2/EX2.16/example16.sce
@@ -0,0 +1,7 @@
+printf(" given d1=0.8 and d2=0.2");
+printf(" we have to dtermine the time constant T for which the damping ratio is reduced from 0.8 to 0.2");
+d1=0.8;
+d2=0.2;
+c=d1/d2;
+disp(c^2,"T2/T1=");
+printf("hence, the original time constant T1 should be multiplied by 16, then the damping ratio becomes 0.2");
diff --git a/1151/CH2/EX2.17/example17.sce b/1151/CH2/EX2.17/example17.sce
new file mode 100755
index 000000000..b4536643c
--- /dev/null
+++ b/1151/CH2/EX2.17/example17.sce
@@ -0,0 +1,14 @@
+printf("closed loop transfer function =16/(s^2+(0.8+16K)*s+16");
+printf("characterstic equation of this system is s^2+(0.8+16K)*s+16=0");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+w=sqrt(16);
+d=0.5;
+k=(2*w*d-0.8)/16;
+rt=(%pi-atan(sqrt((1-d)/d)))/(w*sqrt(1-d^2));
+pt1=%pi/(w*sqrt(1-d^2));
+mo1=exp((-%pi*d)/sqrt(1-d^2))*100;
+st1=4/(d*w);
+disp(k," value of K is");
+disp(pt1,"peak time (in sec) :");
+disp(mo1,"mAXIMUM OVERSHOOT (in %) :");
+disp(st1,"setlling time(in sec):");
diff --git a/1151/CH2/EX2.18/example18.sce b/1151/CH2/EX2.18/example18.sce
new file mode 100755
index 000000000..ec53d3f27
--- /dev/null
+++ b/1151/CH2/EX2.18/example18.sce
@@ -0,0 +1,9 @@
+printf("closed loop transfer function =K/(s^2+(2+kK)*s+K) withd=0.7 and w=4 rad/sec");
+printf("characterstic equation of this system is s^2+(2+kK)*s+K=0");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+w=4;
+K=w^2;
+d=0.7;
+k=(2*d*w-2)/K;
+disp(K,"Value of K is");
+disp(k,"Value of k is");
diff --git a/1151/CH2/EX2.19/example19.sce b/1151/CH2/EX2.19/example19.sce
new file mode 100755
index 000000000..a2eccf2eb
--- /dev/null
+++ b/1151/CH2/EX2.19/example19.sce
@@ -0,0 +1,7 @@
+printf ("time required ny the thermometer to indicate 9805 of the response to a step input=1 minute=60 seconds");
+printf("for 1st order sytem \n c(t)=1-e^(-t/T)\n we have to find time constant T");
+c=0.98;
+d=1-c;
+f=log(d);
+h=-60/f;
+disp(h,"time constant T (in sec)=");
diff --git a/1151/CH2/EX2.20/example20.sce b/1151/CH2/EX2.20/example20.sce
new file mode 100755
index 000000000..55df0d043
--- /dev/null
+++ b/1151/CH2/EX2.20/example20.sce
@@ -0,0 +1,7 @@
+printf("closed loop transfer function =10/(s^2+(1+10K)*s+10) with d=0.5" );
+printf("characterstic equation of this system is s^2+(1+10K)*s+10=0");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+d=0.5;
+w=sqrt(10);
+k=(2*d*w-1)/10;
+disp(k,"Value of K is");
diff --git a/1151/CH2/EX2.22/example22.sce b/1151/CH2/EX2.22/example22.sce
new file mode 100755
index 000000000..099d83e61
--- /dev/null
+++ b/1151/CH2/EX2.22/example22.sce
@@ -0,0 +1,13 @@
+printf("closed loop transfer function =1/s(s+1)");
+printf("characterstic equation of this system is s^2+s+1=0");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+w=1;
+d=0.5/w;
+rt=(%pi-atan(sqrt((1-d)/d)))/(w*sqrt(1-d^2));
+pt1=%pi/(w*sqrt(1-d^2));
+mo1=exp((-%pi*d)/sqrt(1-d^2))*100;
+st1=4/(d*w);
+disp(k," value of K is");
+disp(pt1,"peak time (in sec) :");
+disp(mo1,"mAXIMUM OVERSHOOT (in %) :");
+disp(st1,"setlling time(in sec):");
diff --git a/1151/CH2/EX2.23/example23.sce b/1151/CH2/EX2.23/example23.sce
new file mode 100755
index 000000000..dadde6f2d
--- /dev/null
+++ b/1151/CH2/EX2.23/example23.sce
@@ -0,0 +1,10 @@
+printf("closed loop transfer function C(s)/R(s)=w^2/(s^2+2*d*w*s+w^2)");
+printf("characterstic equation of this system is s^2+2*d*w*s+w^2=0");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+printf("we have to determine w and d given maximum overshoot=0.05 and settling time =2 sec");
+t=2;
+d1=log(0.05);
+d=sqrt(d1^2/(d1^2+%pi^2));
+w=4/(d*t);
+disp(d,"damping ratio:");
+disp(w,"natural undamped frequency (in rad/sec):")
diff --git a/1151/CH2/EX2.24/example24.sce b/1151/CH2/EX2.24/example24.sce
new file mode 100755
index 000000000..f7e255738
--- /dev/null
+++ b/1151/CH2/EX2.24/example24.sce
@@ -0,0 +1,16 @@
+printf("given G(s)=K/(s*(1+s*T)) \n Mp=20 percent \n resonant frequency=6 rad/sec\n we have to determine the value of K,T,resonant peak")
+printf(" H(s)=1 \n C(s)/R(s)=G(s)/(1+G(s)*H(s)) \n =(K/T)/(s^2+s/T+(K/T)");
+printf("compare with w^2/(s^2+2*d*w*s+w^2)");
+d1=log(0.2);
+d=sqrt(d1^2/(d1^2+%pi^2));
+wr=6;
+w=wr/sqrt(1-(2*(d^2)));
+K=sqrt(4*d*w^2);
+T=sqrt(4*d/w^2);
+mr=1/(2*d*sqrt(1-d^2));
+disp(w,"undamped natural frequency (in rad/sec)=")
+disp(d,"damping ratio=")
+disp(K,"value of K=")
+disp(T,"value of T=")
+disp(mr,"resonance peak=")
+
diff --git a/1151/CH2/EX2.25/example25.sce b/1151/CH2/EX2.25/example25.sce
new file mode 100755
index 000000000..41036b583
--- /dev/null
+++ b/1151/CH2/EX2.25/example25.sce
@@ -0,0 +1,8 @@
+printf("given c(t)=1+0.2^e-60t-1.2*e^-10t");
+printf("Laplace transform is C(s)=600/(s*(s+10)*(s+60))\n R(s)=1/s \n transfer function is C(s)/R(s)=600/((s+2)*(s+60))");
+printf("characterstic equation of this system is s^2+70*s+600=0");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+w=sqrt(600);
+d=70/(2*w);
+disp(d,"damping ratio:");
+disp(w,"natural undamped frequency (in rad/sec):")
diff --git a/1151/CH2/EX2.3/example3.sce b/1151/CH2/EX2.3/example3.sce
new file mode 100755
index 000000000..8ca7c33c7
--- /dev/null
+++ b/1151/CH2/EX2.3/example3.sce
@@ -0,0 +1,7 @@
+//time requiredto get second peak
+
+printf("c(s)=25/(s*(s^2+8*s+25))");
+w=sqrt(25);
+d=0.8;
+t=3*%pi/(w*sqrt(1-d^2));
+disp(t,"required time");
diff --git a/1151/CH2/EX2.4/example4.sce b/1151/CH2/EX2.4/example4.sce
new file mode 100755
index 000000000..68c8194e8
--- /dev/null
+++ b/1151/CH2/EX2.4/example4.sce
@@ -0,0 +1,7 @@
+printf("C(s)=16/(s^2+(0.8+16a)*s+16)");
+w=sqrt(16);delta=0.5;
+a=(2*d*w-0.8)/16;
+t=(%pi-atan(sqrt((1-delta)/delta)))/(w*sqrt(1-delta^2));
+mo=exp((-%pi*delta)/sqrt(1-delta^2))*100;
+disp(t,"the rise time (in seconds)is ")//seconds
+disp(mo,"maximum overshoot(in%)")
diff --git a/1151/CH2/EX2.5/example5.sce b/1151/CH2/EX2.5/example5.sce
new file mode 100755
index 000000000..032514139
--- /dev/null
+++ b/1151/CH2/EX2.5/example5.sce
@@ -0,0 +1,12 @@
+printf("closed loop transfer function =G/(s^2+3*s+G)");
+printf("characterstic equation of the given system is s^2+3*s+G=0");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+d=0.6;//assume
+G=(1.5/d)^2;
+G'=2*G;
+w=sqrt(G');
+d'=1.5/w;
+w'=w*sqrt(1-d'^2);
+t=2*%pi/w';
+disp(G,"the minimum value of G for the step response of the system that it will exhibit an overshoot is");
+disp(t,"if G is twice the minimum value then time period T(in sec)= ")
diff --git a/1151/CH2/EX2.6/example6.sce b/1151/CH2/EX2.6/example6.sce
new file mode 100755
index 000000000..61349a9c4
--- /dev/null
+++ b/1151/CH2/EX2.6/example6.sce
@@ -0,0 +1,11 @@
+printf("open loop transfer function G(s)=10/((s+2)*(s+5))");
+printf("for unity feedback system H(s)=1")
+printf("characterstic equation of closed loop system is 1+G(s)H(s)=0");
+printf("characterstic equation of the given system is s^2+7*s+");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+w=sqrt(20);
+d=7/(2*w);
+mo=exp((-%pi*d)/sqrt(1-d^2))*100;
+disp(d,"damping ratio=");
+disp(w,"undamped natural frequency(in rad/sec)=")
+disp(mo,"maximum overshoot(in %)")
diff --git a/1151/CH2/EX2.8/example8.sce b/1151/CH2/EX2.8/example8.sce
new file mode 100755
index 000000000..05b386c88
--- /dev/null
+++ b/1151/CH2/EX2.8/example8.sce
@@ -0,0 +1,11 @@
+ printf("closed loop transfer function =K/(s^2+s/T+K/T))");
+printf("characterstic equation of the given system is s^2+s/T+K/T=0");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+m1=.75;
+m2=.25;
+t1=-log(m1);
+t2=-log(m2);
+c=t1/t2;
+d1=.4037;d2=.09118;
+e=d1/d2;
+disp(e^2,"K1/K2=");
diff --git a/1151/CH2/EX2.9/example9.sce b/1151/CH2/EX2.9/example9.sce
new file mode 100755
index 000000000..8a0079a5e
--- /dev/null
+++ b/1151/CH2/EX2.9/example9.sce
@@ -0,0 +1,10 @@
+printf("closed loop transfer function =1/(s^2+R/L*s+1/LC)");
+printf("characterstic equation of the given system is s^2+R/L*s+1/LC=0");
+printf("compare it with the standard second order characterstic equation s^2+2*d*w*s+w^2=0");
+R=1000; //given
+L=10^-2;//given
+C=10^-8;//given
+d=R/2*sqrt(C/L);
+w=1/sqrt(L*C);
+disp(d,"damping ratio=");
+disp(w,"undamped natural frequency(in rad/sec)=");