Chapter 4: Small signal amplifliers

Example 4.1, Page No.118

In [7]:
# voltage

import math
#Variable declaration
Rc=4.7            # in ohm
Vcc=24.0          # in V
Ic1=0             # in A
Ic=1.5            # in mA
#this is given as 15 mA in textbook which is wrong

#Calculations
Vce=Vcc-(Ic*Rc*10**-3*10**3)
Vce1=Vcc-Ic1*Rc

#Result
print("(i) Collector to emitter voltage,Vce(V)  =  %.2f"%Vce)
print("(ii) Collector to emitter voltage,Vce(V) =  %.f"%Vce1)
(i) Collector to emitter voltage,Vce(V)  =  16.95
(ii) Collector to emitter voltage,Vce(V) =  24

Example 4.2, Page No. 118

In [6]:
# vce

import math
#Variable declaration
Beta=100.0
Rb=200*10**3          # in ohm
Rc=1*10**3            # in ohm
Vcc=10.0              # in V

#Calculations
Ib=Vcc/Rb             # in A
Ic=Beta*Ib            # in A
Vce=Vcc-(Ic*Rc)

#Result
print("Collector to emitter voltage,Vce(V) =  %.f"%Vce)
Collector to emitter voltage,Vce(V) =  5

Example 4.3, Page No. 119

In [10]:
# base resistance

import math
#Variable declaration
Vcc=20.0               # in V
Vbe=0.73               # in V
Rc=2.0                 # in kilo-ohm
Icsat= Vcc/Rc          #in mA
Beta=200.0

#RCalculatons
Ib=(Icsat/Beta)*10**3     # in micro-A
Rb=((Vcc-Vbe)/(Ib))*10**3 # in kilo-ohm

#Result
print("Rb < %.f  kilo-ohm"%(math.ceil(Rb)))
Rb < 386  kilo-ohm

Example 4.4, Page No. 119

In [12]:
# operating point

import math
#Variable declaration
Vcc=15.0             # in V
Rb=200.0             # in k-ohm
Rc=2.0               # in k-ohm
Beta=50.0

#Calculations
Ib=(Vcc/(Rb*10**3+(Beta*Rc*10**3)))*10**6
Ic=Beta*Ib*10**-3
Vce=Vcc-(Ic*10**-3*(Rc*10**3))

#Result
print("collector current,Ic(mA) = %.1f"%Ic)
print("Collector to emitter voltage,Vce(V) = %.f"%Vce)
collector current,Ic(mA) = 2.5
Collector to emitter voltage,Vce(V) = 10

Example 4.5, Page No. 120

In [14]:
# resistor

import math
#Variable declaration
Vcc=15.0             # in V
Vce=6.0              # in V
Rc=3*10**3           # in ohm
Beta=50.0


#Calculations
Ic=(Vcc-Vce)/Rc
Ib=Ic/Beta;
Rb=((Vcc/Ib)-(Beta*Rc))*10**-3

#Result
print("The value of resistoe,Rb(k-ohm) = %.f"%Rb)
The value of resistoe,Rb(k-ohm) = 100

Example 4.6, Page No. 120

In [17]:
# operating point

import math
#Variable declaration
Vcc=12.0            # in V
Rb1=70.0            # in k-ohm
Rb2=70.0            # in k-ohm
Beta=50.0
Rc=2.0              # in k-ohm

#Calculations
Ib=Vcc/((Rb1+Rb2+(Beta*Rc))*10**3)
Ic=Beta*Ib*10**3
Vce=Vcc-(Ic*Rc)

#Result
print("Collector current,Ic(mA) = %.1f"%Ic)
print("Collector to emitter voltage,Vce(V) = %.f"%Vce)
Collector current,Ic(mA) = 2.5
Collector to emitter voltage,Vce(V) = 7

Example 4.7, Page No. 121

In [19]:
# operating point

import math
#Variable declaration
Vcc=9.0             # in V
Rb=50.0             # in k-ohm
Rc=250.0            # in ohm
Re=500.0            # in ohm
Beta=80.0

#Calculations
Ib=Vcc/(Rb*10**3+(Beta*Re))
Ic=Beta*Ib*10**3
Vce=Vcc-(Ic*10**-3*(Rc+Re));

#Result
print("collector current,Ic(mA) = %.f"%Ic)
print("Collector to emitter voltage,Vce(V) = %.f"%Vce)
collector current,Ic(mA) = 8
Collector to emitter voltage,Vce(V) = 3

Example 4.8, Page No. 121

In [21]:
# operating point

import math
#Variable declaration
R2=4.0            # in k-ohm
R1=40.0           # in k-ohm
Vcc=22.0          # in V
Rc=10.0           # in k-ohm
Re=1.5            # in k-ohm
Vbe=0.5           # in V

#Calculations
Voc=R2*10**3*Vcc/((R1+R2)*10**3)
Ic=(Voc-Vbe)/(Re*10**3)
Vce=Vcc-(Rc+Re)*Ic*10**3

#Result
print("Collector to emitter voltage,Vce(V) = %.1f"%Vce)
Collector to emitter voltage,Vce(V) = 10.5

Example 4.9, Page No.124

In [23]:
# maximum collector current

import math
#Variable declaration
Bv=12.0           # battery voltage in V
Cl=6.0            # collector load in k-ohm

#Calculations
CC=Bv/Cl

#Result
print("Collector current,(mA) = %.f"%CC)
Collector current,(mA) = 2

Example 4.10, Page No. 125

In [25]:
# maximum collector current

import math
#Variable declaration
Bv=12.0           # battery voltage in V
P=2.0             # power in Watt

#Calculations
Ic=(P/Bv)*10**3

#Result
print("The maximum collector current,Ic(mA) = %.1f"%Ic)
The maximum collector current,Ic(mA) = 166.7

Example 4.11, Page No. 125

In [70]:
# gain

import math
#Variable declaration
del_ic=1.0        # in mA
del_ib=10.0       # in micro-A
del_Vbe=0.02      # in V
del_ib=10*10**-6  # in A
Rc=2.0            # in k-ohm
Rl=10.0           # in k-ohm

#Calculations
Beta=del_ic/(del_ib*10**3)
Ri=(del_Vbe/del_ib)*10**-3
Rac=Rc*Rl/(Rc+Rl);
Av=round(Beta*Rac/Ri);
Ap=Beta*Av;

#Result
print("Current gain,Beta         = %.f"%Beta)
print("Input impedence,Ri(k-ohm) = %.f"%Ri)
print("Effective load,Rac(k-ohm) = %.2f"%(math.floor(Rac*100)/100))
print("Voltage gain,Av           = %.f"%Av)
print("power gain,Ap             = %.f"%Ap)
Current gain,Beta         = 100
Input impedence,Ri(k-ohm) = 2
Effective load,Rac(k-ohm) = 1.66
Voltage gain,Av           = 83
power gain,Ap             = 8300

Example 4.12, Page No. 125

In [34]:
# output voltage

import math
#Variable declaration
Rc=10.0         # in k-ohm
Rl=10           # in k-ohm
Beta=100.0
Ri=2.5
Iv=2.0          # input voltage in mV

#Calculations
Rac=Rc*Rl/(Rc+Rl)
Av=round(Beta*Rac/Ri)
Ov=Av*Iv*10**-3

#Result
print("Output voltage,(V) = %.1f"%Ov)
Output voltage,(V) = 0.4

Example 4.13, Page No.133

In [79]:
# gain and resistance 

import math
#Variable declaration
I=1.0
hfe=46.0
hoe=80*10**-6
hre=5.4*10**-4
hie=800.0             # in ohm
RL=5*10**3            # in ohm
Rg=500                # in ohm

#Result
Aie=hfe/(I+(hoe*RL))
Aie = math.floor(Aie*10)/10
Zie=hie-(hre*RL*Aie)
Ave=(Aie*RL)/Zie
Ave=math.floor(Ave*10)/10
Zoe=((hie+Rg)/(hoe*(hie+Rg)-(hfe*hre)))/10**3
Ape=Aie*Ave

#Result
print("Current gain,Aie             = %.1f"%(Aie))
print("Input resistance,Zie(ohm)    = %.1f"%(Zie))
print("Voltage gain,Ave             = %.1f"%Ave)
print("Output resistance,Zoe(k-ohm) = %.1f"%Zoe)
print("Power gain,Ape               = %.1f"%Ape)
#voltage gain and power gain are calculated wrong in the textbook
Current gain,Aie             = 32.8
Input resistance,Zie(ohm)    = 711.4
Voltage gain,Ave             = 230.5
Output resistance,Zoe(k-ohm) = 16.4
Power gain,Ape               = 7560.4

Example 4.14, Page No.141

In [40]:
# gain and voltage

import math
#Variable declaration
A=100.0              # gain without feedback
Beta=1.0/25          # feed back ratio
vi=50.0              # mV
Af=(A/(1+(Beta*A)))  # gain with feedback
ff=Beta*A            # feedback factor
Vo=Af*vi*10**-3      # in V
fv=Beta*Vo           # in V
vin=vi*(1+Beta*A)    # mV

#Result
print("gain with feedback is ,              = %.f"%Af)
print("feedback factor is,                  = %.f"%ff)
print("output voltage is ,(V)               = %.f"%Vo)
print("feedback voltage is ,(V)             = %.2f"%fv)
print("new increased input voltage is ,(mV) = %.f"%vin)
gain with feedback is ,              = 20
feedback factor is,                  = 4
output voltage is ,(V)               = 1
feedback voltage is ,(V)             = 0.04
new increased input voltage is ,(mV) = 250

Example 4.15, Page No. 142

In [81]:
# voltage gain

import math
#Variable declaration
A=1000.0               # gain without feedback
fctr=0.40              # gain reduction factor

A2=800.0               # redued gain

#Calculations
Af=A-fctr*A                # gain with feedback
Beta=((A/Af)-1)/A          # feed back ratio
Af2=((A2)/(1+(Beta*A2)))
prfb= ((A-A2)/A)*100       #percentage reduction without feedback
prwfb= ((Af-Af2)/Af)*100   #percentage reduction without feedback

#Result
print("(i) voltage gain  is ,                             = %.1f"%Af2)
print("(ii) percentage reduction without feedback is,(%%) = %.f"%prfb)
print("     percentage reduction with feedback is,(%%)    = %.2f"%(math.ceil(prwfb*100)/100))
(i) voltage gain  is ,                             = 521.7
(ii) percentage reduction without feedback is,(%) = 20
     percentage reduction with feedback is,(%)    = 13.05

Example 4.16, Page No. 142

In [58]:
# small change in gain

import math
#Variable declaration
A=200.0            #gain without feedback
Beta=0.25          #feed back ratio
gc=10              #percent gain change

#Calculations
dA=gc/100.0
dAf= ((1/(1+Beta*A)))*dA
#Result
print("small change in gain is, = %.4f"%(math.floor(dAf*10**4)/10**4))
small change in gain is, = 0.0019

Example 4.17, Page No.143

In [83]:
# input voltage

import math
#Variable declaration
A=200.0              # gain without feedback
Beta=0.05            # feed back ratio
Dn=10.0              # percentage distortion
vo=0.5               # initial output voltage

#Calculations
Af=(A/(1+(Beta*A)))  # gain with feedback
Dn1=(Dn/(1+A*Beta))  # percentage Distortion with negative feedback
ff=Beta*A            # feedback factor
vi=A*vo              # in V
vin=vi/Af            # in V

#Result
print("gain with negative feedback is ,                      = %.1f"%Af)
print("percentage Distortion with negative feedback is ,(%%)  = %.3f"%Dn1)
print("new input voltage is ,(V)                             = %.1f"%vin)
#gain and input voltage are calculated wrong in the textbook   
gain with negative feedback is ,                      = 18.2
percentage Distortion with negative feedback is ,(%)  = 0.909
new input voltage is ,(V)                             = 5.5

Example 4.18, Page No. 143

In [84]:
# percentage of feedback

import math
#Variable declaration
A=50.0                     # gain without feedback
Af=10.0                    # gain with feedback

#Calculations
Beta=(((A/Af)-1)/A)*100    # feed back ratio
print("percentage of feedback is ,(%%) = %.f"%Beta)
percentage of feedback is ,(%) = 8

Example 4.19, Page No. 144

In [52]:
# band width

import math
#Variable declaration
Bw=200.0                # bandwidth in kHz
vg=40.0                 # dB
fb=5.0                  # percentage negetive feedback
A=40.0                  # gain without feedback

#Calculations
Beta=fb/100             # feed back ratio
Af=(A/(1+(Beta*A)))     # gain with feedback
Bwf= (A*Bw)/Af          # Bandwidth with feedback

#Result
print(" new band-width is ,(kHz) = %.f"%Bwf)
 new band-width is ,(kHz) = 600

Example 4.20, Page No. 144

In [55]:
# percentage reduction

import math
#Variable declaration
A=50.0                # gain without feedback
Af=25.0               # gain with feedback
Ad=40.0               # new gain after ageing

#Calculations
Beta=(((A/Af)-1)/A)   # feed back ratio
Af1=(Ad/(1+(Beta*Ad)))# new gain with feedback
df=Af-Af1             # reduction in gain
pdf= (df/Af)*100      # percentage reduction in gain

#Result
print(" percentage reduction in gain is ,(%%) = %.1f"%pdf)
 percentage reduction in gain is ,(%) = 11.1

Example 4.21, Page No. 145

In [57]:
# Av and beta

import math
#Variable declaration
Af=100.0               # gain with feeback
vi=50.0                # in mV
vi1=60.0               # in mV

#Calcualtion
AAf=vi1/vi
A=AAf*Af
Beta=(((A/Af)-1)/A)

#Result
print("Av is ,= %.f"%A)
print("feedback factor is, = %.5f or 1/600"%Beta)
Av is ,= 120
feedback factor is, = 0.00167 or 1/600