From b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b Mon Sep 17 00:00:00 2001 From: priyanka Date: Wed, 24 Jun 2015 15:03:17 +0530 Subject: initial commit / add all books --- 2384/CH1/EX1.8/ex1_8.sce | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100755 2384/CH1/EX1.8/ex1_8.sce (limited to '2384/CH1/EX1.8/ex1_8.sce') diff --git a/2384/CH1/EX1.8/ex1_8.sce b/2384/CH1/EX1.8/ex1_8.sce new file mode 100755 index 000000000..c7e7556d7 --- /dev/null +++ b/2384/CH1/EX1.8/ex1_8.sce @@ -0,0 +1,24 @@ +// Exa 1.8 +clc; +clear; +close; +format('v',7) +// Given data +R1= 2;// in ohm +R2= 4;// in ohm +R3= 1;// in ohm +R4= 6;// in ohm +R5= 4;// in ohm +V1= 10;// in V +V2= 20;// in V +//Applying KVL in ABGHA : I1*(R1+R2) - R2*I2 = V1 (i) +//Applying KVL in BCFGB : I1*R5-I2*(R3+R4+R5)+I3*R4 = 0 (ii) +//Applying KVL in CDEFC: R4*I2-I3*(R2+R4)=V2 (iii) +A= [(R1+R2) R5 0; -R2 -(R3+R4+R5) R4; 0 R4 -(R2+R4)]; +B= [V1 0 V2]; +I= B*A^-1;// Solving eq(i), (ii) and (iii) by Matrix method +I1= I(1);// in A +I2= I(2);// in A +I3= I(3);// in A +I6_ohm_resistor= I2-I3;//The current through 6 ohm resistance in A +disp(I6_ohm_resistor,"The current through 6 ohm resistance in A is : ") -- cgit