diff options
Diffstat (limited to '3673/CH2')
25 files changed, 300 insertions, 0 deletions
diff --git a/3673/CH2/EX2.10/Ex2_10.sce b/3673/CH2/EX2.10/Ex2_10.sce new file mode 100644 index 000000000..f28079e1f --- /dev/null +++ b/3673/CH2/EX2.10/Ex2_10.sce @@ -0,0 +1,8 @@ +//Example 2_10 page no:74
+clc
+//mesh equation for the given circuit is
+resistance=[15,-10,-5;-15,12,6;0,1,-1]
+U=[40.0005,23.3326,-11.3332]
+II=inv(resistance)'*U'//calculating current I1 I2 I3
+current=II(1,1)-II(3,1)
+disp(current,"current flowing through 5 ohms (in ampere)")
diff --git a/3673/CH2/EX2.11/Ex2_11.sce b/3673/CH2/EX2.11/Ex2_11.sce new file mode 100644 index 000000000..189621cd8 --- /dev/null +++ b/3673/CH2/EX2.11/Ex2_11.sce @@ -0,0 +1,10 @@ +//Example 2_11 page no:74
+clc
+//mesh equation for the circuit is
+I1=10;//current in ampere
+resistance=[5,-2;-2,3]
+volt=[20,10]
+current=inv(resistance)'*volt'//calculating current I1 I2 I3
+disp(I1,"the current I1 is (in ampere)")
+disp(current(1),"the current I2 is (in ampere)")
+disp(current(2),"the current I3 is (in ampere)")
diff --git a/3673/CH2/EX2.12/Ex2_12.sce b/3673/CH2/EX2.12/Ex2_12.sce new file mode 100644 index 000000000..ddf9e86a8 --- /dev/null +++ b/3673/CH2/EX2.12/Ex2_12.sce @@ -0,0 +1,22 @@ +//Example 2_12 page no:76
+clc
+//applying kirchoff's law to the given circuit
+R1=10//resistance in ohm
+R2=3//resistance in ohm
+R3=5//resistance in ohm
+R4=1//resistance in ohm
+V=10//source voltage
+resistance=[(1/10+1/3),-1/3;-1/3,(1/3+1/5+1)]
+current=[5,10]
+volt=inv(resistance)'*current'//calculating V1 V2
+disp(volt(1),"voltage across node 1 is (in V)")
+disp(volt(2),"voltage across node 2 is (in V)")
+I1=volt(1,1)/R1;
+disp(I1,"current in branch I10 (in ampere)")
+I2=(volt(1,1)-volt(2,1))/R2;
+disp(I2,"current in branch I3 (in ampere)")
+I3=volt(2,1)/R3
+disp(I3,"current in branch I5 (in ampere)")
+I4=(volt(2,1)-V)/R4
+disp(I4,"current in branch I1 (in ampere)")
+//in textbook node voltages are rounded off so that current in each branches are more approximated in text book so current values varies slightly with textbook
diff --git a/3673/CH2/EX2.13/Ex2_13.sce b/3673/CH2/EX2.13/Ex2_13.sce new file mode 100644 index 000000000..00a225209 --- /dev/null +++ b/3673/CH2/EX2.13/Ex2_13.sce @@ -0,0 +1,10 @@ +//Example 2_13 page no:77
+clc
+//applying kirchhoff's law
+resistance=[0.96,-0.66,0;-0.66,1.16,-0.5;0,-0.5,1.66]
+current=[1,5,0]
+volt=inv(resistance)'*current'//calculating V1 V2 V3
+disp(volt(1),"voltage at node_1 V1 is (in V)")
+disp(volt(2),"voltage at node_2 V2 is (in V)")
+disp(volt(3),"voltage at node_3 V3 is (in V)")
+//values of V1 and V3 varies slightly with text book hence voltages are rounded off in text book calculation
diff --git a/3673/CH2/EX2.15/Ex2_15.sce b/3673/CH2/EX2.15/Ex2_15.sce new file mode 100644 index 000000000..b221bf375 --- /dev/null +++ b/3673/CH2/EX2.15/Ex2_15.sce @@ -0,0 +1,11 @@ +//Example 2_15 page no:81
+clc
+//applying kirchoff law to node 1
+R5=5//resistance in ohm
+V=10//source voltge
+resistance=[0.83,-0.5,0;-0.5,1.5,0.7;0.01,1,-1]
+current=[10,2,20]
+volt=inv(resistance)'*current'//calculating V1 V2 V3
+I3=(volt(3,1)-8.8)/R5
+disp(I3,"current flowing through 5 ohm resistor is (in ampere)")
+disp("negative sign indicate flow of current in opposite direction")
diff --git a/3673/CH2/EX2.16/Ex2_16.sce b/3673/CH2/EX2.16/Ex2_16.sce new file mode 100644 index 000000000..5a90d06e4 --- /dev/null +++ b/3673/CH2/EX2.16/Ex2_16.sce @@ -0,0 +1,6 @@ +//Example 2_16 page no:84
+clc
+current_source=5//in ampere
+source_resistance=5//in ohm
+equ_src_volt=current_source*source_resistance
+disp(equ_src_volt,"equivalent source voltage is (in volt)")
diff --git a/3673/CH2/EX2.17/Ex2_17.sce b/3673/CH2/EX2.17/Ex2_17.sce new file mode 100644 index 000000000..9d4295452 --- /dev/null +++ b/3673/CH2/EX2.17/Ex2_17.sce @@ -0,0 +1,6 @@ +//Example 2_17 page no:84
+clc
+src_volt=50//in volt
+internal_resistance=30//in ohm
+equ_current_src=src_volt/internal_resistance
+disp(equ_current_src,"equivalent current source is (in ampere)")
diff --git a/3673/CH2/EX2.7/Ex2_7.sce b/3673/CH2/EX2.7/Ex2_7.sce new file mode 100644 index 000000000..c8603c397 --- /dev/null +++ b/3673/CH2/EX2.7/Ex2_7.sce @@ -0,0 +1,7 @@ +//Example 2_7 page no:69
+clc
+//mesh current equation for the circuit
+resistance=[7,-2;-2,12]
+volt=[10,-50]
+current=inv(resistance)'*volt'//calculating current I1 I2 I3
+disp(current,"current flowing in the circuit I1 and I2 (in ampere)")
diff --git a/3673/CH2/EX2.8/Ex2_8.sce b/3673/CH2/EX2.8/Ex2_8.sce new file mode 100644 index 000000000..79465d56a --- /dev/null +++ b/3673/CH2/EX2.8/Ex2_8.sce @@ -0,0 +1,9 @@ +//Example 2_8 page no:69
+clc
+//mesh equations for the cirucuit is
+resistance=[18,5,-3;5,8,1;-3,1,4]
+volt=[50,10,-5]
+current=inv(resistance)'*volt'//calculating current I1 I2 I3
+disp(current(1),"the mesh current I1 in the circuit are (in ampere)")
+disp(current(2),"the mesh current I2 in the circuit are (in ampere)")
+disp(current(3),"the mesh current I3 in the circuit are (in ampere)")
diff --git a/3673/CH2/EX2.a.1/Example_a_2_1.sce b/3673/CH2/EX2.a.1/Example_a_2_1.sce new file mode 100644 index 000000000..e858d50d1 --- /dev/null +++ b/3673/CH2/EX2.a.1/Example_a_2_1.sce @@ -0,0 +1,29 @@ +//Example 2_1 page no:85
+clc;
+delta=[3,-1,-1,
+ -1,3,-1,
+ -1,-1,3];
+delta1=[10,-1,-1,
+ 5,3,-1,
+ 5,-1,3];
+delta2=[3,10,-1,
+ -1,5,-1,
+ -1,5,3];
+delta3=[3,-1,10,
+ -1,3,5,
+ -1,-1,5];
+ia=det(delta1)/det(delta);
+ib=det(delta2)/det(delta);
+ic=det(delta3)/det(delta);
+I=ia;
+I1=ia-ib;
+I2=ib;
+I3=ib-ic;
+I4=ic;
+I5=ia-ic;
+disp(I,"the branch current I is (in A)");
+disp(I1,"the branch current I1 is (in A)");
+disp(I2,"the branch current I2 is (in A)");
+disp(I3,"the branch current I3 is (in A)");
+disp(I4,"the branch current I4 is (in A)");
+disp(I5,"the branch current I5 is (in A)");
diff --git a/3673/CH2/EX2.a.10/Example_a_2_10.sce b/3673/CH2/EX2.a.10/Example_a_2_10.sce new file mode 100644 index 000000000..11dbf8873 --- /dev/null +++ b/3673/CH2/EX2.a.10/Example_a_2_10.sce @@ -0,0 +1,14 @@ +//Example 2_10 page no:95
+clc;
+A=[0.34,1.2,-1.34,
+ -0.34,-1,1.83,
+ 1,-1,0];
+B=[3,
+ 0,
+ 10];
+X=inv(A)*B;
+V1=X(1);
+V2=X(2);
+V3=X(3);
+P=V2*5;
+disp(P,"the power delivered by the current source(5A) is (in W)");
diff --git a/3673/CH2/EX2.a.11/Example_a_2_11.sce b/3673/CH2/EX2.a.11/Example_a_2_11.sce new file mode 100644 index 000000000..93467ad37 --- /dev/null +++ b/3673/CH2/EX2.a.11/Example_a_2_11.sce @@ -0,0 +1,7 @@ +//Example 2_11 page no:96
+clc;
+V=50;
+V1=23.33/(0.2+0.5+0.33);
+I=(V-V1)/5;
+P=V*I;
+disp(P,"the power delivered by the 50V voltage source is (in W)");
diff --git a/3673/CH2/EX2.a.12/Example_a_2_12.sce b/3673/CH2/EX2.a.12/Example_a_2_12.sce new file mode 100644 index 000000000..59b253630 --- /dev/null +++ b/3673/CH2/EX2.a.12/Example_a_2_12.sce @@ -0,0 +1,18 @@ +//Example 2_12 page no:96
+clc;
+//current source are parallel so added them up
+I1=5;
+I2=5;
+I3=10;
+I=I1+I2+I3;
+R1=2;
+R2=2;
+R3=3;
+R4=2;
+R5=1;
+R=1/((1/R1)+(1/R2)+(1/R3)+(1/R4)+(1/R5));
+V=I*R;
+disp(V,"the voltage source is (in V)");
+disp(R,"the resistance connected in series is (in ohm)");
+//in text book resistance calculationg is wrong
+//R valus is 0.35
diff --git a/3673/CH2/EX2.a.13/Example_a_2_13.sce b/3673/CH2/EX2.a.13/Example_a_2_13.sce new file mode 100644 index 000000000..46ed9c8fb --- /dev/null +++ b/3673/CH2/EX2.a.13/Example_a_2_13.sce @@ -0,0 +1,14 @@ +//Example 2_13 page no:97
+clc;
+delta=[1.08,-0.75,
+ -4.75,5.75];
+delta1=[-6.25,-0.75,
+ 21.25,5.75];
+delta2=[1.08,-6.25,
+ -4.75,21.25];
+V1=det(delta1)/det(delta);
+V2=det(delta2)/det(delta);
+Vx=V1+5-V2;
+disp(V1,"the voltage V1 is");
+disp(V2,"the voltage V2 is");
+disp(Vx,"the voltage across 4 ohm resistor is (in V)");
diff --git a/3673/CH2/EX2.a.14/Example_a_2_14.sce b/3673/CH2/EX2.a.14/Example_a_2_14.sce new file mode 100644 index 000000000..1a8cc66e4 --- /dev/null +++ b/3673/CH2/EX2.a.14/Example_a_2_14.sce @@ -0,0 +1,5 @@ +//Example 2_14 page no:98
+clc;
+V=48;
+I=(V-30)/5;
+disp(I,"the current in 5ohm resistor is (in A)");
diff --git a/3673/CH2/EX2.a.15/Example_a_2_15.sce b/3673/CH2/EX2.a.15/Example_a_2_15.sce new file mode 100644 index 000000000..34112eb2c --- /dev/null +++ b/3673/CH2/EX2.a.15/Example_a_2_15.sce @@ -0,0 +1,15 @@ +//Example 2_15 page no:99
+clc;
+A=[12,6,-5,
+ -1,1,0,
+ 0,0,1]
+B=[4,
+ 5,
+ -2];
+X=inv(A)*B;
+I1=X(1);
+I2=X(2);
+V2=2*I1;
+P4=4*I2;
+disp(V2,"the voltage across 2 ohm resistor is (in V)");
+disp(P4,"the power delivered by 4V source is (in W)");
diff --git a/3673/CH2/EX2.a.16/Example_a_2_16.sce b/3673/CH2/EX2.a.16/Example_a_2_16.sce new file mode 100644 index 000000000..1cbc024c9 --- /dev/null +++ b/3673/CH2/EX2.a.16/Example_a_2_16.sce @@ -0,0 +1,11 @@ +//Example 2_16 page no:99
+clc;
+A=[10,5,4,
+ 1,-1,0,
+ -2,-1,1];
+B=[35,
+ 2,
+ 0];
+X=inv(A)*B;
+I1=X(1);
+disp(I1,"the current in the 10 ohm resistor is (in A)");
diff --git a/3673/CH2/EX2.a.2/Example_a_2_2.sce b/3673/CH2/EX2.a.2/Example_a_2_2.sce new file mode 100644 index 000000000..2f298a6e8 --- /dev/null +++ b/3673/CH2/EX2.a.2/Example_a_2_2.sce @@ -0,0 +1,5 @@ +//Example 2_2 page no:86
+clc;
+V1=(4.8+2+3.6)/((1/5)+(1/20)+(1/10));
+I=(V1-24)/5;
+disp(I,"the current delivered by the 24V source is");
diff --git a/3673/CH2/EX2.a.3/Example_a_2_3.sce b/3673/CH2/EX2.a.3/Example_a_2_3.sce new file mode 100644 index 000000000..497a8bb0e --- /dev/null +++ b/3673/CH2/EX2.a.3/Example_a_2_3.sce @@ -0,0 +1,15 @@ +//Example 2_3 page no:87
+clc;
+delta3=[360,-2,-1.5,
+ -60,9,-1,
+ 0,-1,10.5];
+delta5=[15.5,-2,360,
+ -2,9,-60,
+ -1.5,-1,0];
+delta=[15.5,-2,-1.5,
+ -2,9,-1,
+ -1.5,-1,10.5];
+I3=det(delta3)/det(delta);
+I5=det(delta5)/det(delta);
+I=I3-I5;
+disp(I,"the current I in the loop is (in A)");
diff --git a/3673/CH2/EX2.a.4/Example_a_2_4.sce b/3673/CH2/EX2.a.4/Example_a_2_4.sce new file mode 100644 index 000000000..6ba2f684a --- /dev/null +++ b/3673/CH2/EX2.a.4/Example_a_2_4.sce @@ -0,0 +1,12 @@ +//Example 2_4 page no:88
+clc;
+A=[1.25,-0.75,
+ -4.75,5.75];
+B=[-12.5,
+ 42.5];
+X=inv(A)*B;
+Va=X(1);
+Vb=X(2);
+I10=(Va-Vb+10)/4;
+P=10*I10;
+disp(P,"the power supplied by 10V source is (in W)");
diff --git a/3673/CH2/EX2.a.5/Example_a_2_5.sce b/3673/CH2/EX2.a.5/Example_a_2_5.sce new file mode 100644 index 000000000..5a4d10cd5 --- /dev/null +++ b/3673/CH2/EX2.a.5/Example_a_2_5.sce @@ -0,0 +1,12 @@ +//Example 2_5 page no:90
+clc;
+R=16.67;
+A=[75,-25,
+ -58.35,25];
+B=[25,
+ 10];
+X=inv(A)*B;
+I1=X(1);
+I2=X(2);
+Vx=I1*R;
+disp(Vx,"the voltage across 16.67 ohm resistor is (in V)");
diff --git a/3673/CH2/EX2.a.6/Example_a_2_6.sce b/3673/CH2/EX2.a.6/Example_a_2_6.sce new file mode 100644 index 000000000..ae1890576 --- /dev/null +++ b/3673/CH2/EX2.a.6/Example_a_2_6.sce @@ -0,0 +1,9 @@ +//Example 2_6 page no:91
+clc;
+Va=11;
+Vout=6;
+V=Va/Vout;
+Vin=9.53;
+Vout=1;
+Vrat=Vout/Vin;
+disp(Vrat,"the ratio Vout/Vin is ");
diff --git a/3673/CH2/EX2.a.7/Example_a_2_7.sce b/3673/CH2/EX2.a.7/Example_a_2_7.sce new file mode 100644 index 000000000..60d809936 --- /dev/null +++ b/3673/CH2/EX2.a.7/Example_a_2_7.sce @@ -0,0 +1,11 @@ +//Example 2_7 page no:91
+clc;
+A=[0.93,-0.1,
+ -0.1,0.443];
+B=[17.29,
+ 7.143];
+X=inv(A)*B;
+V1=X(1);
+V2=X(2);
+V=3*((0.93*V1)-(0.1*V2));
+disp(V,"the voltage V in the cicuit is (in V)");
diff --git a/3673/CH2/EX2.a.8/Example_a_2_8.sce b/3673/CH2/EX2.a.8/Example_a_2_8.sce new file mode 100644 index 000000000..3a3826e74 --- /dev/null +++ b/3673/CH2/EX2.a.8/Example_a_2_8.sce @@ -0,0 +1,17 @@ +//Example 2_8 page no:92
+clc;
+R6=6;
+delta=[1.83,-1,-0.5,
+ -1,-1.167,-0.167,
+ -0.5,-0.167,0.867];
+delta2=[1.83,6.67,-0.5,
+ -1,5,-0.167,
+ -0.5,0,0.867];
+delta3=[1.83,-1,6.67,
+ -1,-1.167,5,
+ -0.5,-0.167,0];
+V2=det(delta2)/det(delta);
+V3=det(delta3)/det(delta);
+I6=(V2-V3)/6;
+P=I6^2*R6;
+disp(P,"the power absorbed or dissipated is (in W))");
diff --git a/3673/CH2/EX2.a.9/Example_a_2_9.sce b/3673/CH2/EX2.a.9/Example_a_2_9.sce new file mode 100644 index 000000000..8c7713a70 --- /dev/null +++ b/3673/CH2/EX2.a.9/Example_a_2_9.sce @@ -0,0 +1,17 @@ +//Example 2_9 page no:94
+clc;
+R5=5;
+A=[0.42,-0.167,-0.25,
+ -0.42,0.5,0.45,
+ 0,-1,1]
+B=[18,
+ -15,
+ 20];
+X=inv(A)*B;
+V1=X(1);
+V2=X(2);
+V3=X(3);
+I5=V3/5;
+P=I5^2*R5;
+disp(P,"the power absorbed by 5 ohm resistor is (in W)");
+//in text book value of I5^2 is rounded up so result vary slightly
|