Chapter 5 , Kirchhoff's Laws and Network Theorems

Example 5.1 , Page Number 73

In [1]:
import math

#Variables

IT = 20           #Total current (in milli-Ampere)
I2 = 4            #Current (in milli-Ampere)

#Calculation

I1 = IT - I2      #Current (in milli-Ampere)

#Result

print "Value of the current I1 is ",I1," mA."
Value of the current I1 is  16  mA.

Example 5.2 , Page Number 74

In [3]:
import math

#Variables

I = 1               #Current (in Ampere)

#Calculation

#Applying Kirchoff's voltage law:
#(1 *3) + (1 * R) + (1 * 4) - 12 =0

R = 5               #Resistance (in ohm)

#Result

print "Value of R is ",R," ohm."
Value of R is  5  ohm.

Example 5.3 , Page Number 74

In [6]:
import math

#Variables

Vs = 100          #Source Voltage (in volts)
I = 5             #Current entering the circuit (in Ampere)
IL = 5            #Current leaving the circuit (in Ampere)
R15 = 15           #Resistor of 15 ohm (in ohm)
V15 = 30          #Voltage across 15 ohm resistor (in ohm)

#Calculation

I1 = V15 / R15    #Current through 15 ohm resistor (in Ampere)
IA = I + I1       #Current entering junction A (in Ampere)
#Applying Kirchoff's current law
I2 = I + I1       #Current through 5 ohm resistor (in Ampere)
IB = I2           #Current entering juction B (in Ampere)
IR = IA - IL      #Current through R (in Ampere)
#Applying Kirchoff's voltage law
#(7 * 5) + (2 *R) - 100 + 30 =0
R = 35.0/2

#Result

print "The value of R is ",R," ohm."
The value of R is  17.5  ohm.

Example 5.4 , Page Number 75

In [36]:
import math

#Variables

V = 25          #Source voltage (in volts)
RB = 99         #Resistance (in kilo-ohm)
RC = 2          #Resistance (in kilo-ohm)
RE = 1          #Resistance (in kilo-ohm)
VCE = 5         #Voltage across C and E (in volts)

#Calculation

#Applying Kirchoff's Voltage law:
#IB*RB + VBE + IE*RE -V = 0
#IB*RB + VBE + (IB + IC)*RE - VCC = 0
#100*IB + IC = 24
#IB + 3*IC = 20
IC = 1976.0/299
IB = 20 - (3 * 6.61)

#Result

print "Value of IB is ",round(IB,3)," mA.\nValue of IC is ",round(IC,3)," mA."
Value of IB is  0.17  mA.
Value of IC is  6.609  mA.

Example 5.5 , Page Number 77

In [56]:
import math

#Variables

VS1 = 5            #Voltage source 1 (in volts)
VS2 = 3            #Voltage source 2 (in volts)
V6  = 0            #Voltage drop across 6 ohm resistor when AB is open (in volts)
R1 = 6             #Resistor (in ohm)
R2 = 4             #Resistor (in ohm)

#Calculation

I = 5.0/4          #Current through 4 ohm resistor (in Ampere)
V = I * R2         #Voltage drop across 4 ohm Resistor (in volts)
VOC = VS2 + V6 + V #Open circuit voltage (in volts)
Rth = R1

#Result

print "Thevenin's equivalent Voltage is ",VOC," V.\nThevenin's equivalent resistance is ",Rth," ohm."
Thevenin's equivalent Voltage is  8.0  V.
Thevenin's equivalent resistance is  6  ohm.

Example 5.6 , Page Number 78

In [59]:
import math

#Variables

V = 25.0                                  #Source voltage (in volts)
R1 = 100.0                                #Resistance (in ohm)
R2 = 75.0                                 #Resistance (in ohm)
R3 = 50.0                                 #Resistance (in ohm)
R4 = 25.0                                 #Resistance (in ohm)
RL = 250.0                                #Load resistance (in ohm)     

#Calculation

I = V / (R1 + R2 + R3)                  #Series curren (in Ampere)
VR2 = I * R2                            #Voltage drop across R2
VOC = VR2                               #Open circuit voltage (in volts)
Vth = VOC                               #Thevenin's equivalent voltage (in volts)
Rth = R4 + R2*(R1 + R3)/(R1 + R2 + R3)  #Thevenin's equivalent resistance (in ohm)
IL = Vth/(Rth + RL)

#Result

print "Thevenin's equivalent voltage is ",round(Vth,3)," V. and resistance in ",Rth," ohm."
print "Current through load resistance is ",round(IL,3)," A."
Thevenin's equivalent voltage is  8.333  V. and resistance in  75.0  ohm.
Current through load resistance is  0.026  A.

Example 5.7 , Page Number 80

In [2]:
import math

#Variables

R1 = 2.0                                #Resistance (in kilo-ohm)
R2 = 1.0                                #Resistance (in kilo-ohm)
R3 = 2.0                                #Resistance (in kilo-ohm)
I = 0.1                                 #Current source (in Ampere)

#Calculation

#Using Thevenin's theorem : 

I2 = I * R1 / (R1 + (R2 +R3))         #Current through brach ECD (in Ampere)
VR3 = I2 * R3* 10 **3                 #Voltage drop across R3 (in volts)
Vth = VR3                             #Thevenin's Voltage
Rth = R3 * (R1 + R2)/(R1 + R2 + R3)

#Result

print "Thevenin's voltage is ",Vth," V.\nThevenin's Resistance is ",Rth," kilo-ohm." 
Thevenin's voltage is  80.0  V.
Thevenin's Resistance is  1.2  kilo-ohm.

Example 5.8 , Page Number 82

In [4]:
import math

#Variables

R1 = 0.6                                    #Resistance (in ohm)
R2 = 0.6                                    #Resistance (in ohm)
R3 = 0.8                                    #Resistance (in ohm)
R4 = 0.8                                    #Resistance (in ohm)

#Calculation

Rth = R3 + R4*(R1 + R2)/(R4 + (R1 +R2))     #Thevenin's resistance (in ohm)

#Result

print "The value of Rth is ",Rth," ohm."
The value of Rth is  1.28  ohm.

Example 5.9 , Page Number 83

In [6]:
import math

#Variables

V = 12.0                                 #Voltage (in volts)
R1 = 3.0                                 #Resistance (in ohm)
R2 = 9.0                                 #Resistance (in ohm)

#Calculation

#Using Norton's Theorem

Isc = V / R1                           #Short circuit current (in Ampere)
IN = Isc                               #Norton's Current (in Ampere)
RN = R1 * R2 / (R1 + R2)               #Norton's resistance (in ohm)

#Result

print "Norton's Current is ",IN," A.\nNorton's Resistance is ",RN," ohm." 
Norton's Current is  4.0  A.
Norton's Resistance is  2.25  ohm.

Example 5.10 , Page Number 85

In [9]:
import math

#Variables

V = 15.0                        #Voltage 15 volt battery (in volts)
R1 = 6.0                        #Resistance (in ohm)
R2 = 3.0                        #Resistance (in ohm)
R3 = 3.0                        #Resistance (in ohm)
V0 = 30.0                       #Voltage 30 volt battery (in volts)

#Calculation

R4 = R2 * R3 / (R2 + R3)      #R4 = R2 || R3 (in ohm)
V1 = R4 / (R1 + R4) * V       #Voltage drop across R4 (in volts)
R5 = R1 * R3 / (R1 + R3)      #R5 = R1 || R3 (in ohm)
V2 = R5 / (R2 + R5) * V0      #Voltage drop across R5 (in volts)
I = V/R3

#Result

print "In case 1: Voltage drop across R3 is ",V1," V.\nIn case 2: Voltage drop across R3 is ",V2," V.\nThe current through R3 is ",I," A."  
In case 1: Voltage drop across R3 is  3.0  V.
In case 2: Voltage drop across R3 is  12.0  V.
The current through R3 is  5.0  A.

Example 5.11 , Page Number 88

In [13]:
import math

#Variables

Vth = 100                      #Thevenin Voltage (in micro-volts)
Rth = 50                       #Thevenin Resistance (in ohm)

#Calculation

RL = Rth                       #Maximum Load Resistance (in ohm)
PL = (Vth/(Rth + RL))**2 *RL   #Maximum load power (in pico-watt)

#Result
print "Maximum load resistance is ",RL," ohm.\nMaximum load power is ",PL," pW."
Maximum load resistance is  50  ohm.
Maximum load power is  50  pW.

Example 5.12 , Page Number 88

In [1]:
import math

#Variables

VTH = 20.0 * 10**-3              #Thevenin's Voltage (in volts)
RTH = 300.0                      #Thevenin's Resistance (in ohm) 
RL = 300.0                       #Load Resistance (in ohm)

#Calculation

PL = (VTH/(RTH + RL))**2 * RL    #Power across load resistance (in watt)   

#Result

print "The value of power transmitted to the receiver is ",round(PL*10**6,2)," micro-watt."
The value of power transmitted to the receiver is  0.33  micro-watt.

Example 5.13 , Page Number 89

In [62]:
import math

#Variables

R1 = 5.0                      #resistance (in ohm)
R2 = 2.0                      #resistance (in ohm)
R3 = 3.0                      #resistance (in ohm)

#Calculation

Req = R2 * R3 / (R2 + R3)   #Equivalent resistance (in ohm)
RL = R1 + Req

#Result

print "Load resistance is ",RL," ohm."
Load resistance is  6.2  ohm.