Chapter 13 , Special Purpose Diodes and Opto-Electornic Devices

Example 13.1 , Page Number 253

In [1]:
import math

#Variables

PZM = 500                         #Power rating of zener diode (in milli-watt)
VZ = 6.8                          #Zener voltage rating (in volts)

#Calculation

IZM = PZM / VZ                    #Maximum value of zener current (in milli-Ampere)

#Result

print "THe value of IZM for the device is ",round(IZM,1)," mA."
THe value of IZM for the device is  73.5  mA.

Example 13.2 , Page Number 253

In [2]:
import math

#Variables

PZM = 500                             #Power rating of zener diode (in milli-watt)
df = 3.33                             #derating factor (in milli-watt)
T1 = 75                               #Temperature (in degree Celsius)
T2 = 50                               #Temperature (in degree Celsius)

#Calculation

Tdf = df * (T1 - T2)                  #Total derating factor (in milli-watt)
PZ = PZM - Tdf                        #Maximimum power dissipating for the device (in milli-watt)

#Result

print "The maximum power dissipation for the device is ",PZ," mW." 
The maximum power dissipation for the device is  416.75  mW.

Example 13.3 , Page Number 254

In [3]:
import math

#Variables

IZ1 = 20                       #Reverse current (in milli-Ampere)
IZ2 = 30                       #Reverse current (in milli-Ampere)
VZ1 = 5.6                      #Zener voltage (in volts)
VZ2 = 5.65                     #Zener voltage (in volts)

#Calculation

dIZ = IZ2 - IZ1                #Change in reverse current (in milli-Ampere)
dVZ = VZ2 - VZ1                #Change in zener voltage (in volts)
rZ = dVZ / (dIZ * 10**-3)      #Resistance of device (in ohm)

#Result

print "Resistance of the zener diode is ",rZ," ohm."
Resistance of the zener diode is  5.0  ohm.

Example 13.4 , Page Number 254

In [4]:
import math

#Variables

VZ = 4.7                          #Zener voltage (in volts)
rZ = 15                           #Resistance (in ohm)
IZ = 20 * 10**-3                  #Current (in Ampere)

#Calculation

VZ1 = VZ + IZ * rZ                #Terminal voltage of a zener diode (in volts)
 
#Result

print "Terminal voltage of the zener diode is ",VZ1," V."
Terminal voltage of the zener diode is  5.0  V.

Example 13.5 , Page Number 262

In [1]:
import math

#Variables

C1min = C2min = Cmin = 5                        #Minimum capacitance (in pico-farad)
C1max = C2max =  Cmax = 50                      #Maximum capacitance (in pico-farad)
L = 10                                          #Inductance (in milli-Henry)
 
#Calculation

CTmin = C1min * C2min / (C1min + C2min)         #Total minimum capacitance (in pico-farad)
CTmin = CTmin * 10**-12                         #Total minimum capacitance (in farad)
L = 10 * 10**-3                                 #Inductance (in Henry)
f0max = 1/(2*math.pi*(L*CTmin)**0.5)            #Maximun resonant frequency (in Hertz)
CTmax = C1max * C2max / (C1max + C2max)         #Total maximum capacitance (in pico-farad)
CTmax = CTmax * 10**-12                         #Total minimum capacitance (in farad)
f0min = 1/(2*math.pi*(L*CTmax)**0.5)            #Minimum resonant frequency (in Hertz)

#Result

print "Tuning range for the circuit is between ",round(f0min * 10**-3)," kHz and ",round(f0max * 10**-6,0)," MHz."
Tuning range for the circuit is between  318.0  kHz and  1.0  MHz.

Example 13.6 , Page Number 266

In [6]:
import math

#Variables

T = 0.04 * 10**-6                     #Time period (in seconds)

#Calculation

f = 1/T                               #Frequency (in Hertz)
f = f * 10**-6                        #Frequency (in Mega-Hertz)
f5 = 5 * f                            #%th - harmonic (in Mega-Hertz)

#Result

print "Frequency of 5th harmonic is ",f5," MHz."
Frequency of 5th harmonic is  125.0  MHz.

Example 13.7 , Page Number 270

In [7]:
import math

#Variables

Vout = 8.0                     #Output voltage (in volts)
VFmin = 1.8                    #LED min voltage (in volts)
VFmax = 2.0                    #LED max voltage (in volts)
IFmax = 16 * 10**-3            #Maximum current (in Ampere)

#Calculation

RS = (Vout - VFmin) / IFmax    #Current limiting Resistor (in ohm)
RS1 = (Vout - VFmax) / IFmax   #Current limiting Resistor 1 (in ohm)

#Result

print "In either case , the smallest standard-value resistor that has a value greater than ",RS, " ohm or ",RS1,"  ohm is the 390 ohm resistor.\nTherefore Rs should be 390 ohm." 
In either case , the smallest standard-value resistor that has a value greater than  387.5  ohm or  375.0   ohm is the 390 ohm resistor.
Therefore Rs should be 390 ohm.

Example 13.8 , Page Number 271

In [8]:
import math

#Variables

VDmin = 1.5               #minimum voltage drop (in volts)
VDmax = 2.3               #maximum voltage drop (in volts)
VS = 10                   #Source voltage (in volts)
R1 = 470                  #Resistance (in ohm)

#Calculation

Imax = (VS - VDmin) / R1  #Maximum current (in Ampere)
Imin = (VS - VDmax) / R1  #Minimum current (in Ampere)

#Result

print "Minimum value of LED current is ",round(Imin * 10**3,1)," mA.\nMaximum value of LED current is ",round(Imax * 10**3,1)," mA." 
Minimum value of LED current is  16.4  mA.
Maximum value of LED current is  18.1  mA.

Example 13.9 , Page Number 271

In [9]:
import math

#Variables

VDmin = 1.8                  #minimum voltage drop (in volts)
VDmax = 3.0                  #maximum voltage drop (in volts)

#Calculation

#Case 1

VS = 24.0                    #Source voltage (in volts)
RS = 820.0                   #Resistance (in ohm)
Imax = (VS - VDmin) / RS     #Maximum current (in Ampere)
Imin = (VS - VDmax) / RS     #Minimum current (in Ampere)
dI = Imax - Imin             #Change in current (in Ampere)

#Case 2

VS1 = 5.0                    #Source voltage (in volts)
RS1 = 120.0                  #Resistance (in ohm)
Imax1 = (VS1 - VDmin) / RS1  #Maximum current (in Ampere)
Imin1 = (VS1 - VDmax) / RS1  #Minimum current (in Ampere)
dI1= Imax1 - Imin1           #Change in current (in Ampere)

#Result

print "Since change in current in case 1 i.e",round(dI*10**3,2),"mA is less than change in current in case 2 i,e,",round(dI1* 10**3,2)," mA." 
print "Therefore brightness in the first case will remain constant."

#printing mistake in book for value of VDmin. It should be 1.8 volts instead of 1.1 volts.
Since change in current in case 1 i.e 1.46 mA is less than change in current in case 2 i,e, 10.0  mA.
Therefore brightness in the first case will remain constant.

Example 13.10 , Page Number 281

In [10]:
import math

#Variables

R1 = 100.0 * 10**3             #Resistance when illuminated (in ohm)
r = 1.0 * 10**3                #cell resistance (in ohm)
I = 10.0 * 10**-3              #Current (in Ampere)
VS = 30                        #Source voltage (in volts)

#Calculation

R = VS/I - r                   #R is the series resitance (in ohm)
Id = VS / (R + R1)             #Dark current (in Ampere)

#Result

print "Ther series resistance required is ",R/1000," kilo-ohm.\nThe dark current is ",round(Id * 10**3,1)," A." 
Ther series resistance required is  2.0  kilo-ohm.
The dark current is  0.3  A.

Example 13.11 , Page Number 284

In [11]:
import math

#Variables

V = 12.0                        #Battery voltage (in volts)
I = 0.5                         #Current (in Ampere)
T = 24                          #Time period (in hours)
V1 = 0.5                        #Voltage by each cell (in volts)
I1 = 50 * 10**-3                #Current in each cell (in Ampere)

#Calculation

VS = 13.5                       #Solar bank voltage (in volts)
n = VS / V1                     #Number of series connected solar cells 
Q = T/2 * I                     #Charge given out in one day (in Ampere-Hour)
I2 = Q / (T/2)                  #Charging current (in Ampere)
N = I2/I1                       #Number of groups of solar cell required                     
nT = n * N                      #Total number of solar cells required               

#Result

print "Total cells required is ",nT,"." 
Total cells required is  270.0 .