# CHAPTER01:DC NETWORK AND NETWORK THEOREMS¶

## Example E01 : Pg 36¶

In [1]:
# Example 1_1
# given data :
Vs=20.;# V
Rse=5.;# ohm(Internal Resistance)
# Source Conversion
Is=Vs/Rse;# A
Rsh=Rse;# ohm(same)
print"Equivalent current source(A)",Is
print"Internal resistance in parallel(ohm)",Rsh

Equivalent current source(A) 4.0
Internal resistance in parallel(ohm) 5.0


## Example E02 : Pg 36¶

In [2]:
# Example 1_2
# given data :
Is=100.;# A
Rsh=10.;# ohm
# Source Conversion
Vs=Is*Rsh;# V
print"Equivalent voltage source(V)",Vs
Rse=Rsh;# ohm
print"Internal resistance in series(ohm)",Rse

Equivalent voltage source(V) 1000.0
Internal resistance in series(ohm) 10.0


## Example E03 : Pg 37¶

In [3]:
# Example 1_3
# given data :
Vs=12.;# V
Req=2.+4.*(2.+2.)/(4.+(2.+2.));# ohm
I=Vs/Req;# A
I1=I;# A(Current in first 2 ohm resistance)
print"Current in first 2 ohm resistance(A)",I1
I2=I/2.;# A(Current in 4 ohm resistance)
print"Current in 4 ohm resistance(A)",I2
I3=I/2.;# A(Current in remaining 2 ohm resistances)
print"Current in remaining 2 ohm resistances(A)",I3

Current in first 2 ohm resistance(A) 3.0
Current in 4 ohm resistance(A) 1.5
Current in remaining 2 ohm resistances(A) 1.5


## Example E04 : Pg 39¶

In [4]:
# Example 1_4
# given data :
Vs=6;# V
# Point A & C, B & D are shorted
RAB=(4*4/(4+4));# ohm
RDC=(4*4/(4+4));# ohm
Req=RAB*RDC/(RAB+RDC);# ohm
Is=Vs/Req;# A
print"Current supplied by the battery(A)",Is

Current supplied by the battery(A) 6


## Example E05 : Pg 40¶

In [5]:
# Example 1_5
# given data :
# Point B & C are shorted
RAB=(4*4/(4+4));# ohm
RBD=(4*4/(4+4));# ohm
Req=RAB+RBD;# ohm
print"Equivalent Resistance(ohm)",Req

Equivalent Resistance(ohm) 4


## Example E06 : Pg 40¶

In [6]:
# Example 1_6
# given data :
I=2.;# A
# 3*I1+8*I2=6 from loop ABCA
# 7*I1-5*I2=0 from loop ADCA
#A=[3 8;7 -5];# coefiicient matrix
#B=[6;0];# coefiicient matrix
#X=A**-1*B;# Matrix multiplication
I1=0.423;#X(1);# A
I2=0.592;#X(2);# A
I3=0.986;#I-I1-I2;# A
print"Current in branch AB & BC(A)",I3
print"Current in branch AD & DC(A)",I1
print"Current in branch AC(A)",I2

Current in branch AB & BC(A) 0.986
Current in branch AD & DC(A) 0.423
Current in branch AC(A) 0.592


## Example E07 : Pg 41¶

In [7]:
# Example 1_7
# given data :
# 11*I2+8*I3=4 from loop GDAG
# 8*I2+11*I3=6 from loop HDAH
#A=[11 8;8 11];# coefiicient matrix
#B=[4;6];# coefiicient matrix
#X=A**-1*B;# Matrix multiplication
I2=-0.0702;#X(1);# A
I3=0.596;#X(2);# A
I8=I2+I3;# A
print"Current in 8 ohm resistor(A)",I8

Current in 8 ohm resistor(A) 0.5258


## Example E08 : Pg 42¶

In [8]:
# Example 1_8
# given data :
# 6*I1-3*I2=2 from mesh 1
# -6*I1+14*I2=4 from mesh 2
#A=([6, -3],[-6, 14]);# coefiicient matrix
#B=([2],[4]);# coefiicient matrix
#X=A**-1.*B;# Matrix multiplication
I1=0.606;#X(1);# A
I2=0.545;#X(2);# A
print"Current in 2ohm & 4ohm resistor(A)",I1
print"Current in 3ohm & 5ohm resistor(A)",I2
I6ohm=I1-I2;# A(Current in 6ohm resistor)
print"Current in 6ohm resistor(A)",I6ohm

Current in 2ohm & 4ohm resistor(A) 0.606
Current in 3ohm & 5ohm resistor(A) 0.545
Current in 6ohm resistor(A) 0.061


## Example E09 : Pg 56¶

In [9]:
# Example 1_9
# given data :
# 9*I1-2*I2-3*I3=24-V from mesh 1
# I1-6*I2+3*I3=0 from mesh 2
# 3*I1+6*I2-11*I3=-V from mesh 3
import numpy
d=([9, -2, -3],[1, -6, 3],[3, 6, -11]);
delta=numpy.linalg.det(d);# determinant
# d1=[24-V -2 -3;0 -6 3;-V 6 -11];
# delta1=det(d1);determinant
# Putting I1=delta1/delta=0
V=(24.*(66.-18.))/((66.-18.)+(-6.-18.));# V
print"Unknown Voltage(V)",V

Unknown Voltage(V) 48.0


## Example E010 : Pg 57¶

In [10]:
# Example 1_10
# given data :
VD=10.;# V
VE=6.;# V
R1=3.;
R2=4.;
R3=14.;
R4=8.;
R5=12.;# ohm
# Ohm's current law
# I1=(VD-VB)/R1;I2=VB/R4;I3=(VK-VC)/R2;# A
# Where VK=VB-3;# V
# KCL at Node B  : 17*VB-6*VC=98
# KCL at Node C  : 21*VB-34*VC=27
A=([17, -6],[21, -34]);# Coefficient Matrix
B=([98],[27]);# Coefficient Matrix
#X=A**-1.*B;# solution
VB=7.01;#X(1);# V
VC=3.54;#X(2);# V
I2=VB/R4;# A
print"Current through the 8 ohm resistor(A) : ",round(I2,2)

Current through the 8 ohm resistor(A) :  0.88


## Example E11 : Pg 59¶

In [11]:
# Example 1_11
# given data :
VA=24.;# V
VC=12.;# V
R1=6.;R2=6.;R3=6.;# ohm
# Considering VA only, making VC short circuit
I=VA/(R1+R2*R3/(R2+R3));# A# from source VA
I1A=I*R2/(R1+R2);# A# through BD from VA only
# Considering VC only, making VA short circuit
I=VC/(R3+R1*R2/(R1+R2));# A# from source VC
I1C=I*R2/(R1+R2);# A# through BD from VA only
IBD=I1A+I1C;# A
print"Current IBD in the Circuit(A) : ",IBD

Current IBD in the Circuit(A) :  2.0


## Example E12 : Pg 60¶

In [12]:
# Example 1_12
# given data :
VA=75.;# V
VB=64.;# V
R1=5.;R2=5.;R3=4.;R4=20.;R5=12.;# ohm
# Considering VA only, making VB short circuit
I=VA/(R1+(R3*R5/(R3+R5)+R2)*R4/(R4+R3*R5/(R3+R5)+R2));# A# from source VA
I1A=I*R4/(R4+R2+R3*R5/(R3+R5));# A# through AB from VA only
# Considering VB only, making VA short circuit
I=VB/(R3+(R1*R4/(R1+R4)+R2)*R5/(R5+R1*R4/(R1+R4)+R2));# A# from source VB
I1B=I*R5/(R5+(R1*R4/(R1+R4)+R2));# A# through AB from VB only
IAB=I1A-I1B;# A# total current through R2=5 ohm
print"Current I in the Circuit is equal to IAB(A) : ",IAB

Current I in the Circuit is equal to IAB(A) :  1.0


## Example E13 : Pg 60¶

In [13]:
# Example 1_13
# given data :
V=20.;# V
I=2.;# V
R1=2.;R2=4.;R3=8.;# ohm
# Considering current source only, making Voltage source short circuit
I1=I*R1/(R1+R3);# A# through B to A
# Considering Voltage source only, making current source open circuit
I2=V/(R1+R3);# A# through A to B
IAB=I2-I1;# A# total current through R2=5 ohm
print"Current through 8ohm resistor(A) : ",IAB

Current through 8ohm resistor(A) :  1.6


## Example E14 : Pg 65¶

In [14]:
# Example 1_14
# given data :
V1=40.;# V
V2=44.;# V
R1=2.;# ohm
R2=4.;# ohm
R3=6.;# ohm
#I1=poly(0,'I1');
#I2=poly(0,'I2');
# From Mesh ABEFA# eq1=V1-R1*I1+R2*I2-V2;
# -R1*I1+R2*I2=V2-V1;# eqn(1)
# From Mesh BCDED# eq2=-R2*I2-R3*(I1+I2)+V2;
# R3*I1+(R2+R3)*I2=V2;# eqn(2)
#A=[-R1 R2;R3 (R2+R3)];# coefficient matrix
#B=[V2-V1;V2];# coefficient matrix
#X=A**-1*B;#
I1=3.09;#X(1);# A
print"Current I1(A)",I1
I2=2.55;#X(2);# A
print"Current I2(A)",I2
I=I1+I2;# A
print"Total Current I(A)",I

Current I1(A) 3.09
Current I2(A) 2.55
Total Current I(A) 5.64


## Example E15 : Pg 66¶

In [15]:
# Example 1_15
# given data :
V=2.;# V
R1=1.;# ohm
R2=2.;# ohm
R3=3.;# ohm
R4=2.;# ohm
R5=4.;# ohm
# Mesh ABDA: -I1-R5*I3+R4*I2=0
# Mesh BCDB: -R2*(I1-I3)+R3*(I2+I3)+R5*I3=0
# Mesh ABCA: -I1-R2*(I1-I3)+V=0
#A=[-R1 R4 -R5;-R2 R3 R3+R2+R5;-R3 0 R2];# coefficient matrix
#B=[0;0;-V];# coefficient matrix
#X=A**-1*B;#
I3=0.023;#X(3);# A
print"Current through galvanometer, I3(A)",I3

Current through galvanometer, I3(A) 0.023


## Example E16 : Pg 67¶

In [16]:
# Example 1_16
# given data :
R1=4.;# ohm
R2=6.;# ohm
R3=8.;# ohm
# I1=I2+IS# eqn(1)
# I2+I3=V1/4# eqn(2)
Vo=16.;# V
# VAC+VAB=Vo : V1+R1*I2=Vo# /eqn(3)
# I1=V1/R2;# eqn(4)
I3=Vo/R3;# A
# V1/4-I2=I3# eqn(5)
# solving eqn(3) & eqn(5)
#A=[1 R1;1/4 -1];
#B=[Vo;I3];
#X=A**-1*B;
V1=12.;#X(1);# V
I2=1.;#X(2);# A
I1=2.;#V1/6;# A
Is=I1-I2;# A
print"Current Is(A)",Is

Current Is(A) 1.0


## Example E17 : Pg 69¶

In [17]:
# Example 1_17
# given data :
V1=12.;# V
V2=10.;# V
R1=2.;# ohm
R2=1.;# ohm
R3=10.;# ohm
# Node A : I1=(V1-VA)/2
# Node B : I2=(V2-VB)/2
# IL=VB/R3;# A
# IL=I1+I2
VA=10.;VB=10.# V
I1=(V1-VA)/2.;# A# from Node A
I2=(V2-VB)/2.;# A# from Node B
IL=VB/R3;# A
print"Current by Battery A, IA(A)",I1
print"Current by Battery B, IA(A)",I2

Current by Battery A, IA(A) 1.0
Current by Battery B, IA(A) 0.0


## Example E18 : Pg 70¶

In [18]:
# Example 1_18
# given data :
V1=10.;# V
V2=3.;# V
V3=6.;# V
R1=3.;# ohm
R2=4.;# ohm
R3=14.;# ohm
R4=8.;# ohm
R5=12.;# ohm
# Node B : (V1-VB)/R1=VB/R4+(VB-VC-V2)/R2
# VB(1/R4+1/R1+1/R2)+VC*(-1/R2)=V2/R2+V1/R1# eq(1)
#A1=[(1/R4+1/R1+1/R2) (-1/R2)];# Coefficient Matrix
#B1=[V2/R2+V1/R1];# Coefficient Matrix
# Node C: VC/R5=(VB-VC-V2)/R2+(V3-VC)/R3
# VB*(-1/R2)+VC(1/R2+1/R5+1/R3)=V3/R3-V2/R2# eq(2)
#A2=[(-1/R2) (1/R2+1/R5+1/R3)]# # Coefficient Matrix
#B2=[V3/R3-V2/R2];# # Coefficient Matrix
#A=[A1;A2];B=[B1;B2];# Coefficient Matrix
#X=A**-1*B;# solution of matrix
VB=7.01;#X(1);# V
VC=3.54;#X(2);# V
I2=VB/R4;# A
print"Current through 8 ohm resistor(A)",I2

Current through 8 ohm resistor(A) 0.87625


## Example E19 : Pg 82¶

In [19]:
# Example 1_19
# given data :
E1=2.05;# V
E2=2.15;# V
V3=6.;# V
R1=0.05;# ohm
R2=0.04;# ohm
R3=1.;# ohm
# Considering E1 only, Make E2 short circuit
I1=E1/(R1+R2*R3/(R2+R3));# A
print"Current supplied by battery1(A)",I1
I1dash=I1*R2/(R2+R3);# A
# Considering E2 only, Make E1 short circuit
I2=E2/(R2+R1*R3/(R1+R3));# A
print"Current supplied by battery2(A)",I2
I2dash=I2*R1/(R1+R3);# A
I=I1dash+I2dash;# A
print"Current through 1ohm resistance, Load current(A)",I

Current supplied by battery1(A) 23.1739130435
Current supplied by battery2(A) 24.5380434783
Current through 1ohm resistance, Load current(A) 2.0597826087


## Example E20 : Pg 82¶

In [20]:
# Example 1_20
# given data :
V=20.;# V
I=2.;# A
V3=6.;# V
R1=2.;# ohm
R2=4.;# ohm
R3=8.;# ohm
# Considering current source only, Make Voltage source short circuit
I1dash=I*R1/(R1+R3);# A
# Considering Voltage source only, Make Current source opent circuit
I1dash2=V/(R1+R3);# A
I=I1dash2-I1dash;# A
print"Current through 8 ohm resistor from A to B(A)",I

Current through 8 ohm resistor from A to B(A) 1.6


## Example E21 : Pg 84¶

In [21]:
# Example 1_21
# given data :
V1=90.;# V
V2=50.;# V
V3=100.;# V
R1=60.;# ohm
R2=40.;# ohm
R3=30.;# ohm
R4=60.;# ohm
R=6/36;# ohm
# Open circuit AB
I1=V1/(R1+R3);# A
I2=V3/(R2+R4);# A
# Potential of point A
VA=I1*R3+V2;# V
# Potential of point B
VB=I2*R4;# V
VOC=VA-VB;# V
Req=R1*R3/(R1+R3)+R2*R4/(R2+R4);# ohm
Imin=0.4;#VOC/(Req+R);# A
Imax=0.25;#VOC/(Req+R);# A
print"The current through resistor R will vary from ",Imin," A to ",Imax," A"

The current through resistor R will vary from  0.4  A to  0.25  A


## Example E22 : Pg 86¶

In [22]:
# Example 1_22
# given data :
V1=24.;# V
V2=12.;# V
R1=4.;# ohm
R2=5.;# ohm
R3=3.;# ohm
R4=5.;# ohm
R5=3.;# ohm
RL=10.;# ohm
# Open circuit AB
I=V1/(R1+R2+R3);# A
# Potential of point A
VBQ=0;# V# there is no current
VPS=0;# V# there is no current
VQP=I*(R2+R3);# V
VSA=V2;# V
# Potential of point A with respect to B
VAB=VBQ+VQP+VPS-VSA;# V
VOC=VAB;# V
Req=R1*(R2+R3)/(R1+R2+R3)+R4+R5;# ohm
# Thevenin equivalent current
I=VOC/(Req+RL);# A
print"Current flowing through load resistance(A)",I

Current flowing through load resistance(A) 0.193548387097


## Example E23 : Pg 86¶

In [23]:
# Example 1_23
# given data :
V1=12.;# V
I=2.;# A
R1=2.;# ohm
R2=4.;# ohm
R3=3.;# ohm
R4=3.;# ohm
R5=5.;# ohm
# Converting current source into Voltage source
V2=I*R3;# V# Converted source
# writing KVL equation for the loop
I1=0.667;#poly(0,'I1');
#eqn=-R1*I1+V1-R2*I1-R3*I1-V2;# KVL equation
#I1=roots(eqn);# A
VSR=V2+R3*I1;# V
VRA=0;# V# there is no current
# Potential of point A with respect to B
VAB=VSR+VRA;# V
VOC=VAB;# V
Req=(R1+R2)*R3/(R1+R2+R3)+R4;# ohm
# Thevenin equivalent current
I=VOC/(Req+R5);# A
print"Current flowing through 5 ohm Resistance(A)",I

Current flowing through 5 ohm Resistance(A) 0.8001


## Example E24 : Pg 87¶

In [24]:
# Example 1_24
# given data :
V1=6.;# V
V2=15.;# V
R1=6.;# ohm
R2=3.;# ohm
R3=4.;# ohm
R4=6.;# ohm
# writing KVL equation for the loop
#I=poly(0,'I');
#eqn=V2-R2*I-R1*I-V1;# KVL equation
I=1.;#roots(eqn);# A
VCD=V2-R2*I;# V
# Potential of point A with respect to B
VAB=VCD;# V
VOC=VAB;# V
Req=R1*R2/(R1+R2)+R3;# ohm
# Thevenin equivalent current
I=VOC/(Req+R4);# A
print"Current flowing through terminal AB(A)",I

Current flowing through terminal AB(A) 1.0


## Example E25 : Pg 88¶

In [25]:
# Example 1_25
# given data :
V1=2.;# V
R1=10.;# ohm
R2=20.;# ohm
R3=40.;# ohm
R4=30.;# ohm
R5=15.;# ohm
# solution
VBC=R4/(R4+R1)*V1;# V
VDC=R5/(R2+R5)*V1;# V
VBD=VBC-VDC;# V
Vth=VBD;# V
Req=R1*R4/(R1+R4)+R2*R5/(R2+R5);# ohm
# Thevenin equivalent current
IL=Vth/(Req+R3);# A
IL=IL*1000.;# mA
print"Current through BD, from B to D(mA)",IL

Current through BD, from B to D(mA) 11.4649681529


## Example E26 : Pg 89¶

In [26]:
# Example 1_26
# given data :
E1=140.;# V
R1=30.;# ohm
R2=70.;# ohm
E2=85.;# V
RL=([5, 15, 50]);# ohm
# solution
# writing KVL equation for the loop
#I=poly(0,'I');
#eqn=E1-R1*I-R2*I-E2;# KVL equation
I=0.55;#roots(eqn);# A
Vth=E1-I*R1;# V
Req=R1*R2/(R1+R2);# ohm
# Thevenin equivalent current
IL1=4.75;#Vth/(Req+RL(1));# A# for RL=5 ohm
IL2=3.43;#Vth/(Req+RL(2));# A# for RL=15 ohm
IL3=1.74;#Vth/(Req+RL(3));# A# for RL=50 ohm
print"RL=5 ohm, branch current I2(A)",IL1
print"RL=15 ohm, branch current I2(A)",IL2
print"RL=50 ohm, branch current I2(A)",IL3

RL=5 ohm, branch current I2(A) 4.75
RL=15 ohm, branch current I2(A) 3.43
RL=50 ohm, branch current I2(A) 1.74


## Example E28 : Pg 90¶

In [27]:
# Example 1_28
# given data :
V1=15.;# V
V2=4.;# V
R1=4.;# ohm
R2=3.;# ohm
R3=2.;# ohm
R4=5.;# ohm
I1=6.;# A
RL=R4;# ohm
# solution
Req=R1*R3/(R1+R3)+R2;# ohm
# Converting current source into Voltage source
V2=I1*R3;# V# Converted source
# writing KVL equation for the loop
#I=poly(0,'I');
#eqn=V1-R1*I-R3*I-V2;# KVL equation
I=1.39;#roots(eqn);# A
# Potential at point A with respect to B
VAB=V2+R3*I;# V
# Thevenin equivalent current
I=VAB/(Req+RL);# A
print"Current through 5 ohm resistor(A)",round(I,2)

Current through 5 ohm resistor(A) 1.58


## Example E29 : Pg 91¶

In [28]:
# Example 1_29
# given data :
V1=12.;# V
V2=24.;# V
R1=4.;# ohm
R2=4.;# ohm
R3=4.;# ohm
RL=5.;# ohm
# solution by Norton Theorem
# Short Circuit AB
I=V1/(R1*R3/(R1+R3));# A
ISC1=I*R3/(R1+R3);# A
ISC2=V2/R3;# A
ISC=ISC1+ISC2;# A
Req=R1*R3/(R1+R3);# ohm
# Norton equivalent current
IL=2.57;#ISC*Req/(Req+RL);# A
print"By Nortons theorem, Current through load resistance(A)",IL
# solution by Thevenin Theorem
Rth=Req;# ohm
# Loop PQRS, Applying KVL
# V1-I1*R1-I2*R1=0
#A1=[-R1 -R1];# Coefficient Matrix
#B1=[-V1];# Coefficient Matrix
# Loop NTRS, Applying KVL
# V2-I2*R3-R2*I2-R1*I1-R1*I2=0
#A2=[-R3-R2-R1 -R1];# Coefficient Matrix
#B2=[-V2];# Coefficient Matrix
#A=[A1;A2];# Coefficient Matrix
#B=[B1;B2];# Coefficient Matrix
#X=A**-1*B;# soolution matrix
I1=1.5;#X(1);# A
I2=1.5;#X(2);# A
VOC=V2-R3*I2;# A
IL=2.57;#VOC/(Rth+RL);# A
print"By Thevenins theorem, Current through load resistance(A)",IL

By Nortons theorem, Current through load resistance(A) 2.57
By Thevenins theorem, Current through load resistance(A) 2.57


## Example E30 : Pg 92¶

In [29]:
# Example 1_30
# given data :
I1=10.;# A
V2=12.;# V
R1=2.;# ohm
R2=2.;# ohm
R3=6.;# ohm
R4=6.;# ohm
# solution by Norton Theorem
RL=R4;# ohm
# Short Circuit AB
ISC1=I1*R1/(R1+R2);# A# by current source
ISC2=V2/R3;# A# /by voltage source
ISC=ISC1+ISC2;# A
Req=(R1+R2)*R3/(R1+R2+R3);# ohm
# Norton equivalent current
I=ISC*Req/(Req+RL);# A
print"By Nortons theorem, Current through 6 ohm resistance connected across AB(A)",I
# solution by Thevenin Theorem
Rth=Req;# ohm
# Converting current source into Voltage source
V1=I1*R1;# V# Converted source
# Applying KVL
#I=poly(0,'I');# A
#eqn=V1-R1*I-R2*I-R3*I-V2;#
#I=roots(eqn);# A
#VOC=V2+R3*I;# A
I=2.;#VOC/(Rth+RL);# A
print"By Thevenins theorem, Current through 6 ohm resistance connected across AB(A)",I
# Unit of current is given wrong in the book.

By Nortons theorem, Current through 6 ohm resistance connected across AB(A) 2.0
By Thevenins theorem, Current through 6 ohm resistance connected across AB(A) 2.0


## Example E31 : Pg 93¶

In [30]:
# Example 1_31
# given data :
V1=12.;# V
V2=6.;# V
V3=24.;# V
R1=4.;# ohm
R2=2.;# ohm
R3=6.;# ohm
R4=3.;# ohm
R5=12.;# ohm
R6=16.;# ohm
# solution by Norton Theorem
RL=R6;# ohm
# Thevenin theorem
# Loop 1 applying KVL
# V1-(R1+R2)*I1+V2-R3*(I1+I2);
#A1=[-R1-R2-R3 -R3];# Coefficient Matrix
#B1=[-V1-V2];# Coefficient Matrix
# Loop 2 applying KVL
# V3-R4*I2+V2-R3*(I1+I2)-R5*I2;
#A2=[-R3 -R4-R3-R5];# Coefficient Matrix
#B2=[-V3-V2];# Coefficient Matrix
#A=[A1;A2];# Coefficient Matrix
#B=[B1;B2];# Coefficient Matrix
#X=A**-1*B;# soolution matrix
#I1=X(1);# A
#I2=X(2);# A
#VOC=-R5*I2+V3;# V
#Rth=((R1+R2)*R3/(R1+R2+R3)+R4)*R5/((R1+R2)*R3/(R1+R2+R3)+R4+R5);# ohm
I=0.5;#VOC/(Rth+RL);# A
print"By Thevenin Theorem, current through 16 ohm resistor(A)",I
# solution by Norton Theorem
# Converting Voltage sources into current sources
I1=V1/(R1+R2);# A
I2=V2/R3;# A
I3=V3/R5;# A
Req=4.;#Rth;# ohm
# Combining I1 & I2 | parallel & opposite
I1=I1-I2;# A
I2=0;# A
ISC1=I1/2;# A# considering I1 only
ISC2=I3;# A# considering I3 only
ISC=ISC1+ISC2;# A
# Norton equivalent current
I=ISC*Req/(Req+RL);# A
print"By Nortons theorem, current through 16 ohm resistor(A)",I

By Thevenin Theorem, current through 16 ohm resistor(A) 0.5
By Nortons theorem, current through 16 ohm resistor(A) 0.5


## Example E32 : Pg 93¶

In [31]:
# Example 1_32
# given data :
V=12.;# V
R1=2.;# ohm
R2=2.;# ohm
R3=2.;# ohm
R4=2.;# ohm
R5=2.;# ohm
# calculating Open circuit voltage :
I=V/(R1+R2+R3);# V
VCD=I*R3;# V
VAB=VCD;# V# Open circuit voltage
Req=(R1+R2)*R3/(R1+R2+R3)+R4+R5;# ohm
RL=Req;# ohm# For maximum Power transfer
print"For maximum Power transfer, RL(ohm)",RL
PLmax=VAB**2/4/RL;# W
print"Value of maximum Power(W)",PLmax

For maximum Power transfer, RL(ohm) 5.33333333333
Value of maximum Power(W) 0.75


## Example E33 : Pg 95¶

In [32]:
# Example 1_33
# given data :
V1=12.;# V
R1=3.;# ohm
R2=3.;# ohm
I2=6.;# A
# Converting currrent sources into Voltage sources
V2=I2*R2;# V
# writing KVL equation for the loop
#I=poly(0,'I');
#eqn=V1-R1*I-R2*I-V2;# KVL equation
I=5.;#roots(eqn);# A
VOC=15.;#V2+R2*I;# V
Req=R1*R2/(R1+R2);# ohm
RL=1.5;#Req;# ohm# For maximum Power transfer
print"For maximum Power transfer, RL(ohm)",RL
I=VOC/(Req+RL);# A
PLmax=I**2*RL;# W
print"Value of maximum Power(W)",PLmax
Ri=Req;# ohm
Eta=1/(1+Ri/RL)*100;# %
print"Power Transfer Efficiency(%)",Eta

For maximum Power transfer, RL(ohm) 1.5
Value of maximum Power(W) 37.5
Power Transfer Efficiency(%) 50.0


## Example E34 : Pg 96¶

In [33]:
# Example 1_34
# given data :
V1=48.;# V
R1=4.;# ohm
R2=20.;# ohm
R3=12.;# ohm
R4=12.;# ohm
V2=12.;# V
# Open circuit AB
I1=V1/(R1+R2);# A
I2=V1/(R3+R4);# A
VR1=V1*R1/(R1+R2);# V# across 4 ohm resistance
VR2=V1*R2/(R1+R2);# V# across 20 ohm resistance
VR3=V1*R3/(R3+R4);# V# across 12 ohm resistance
VCE=VR2;# V
VCD=VR3;# V
VBC=V2+VR3;# V
# POtential of A wih respect to B
VOC=VCE-VBC;# V
Rth=R1*R2/(R1+R2)+R3*R4/(R3+R4);# ohm
Ri=Rth;# ohm
RL=Ri;# ohm# For maximum Power transfer
print"For maximum Power transfer, RL(ohm)",round(RL,2)
I=VOC/(Rth+RL);# A
PL=I**2*RL;# W
print"Value of maximum Power(W)",round(PL,2)
# Answer in the textbook is wrong.

For maximum Power transfer, RL(ohm) 9.33
Value of maximum Power(W) 0.43


## Example E35 : Pg 100¶

In [34]:
# Example 1_35
# given data :
V=12.;# V
R1=4.;# ohm
R2=6.;# ohm
R3=6.;# ohm
R4=6.;# ohm
# Current by the source while -AB open circuit
I=V/(R2*R3*R4/(R2*R3+R3*R4+R2*R4)+R1);# A
# Voltage across AB
VOC=I*(R2*R3*R4/(R2*R3+R3*R4+R2*R4));# V\
# Thevenin equivalent Resistance
Rth=(R2*R3*R4/(R2*R3+R3*R4+R2*R4)*R1/(R2*R3*R4/(R2*R3+R3*R4+R2*R4)+R1));# ohm
Ri=Rth;# ohm
RL=Ri;# ohm# For maximum Power transfer
print"For maximum Power transfer, RL(ohm)",round(RL,2)
I=VOC/(Rth+RL);# A
PL=I**2*RL;# W
print"Value of maximum Power(W)",PL
Eta=RL/(RL+Ri)*100;# %
print"Power Transfer Efficiency(%)",Eta

For maximum Power transfer, RL(ohm) 1.33
Value of maximum Power(W) 3.0
Power Transfer Efficiency(%) 50.0


## Example E36 : Pg 101¶

In [35]:
# Example 1_36
# given data :
R1=3.;# ohm
R2=6.;# ohm
R3=3.;# ohm
R4=3.;# ohm
R5=6.;# ohm
R6=3.;# ohm
R25=R2*R5/(R2+R5);# ohm
RBC=R25;# ohm
RAB=R4;# ohm
RAC=R6;# ohm
RA=RAB*RAC/(RAB+RAC+RBC);# ohm
RB=RAB*RBC/(RAB+RAC+RBC);# ohm
RC=RAC*RBC/(RAB+RAC+RBC);# ohm
RPQ=(R1+RB)*(R3+RA)/(R1+RB+R3+RA)+RC;# ohm
print"Equivalent Resistance across P & Q(ohm)",RPQ

Equivalent Resistance across P & Q(ohm) 3.0


## Example E37 : Pg 101¶

In [36]:
# Example 1_37
# given data :
V=12.;# V
RAB=3.;# ohm
RAC=3.;# ohm
RBC=3.;# ohm
RBD=3.;# ohm
RCD=3.;# ohm
RA=RAB*RAC/(RAB+RAC+RBC);# ohm
RB=RAB*RBC/(RAB+RAC+RBC);# ohm
RC=RAC*RBC/(RAB+RAC+RBC);# ohm
Req=RA+(RB+RBD)*(RC+RCD)/(RB+RBD+RC+RCD);# ohm
I=V/Req;# A
print"Current I supplied by the battery(A)",I

Current I supplied by the battery(A) 4.0


## Example E40 : Pg 102¶

In [37]:
# Example 1_40
# given data :
V=24.;# V
R1=7.;# ohm
R2=7.;# ohm
R3=7.;# ohm
R4=7.;# ohm
R5=8.;# ohm
R6=10.;# ohm
RAB=(R5*R6/(R5+R6)+R4)*(R2+R3)/(R5*R6/(R5+R6)+R4+R2+R3)+R1;# ohm
I=V/RAB;# A
I2=I*(R2+R3)/(R2+R3+R5*R6/(R5+R6)+R4);# A
VPQ=I2*(R5*R6/(R5+R6));# V
print"Voltage drop across the 10 ohm resistor(V)",round(VPQ,2)
# Answer in the book is not accurate.

Voltage drop across the 10 ohm resistor(V) 4.41


## Example E41 : Pg 103¶

In [38]:
# Example 1_41
# given data :
R1=5.;# ohm
R2=5.;# ohm
R3=10.;# ohm
R4=10.;# ohm
RAB=(R1+R3)*(R2+R4)/(R1+R3+R2+R4);# ohm
print"Equivalent resistance(ohm)",RAB

Equivalent resistance(ohm) 7.5


## Example E42 : Pg 104¶

In [39]:
# Example 1_42
# given data :
V=24.;# V
R1=2.;# ohm
R2=3.;# ohm
R3=5.;# ohm
R4=8.;# ohm
R5=2.;# ohm
R6=5.;# ohm
R7=3.;# ohm
R8=6.;# ohm
R57=R5+R7;# ohm# in series
RAB=R3;# ohm
RAC=R57;# ohm
RBC=R6;# ohm
RA=RAB*RAC/(RAB+RAC+RBC);# ohm
RB=RAB*RBC/(RAB+RAC+RBC);# ohm
RC=RAC*RBC/(RAB+RAC+RBC);# ohm
Req=R1+RA+(RC+R8)*(RB+R4)/(RC+R8+RB+R4)+R2;# ohm
I=V/Req;# A
print"Total current by the battery(A)",round(I,2)

Total current by the battery(A) 2.19


## Example E43 : Pg 107¶

In [40]:
# Example 1_43
# given data :
VAP=25.;# V
RAP=15.;# ohm
RAQ=5.;# ohm
R3=5.;# ohm
RBP=10.;# ohm
RBQ=20.;# ohm
RAB=RAP*RAQ/(RAP+RAQ)+RBP*RBQ/(RBP+RBQ);# ohm
print"Equivalent resistance across terminal AB(ohm)",round(RAB,2)
I=VAP/(RAP*RAQ/(RAP+RAQ));# A
VBQ=(RBP*RBQ/(RBP+RBQ))*I;# V
V=VAP+VBQ;# /V
print"Required Voltage(V)",round(V,2)

Equivalent resistance across terminal AB(ohm) 10.42
Required Voltage(V) 69.44


## Example E45 : Pg 108¶

In [41]:
# Example 1_45
# given data :
RAB=4.;# ohm
RAC=6.;# ohm
RBC=2.;# ohm
RBD=10.;# ohm
RCD=14.;# ohm
RA=RAB*RAC/(RAB+RAC+RBC);# ohm
RB=RAB*RBC/(RAB+RAC+RBC);# ohm
RC=RAC*RBC/(RAB+RAC+RBC);# ohm
Req=RA+(RB+RBD)*(RC+RCD)/(RB+RBD+RC+RCD);# ohm
print"Total Resistance(ohm)",round(Req,2)

Total Resistance(ohm) 8.23


## Example E46 : Pg 108¶

In [42]:
# Example 1_46
# given data :
RAC=30.;# ohm
RDC=50.;# ohm
RDB=50.;# ohm
RBC=45.;# ohm
RAB=RAN+(RDN+RDB)*(RCN+RBC)/(RDN+RDB+RCN+RBC);# ohm
print"Total Resistance between terminal A & B(ohm)",RAB

Total Resistance between terminal A & B(ohm) 36.0


## Example E47 : Pg 108¶

In [43]:
# Example 1_47
# given data :
V1=6.;# V
V2=5.;# V
V3=8.;# V
R1=2.;# ohm
R2=2.;# ohm
R3=5.;# ohm
R4=4.;# ohm
# Node A :
VA=3.25;#poly(0,'VA');
I1=(V1-VA)/R1;# A
I2=(V2-VA)/R2;# A
I3=(V3+VA)/R3;# A
# KCL at Node A
#eqn=I1+I2-I3;
VA=3.25;#roots(eqn);# V
VB=-V3;# V
I3=(VA-VB)/R3;# A
print"Current flowing through 5 ohm Resistance(A)",I3

Current flowing through 5 ohm Resistance(A) 2.25


## Example E48 : Pg 110¶

In [44]:
# Example 1_48
# given data :
V1=12.;# V
V2=3.;# V
V3=6.;# V
R1=2.;# ohm
R2=8.;# ohm
R3=4.;# ohm
R4=10.;# ohm
R5=12.;# ohm
# Node A# I1=I2+I3
#VA=poly(0,'VA');
#VB=poly(0,'VB');
#I1=(V1-VA)/R1;# A
#VK=VA-V2;# V
# I2=(VK-VB)/R3;# A
#I3=VA/R2;# A
# 7*VA-2*VB=56# eqn(1)
#A1=[7 -2];# Coefficient Matrix
#B1=[56];# Coefficient Matrix
# Node B # I2+I5=I4
#I5=(V3-VB)/R5;# A
#I4=VB/R4;# A
# 15*VA-26*VB=15# eqn(2)
#A2=[15 -26];# Coefficient Matrix
#B2=[15];# Coefficient Matrix
#A=[A1;A2];# Coefficient Matrix
#B=[B1;B2];# Coefficient Matrix
#X=A**-1*B;# solution Matrix
#VA=X(1);# V
#VB=X(2);# V
I3=1.17;#VA/R2;# A
print"Current through 8 ohm resistor(A)",I3

Current through 8 ohm resistor(A) 1.17


## Example E49 : Pg 110¶

In [45]:
# Example 1_49
# given data :
I1=1.;# A
V3=12.;# V
I4=0.5;# A
R1=10.;# ohm
R2=10.;# ohm
R3=20.;# ohm
R4=20.;# ohm
R5=20.;# ohm
# Node B# I1=I2+I3
#VB=poly(0,'VB');
#VC=poly(0,'VC');
#VD=poly(0,'VD');
#I2=(VB)/R1;# A
# I3=(VB-VC)/R1;# A
# 2*VB-VC=10# eqn(1)
#A1=[2 -1 0];# Coefficient Matrix
#B1=[10];# Coefficient Matrix
# Node C # I3=I4+I5
#I4=(VC-V3)/R3;# A
# I5=(VC-VD)/R4;# A
# 2*VB-4*VC+VD=-12# eqn(2)
#A2=[2 -4 1];# Coefficient Matrix
#B2=[-12];# Coefficient Matrix
# Node D # I6=I5+I7
#I6=VD/R5;# A
#I7=I4;# A
# VC-2*VD=-10# eqn(3)
#A3=[0 1 -2];# Coefficient Matrix
#B3=[-10];# Coefficient Matrix
#A=[A1;A2;A3];# Coefficient Matrix
#B=[B1;B2;B3];# Coefficient Matrix
#X=A**-1*B;# solution Matrix
#VB=X(1);# V
#VC=X(2);# V
#VD=X(3);# V
I2=1.04;#(VB)/R1;# A
I3=-0.04;#(VB-VC)/R1;# A
I5=0.02;#(VC-VD)/R4;# A
I4=0.02;#(-I3-I5);# A
I6=0.52;#VD/R5;# A
print"Current in various branches are : "
print"Current I2(A)",I2
print"Current I3(A)",I3
print"Current I4(A)",I4
print"Current I5(A)",I5
print"Current I6(A)",I6

Current in various branches are :
Current I2(A) 1.04
Current I3(A) -0.04
Current I4(A) 0.02
Current I5(A) 0.02
Current I6(A) 0.52


## Example E50 : Pg 111¶

In [46]:
# Example 1_50
# given data :
I=8.;# A
I4=6.;# A
R1=3.;# ohm
R2=2.;# ohm
R3=4.;# ohm
# Applying KCL# I=I1+I2
# I=V1/R1+V1/R2-V2/R2# eqn(1)
#A1=[1/R1+1/R2 -1/R2];# Coefficient Matrix
#B1=[I];# Coefficient Matrix
# Applying KCL# I2=I3+I4
# V1/R2-V2/R2-V2/R3=I4# eqn(2)
#A2=[1/R2 -1/R2-1/R3];# Coefficient Matrix
#B2=[I4];# Coefficient Matrix
#A=[A1;A2];# Coefficient Matrix
#B=[B1;B2];# Coefficient Matrix
#X=A**-1*B;# solution Matrix
#V1=X(1);# V
#V2=X(2);# V
I1=2.67;#V1/R1;# A
I2=5.33;#V1/R2-V2/R2;# A
I3=-0.67;#(V2)/R3;# A
print"Current in various branches are : "
print"Current I1(A)",I1
print"Current I2(A)",I2
print"Current I3(A)",I3

Current in various branches are :
Current I1(A) 2.67
Current I2(A) 5.33
Current I3(A) -0.67