summaryrefslogtreecommitdiff
path: root/104/CH4
diff options
context:
space:
mode:
Diffstat (limited to '104/CH4')
-rwxr-xr-x104/CH4/EX4.1/4_1.sce17
-rwxr-xr-x104/CH4/EX4.2/4_2.sce28
-rwxr-xr-x104/CH4/EX4.3/4_3.sce13
-rwxr-xr-x104/CH4/EX4.4/4_4.sce12
-rwxr-xr-x104/CH4/EX4.5/4_5.sce19
-rwxr-xr-x104/CH4/EX4.9/4_9.sce16
6 files changed, 105 insertions, 0 deletions
diff --git a/104/CH4/EX4.1/4_1.sce b/104/CH4/EX4.1/4_1.sce
new file mode 100755
index 000000000..1c1c5589d
--- /dev/null
+++ b/104/CH4/EX4.1/4_1.sce
@@ -0,0 +1,17 @@
+//transfer function of the system
+//from state diagram in 4-1(b)
+//initial conditions are taken as zero
+//considering voltage across capacitor as output
+syms R L C
+s=%s
+M1=(1/L)*(s^-1)*(1/C)*(s^-1)
+L11=-(s^-1)*(R/L)
+delta=1-(L11)
+delta1=1
+x=M1*delta1/delta
+disp(x,"Ec(s)/E(s)=")
+//considering current in the circuit as output
+M1=(1/L)*(s^-1)
+delta1=1
+y=M1*delta1/delta
+disp(y,"I(s)/E(s)=") \ No newline at end of file
diff --git a/104/CH4/EX4.2/4_2.sce b/104/CH4/EX4.2/4_2.sce
new file mode 100755
index 000000000..b995d1ea0
--- /dev/null
+++ b/104/CH4/EX4.2/4_2.sce
@@ -0,0 +1,28 @@
+//transfer function of electric network
+//from state diagram in 4-2(b)
+//inital conditions are taken as zero
+//considering i1 as output
+syms R1 R2 L1 L2 C
+s=%s
+M1=(1/L1)*(s^-1)
+L11=-(s^-1)*(R1/L1)
+L21=-(s^-1)*(1/C)*(s^-1)*(1/L1)
+L31=-(s^-1)*(1/L2)*(s^-1)*(1/C)
+L41=-(s^-1)*(R2/L2)
+L12=L11*L31
+L22=L11*L41
+L32=L21*L41
+delta=1-(L11+L21+L31+L41)+(L12+L22+L32)
+delta1=1-(L31+L41)
+x=M1*delta1/delta
+disp(x,"I1(s)/E(s)=")
+//considering i2 as output
+M1=(1/L1)*(s^-1)*(1/C)*(s^-1)*(1/L2)*(s^-1)
+delta1=1
+y=M1*delta1/delta
+disp(y,"I2(s)/E(s)=")
+//considering voltage across capacitor as output
+M1=(1/L1)*(s^-1)*(1/C)*(s^-1)
+delta1=1-L41
+z=M1*delta1/delta
+disp(z,"Ec(s)/E(s)=")
diff --git a/104/CH4/EX4.3/4_3.sce b/104/CH4/EX4.3/4_3.sce
new file mode 100755
index 000000000..d9a37e6ef
--- /dev/null
+++ b/104/CH4/EX4.3/4_3.sce
@@ -0,0 +1,13 @@
+//gear trains
+printf("Given \n inertia(J2)=0.05oz-in.-sec^2 \n frictional torque(T2)=2oz-in. \n N1/N2(r)=1/5")
+J2=0.05;
+disp(J2,"J2=")
+T2=2;
+disp(T2,"T2=")
+r=1/5
+disp(r,"N1/N2=")
+printf("J1=(N1/N2)^2*J2 \n T1=(N1/N2)*T2")
+J1=(r)^2*J2;
+disp(J1,"The reflected inertia on side of N1=")
+T1=(r)*T2
+disp(T1,"The reflected coulumb friction is=") \ No newline at end of file
diff --git a/104/CH4/EX4.4/4_4.sce b/104/CH4/EX4.4/4_4.sce
new file mode 100755
index 000000000..ccc63f44d
--- /dev/null
+++ b/104/CH4/EX4.4/4_4.sce
@@ -0,0 +1,12 @@
+//mass-spring system
+//free body diagram and state diagram are drawn as shown in figure 4-18(b) and 4-18(c)
+//applying gain formula to state diagram
+syms K M B
+s=%s
+M1=(1/M)*(s^-2)
+L11=-(B/M)*(s^-1)
+L21=-(K/M)*(s^-2)
+delta=1-(L11+L21)
+delta1=1
+x=M1*delta1/delta
+disp(x,"Y(s)/F(s)=") \ No newline at end of file
diff --git a/104/CH4/EX4.5/4_5.sce b/104/CH4/EX4.5/4_5.sce
new file mode 100755
index 000000000..62210081f
--- /dev/null
+++ b/104/CH4/EX4.5/4_5.sce
@@ -0,0 +1,19 @@
+//mass-spring system
+//free body diagram and state diagram are drawn as shown in figure 4-19(b) and 4-19(c)
+//applying gain formula to state diagram
+syms K M B
+s=%s
+//considering y1 as output
+M1=(1/M)
+L11=-(B/M)*(s^-1)
+L21=-(K/M)*(s^-2)
+L31=(K/M)*(s^-2)
+delta=1-(L11+L21+L31)
+delta1=1-(L11+L21)
+x=M1*delta1/delta
+disp(x,"Y1(s)/F(s)=")
+//considering y2 as output
+M1=(1/K)*(K/M)*(s^-2)
+delta1=1
+y=M1*delta1/delta
+disp(y,"Y2(s)/F(s)=")
diff --git a/104/CH4/EX4.9/4_9.sce b/104/CH4/EX4.9/4_9.sce
new file mode 100755
index 000000000..23b72d3a4
--- /dev/null
+++ b/104/CH4/EX4.9/4_9.sce
@@ -0,0 +1,16 @@
+//incremental encoder
+//2 sinusoidal signals
+//generates four zero crossings per cycle(zc)
+//printwheel has 96 characters on its pheriphery(ch) and encoder has 480 cycles(cyc)
+zc=4
+ch=96
+cyc=480
+zcpr=cyc*zc //zero crossings per revolution
+disp(zcpr,"zero_crossings_per_revolution=")
+zcpc=zcpr/ch //zreo crossings per character
+disp(zcpc,"zero_crossings_per_character=")
+//500khz clock is used
+//500 pulses/zero crossing
+shaft_speed=500000/500
+x=shaft_speed/zcpr
+disp(x,"ans=") //in rev per sec