import math # This will import math module
VCC=30 #collector voltage(V)
RE=20 #Emitter resistance(Ohm)
R1=490.0 #Base resistance1 (Ohm)
R2=68.0 #Base resistance2 (Ohm)
VBE=0.7 #Base-emitter voltage drop(V)
RL=180 #Load Resistance(Ohm)
RC=120 #Collector resistance(Ohm)
VB=VCC*(R2/(R1+R2)) #Base voltage(V)
VE=math.ceil(VB-VBE) #Emitter voltage(V)
IE=VE/RE #Emitter current(A)
ICQ=IE #collector current (A)
VC=VCC-(ICQ*RC) #collector voltage(V)
VCEQ=VC-VE #collector-emitter voltage (V)
rc=RC*RL/(RC+RL) #ac collector resistance(Ohm)
print 'Collector current ICQ = ',ICQ*1000,'mA'
print 'collector-emitter voltage VCEQ = ',VCEQ,'V'
print 'ac collector resistance rc = ',rc,'Ohm'
VCC=30 #collector voltage(V)
RE=20 #Emitter resistance(Ohm)
R1=490.0 #Base resistance1 (Ohm)
R2=68.0 #Base resistance2 (Ohm)
VBE=0.7 #Base-emitter voltage drop(V)
RL=180 #Load Resistance(Ohm)
RC=120 #Collector resistance(Ohm)
ICQ=150 #collector current (mA)
VCEQ=9 #collector-emitter voltage (V)
rc=72.0 #ac collector resistance(Ohm)
ic_sat=ICQ+(VCEQ/rc)*1000 #ic(sarturation) (mA)
VCE_cut=VCEQ+((ICQ*rc)/1000) #VCE(cut-off) (V)
MP1=ICQ*RC
MP2=VCEQ
MPP=2*(min(MP1,MP2)) #maximum peak-to-peak voltage (V)
print 'ic(sarturation) = ',ic_sat,'mA'
print 'VCE(cut-off) = ',VCE_cut,'V'
print 'maximum peak-to-peak voltage MPP = ',MPP,'V'
import math # This will import math module
VCC=30 #collector voltage(V)
RE=20 #Emitter resistance(Ohm)
R1=490.0 #Base resistance1 (Ohm)
R2=68.0 #Base resistance2 (Ohm)
VBE=0.7 #Base-emitter voltage drop(V)
RL=180.0 #Load Resistance(Ohm)
RC=120 #Collector resistance(Ohm)
vin=200 #input voltage(mV)
zin=100 #input impedance of base(Ohm)
MPP=18 #peak-to-peak voltage (V)
Zin_stage=((zin**-1)+(R1**-1)+(R2**-1))**-1 #input impedance of stage(KOhm)
Pin=vin**2/(Zin_stage*8)/1000 #ac input power (mW)
Pout=1000*MPP**2/(RL*8) #ac output power (mW)
Ap=Pout/Pin #power gain
print 'Power gain Ap = ',math.ceil(Ap)
import math # This will import math module
VCC=30 #collector voltage(V)
RE=20 #Emitter resistance(Ohm)
R1=490.0 #Base resistance1 (Ohm)
R2=68.0 #Base resistance2 (Ohm)
VBE=0.7 #Base-emitter voltage drop(V)
RL=180 #Load Resistance(Ohm)
RC=120 #Collector resistance(Ohm)
VB=VCC*(R2/(R1+R2)) #Base voltage(V)
VE=math.ceil(VB-VBE) #Emitter voltage(V)
IE=VE/RE #Emitter current(A)
ICQ=IE #collector current (A)
VC=VCC-(ICQ*RC) #collector voltage(V)
VCEQ=VC-VE #collector-emitter voltage (V)
PDQ=VCEQ*ICQ #power dissipation(W)
I_bias=VCC/(R1+R2) #bias current(mA)
Idc=I_bias+ICQ #dc current(mA)
Pdc=VCC*Idc #dc input power to stage(W)
Pout=0.225 #Output power as per example 12-3 (W)
n=(Pout/Pdc)*100 #efficiency of stage
print 'Power dissipation PDQ = ',PDQ,'W'
print 'efficiency of stage n = ',round(n,2),'%'
VCC=12 #collector voltage(V)
RE=16 #Emitter resistance(Ohm)
R1=50.0 #Base resistance1 (Ohm)
R2=100.0 #Base resistance2 (Ohm)
VBE=0.7 #Base-emitter voltage drop(V)
RL=16 #Load Resistance(Ohm)
VB=VCC*(R2/(R1+R2)) #Base voltage(V)
VE=(VB-VBE) #Emitter voltage(V)
IE=VE/RE #Emitter current(A)
ICQ=IE #collector current (A)
VCEQ=VCC-VE #collector-emitter voltage (V)
re=RE*RL/(RE+RL) #ac emitter resistance(Ohm)
print 'Collector current ICQ = ',ICQ*1000,'mA'
print 'collector-emitter voltage VCEQ = ',VCEQ,'V'
print 'ac collector resistance re = ',re,'Ohm'
VCC=12 #collector voltage(V)
RE=16 #Emitter resistance(Ohm)
R1=50.0 #Base resistance1 (Ohm)
R2=100.0 #Base resistance2 (Ohm)
VBE=0.7 #Base-emitter voltage drop(V)
RL=16 #Load Resistance(Ohm)
ICQ=456 #collector current (mA)
VCEQ=4.7 #collector-emitter voltage (V)
re=8.0 #ac emitter resistance(Ohm)
ic_sat=(1000*(VCEQ/re))+ICQ #ic(sarturation) (mA)
VCE_cut=VCEQ+(ICQ*re)/1000 #VCE(cut-off) (V)
MP1=ICQ*re/1000
MP2=VCEQ
MPP=2*(min(MP1,MP2)) #maximum peak-to-peak voltage (V)
print 'ic(sarturation) = ',ic_sat/1000,'A'
print 'VCE(cut-off) = ',VCE_cut,'V'
print 'maximum peak-to-peak voltage MPP = ',MPP,'V'
VCC=20 #collector voltage(V)
R1=100.0 #Base resistance1 (Ohm)
R2=100.0 #Base resistance2 (Ohm)
VBE=0.7 #Base-emitter voltage drop(V)
RL=8.0 #Load Resistance(Ohm)
MPP=VCC #maximum peak-to-peak voltage (V)
PD_max=MPP**2/(40*RL) #Maximum power dissipation(W)
Pout_max=MPP**2/(8*RL) #Maximum output power(W)
print 'Maximum power dissipation PD_max = ',PD_max,'W'
print 'Maximum output power Pout_max = ',Pout_max,'W'
import math
VCC=20 #collector voltage(V)
R1=100.0 #Base resistance1 (Ohm)
R2=100.0 #Base resistance2 (Ohm)
VBE=0.7 #Base-emitter voltage drop(V)
RL=8.0 #Load Resistance(Ohm)
Ra=15 #adjustable resistor(Ohm)
VCEQ=VCC/2 #collector-emitter voltage (V)
I_bias=VCC/(R1+R2+Ra) #bias current(mA)
Ic_sat=VCEQ/RL #ic(sarturation) (mA)
Iav=Ic_sat/math.pi #average current (A)
Idc=I_bias+Iav #dc current(mA)
Pdc=VCC*Idc #dc input power to stage(W)
Pout=6.25 #Output power as per example 12-8 (W)
n=(Pout/Pdc)*100 #efficiency of stage
print 'efficiency of stage n = ',round(n,2),'%'
VCC=20 #collector voltage(V)
R1=3.9 #Base resistance1 (KOhm)
R2=3.9 #Base resistance2 (KOhm)
VBE=0.7 #Base-emitter voltage drop(V)
RL=10.0 #Load Resistance(Ohm)
VCEQ=VCC/2 #collector-emitter voltage (V)
I_bias=(VCC-(2*VBE))/(R1+R2) #bias current(mA)
Ic_sat=VCEQ/RL #ic(sarturation) (mA)
Iav=Ic_sat/math.pi #average current (A)
Idc=(I_bias/1000)+Iav #dc current(mA)
Pdc=VCC*Idc #dc input power to stage(W)
Pout=VCC**2/(8*RL) #Output power (W)
n=(Pout/Pdc)*100 #efficiency of stage
print 'efficiency of stage n = ',round(n,2),'%'
import math
L=2*10**-6 #inductance (H)
C=470*10**-12 #capacitance(F)
fr=((2*math.pi)*((L*C)**0.5))**-1
print 'Resonant frequency fr = ',round((fr*10**-6),2),'MHz'
import math
fr=5.19*10**6 #frequency as per previous example(Hz)
L=2*10**-6 #inductance (H)
C=470*10**-12 #capacitance(F)
QL=100 #quality factor of coil
RL=1 #Load resistance(KOhm)
XL=2*math.pi*fr*L #inductive impedance(Ohm)
Rp=QL*XL/1000 #Eq. parallel resistance of coil(KOhm)
rc=1000*Rp*RL/(Rp+RL) #ac collector resistance(Ohm)
Q=rc/XL #Q of overall circuit
BW=(fr/Q/1000) #band width of amplifier(KHz)
print 'band width of amplifier BW = ',round(BW,2),'KHz'
import math # This will import math module
VCC=15 #collector voltage(V)
rc=867.0 #ac collector resistance as per preceding example (Ohm)
MPP=2*VCC #Maximum peak-to-peak voltage(V)
PD=1000*MPP**2/(40*rc) #worst-case power dissipation(mW)
print 'Worst-case power dissipation PD = ',math.ceil(PD),'mW'
PD=625 #maximum power rating at 25 deg C(mW)
D=5 #Derating factor(mW/deg C)
TA=50 #ambient temperature(deg C)
DP=D*(TA-25) #difference in power(mW)
PD_max=PD-DP #maximum power rating(mW)
print 'Maximum power rating PD_max = ',PD_max,'mW'