VCC=10 #collector voltage(V)
RE=4.3 #Emitter resistance(KOhm)
R1=10 #Base resistance1 (KOhm)
R2=10 #Base resistance2 (KOhm)
VBE=0.7 #Base-emitter voltage drop(V)
RL=10 #Load Resistance(KOhm)
VG=1 #Input voltage(mV)
RG=0.6 #internal resistance of source(KOhm)
B=200 #current gain
VBB=VCC/2 #Base voltage(V)
VE=VBB-VBE #Emitter voltage(V)
IE=VE/RE #Emitter current(mA)
re1=(25/IE) #AC resistance(Ohm)
re=RE*RL/(RE+RL) #external ac resistance(KOhm)
Zin_base=(re+(re1/1000))*B #input impedance of base(KOhm)
Zin_stage=((R1**-1)+(Zin_base**-1)+(R2**-1))**-1 #input impedance of stage(KOhm)
print 'input impedance of stage Zin(base) = ',round(Zin_base,2),'KOhm'
print 'input impedance of stage Zin(stage) = ',round(Zin_stage,2),'KOhm'
re=3.03 #Emitter resistance(KOhm)
VG=1 #Input voltage(mV)
RG=0.6 #internal resistance of source(KOhm)
B=200 #current gain
Zin=5 #input impedance(KOhm)
Vin=(Zin/(Zin+RG))*VG #input voltage(V)
print 'Input voltage Vin = ',round(Vin,2),'V'
VCC=15 #collector voltage(V)
RE=2.2 #Emitter resistance(KOhm)
R1=4.7 #Base resistance1 (KOhm)
R2=4.7 #Base resistance2 (KOhm)
VBE=0.7 #Base-emitter voltage drop(V)
RL=6.8 #Load Resistance(KOhm)
VG=1 #Input voltage(mV)
RG=0.6 #internal resistance of source(KOhm)
B=150 #current gain
VBB=VCC/2.0 #Base voltage(V)
VE=VBB-VBE #Emitter voltage(V)
IE=VE/RE #Emitter current(mA)
re1=(25/IE) #AC resistance(Ohm)
re=RE*RL/(RE+RL) #external ac resistance(KOhm)
Zin_base=(re+(re1/1000))*B #input impedance of base(KOhm)
Zin_stage=((R1**-1)+(R2**-1))**-1 #input impedance of stage(KOhm)
Av=re/(re+(re1/1000)) #Voltage gain of stage
Vin=(Zin_stage/(Zin_stage+RG))*VG #input voltage(V)
Vout=Av*Vin #output voltage(V)
print 'input impedance of stage Zin(base) = ',round(Zin_base,2),'KOhm'
print 'input impedance of stage Zin(stage) = ',Zin_stage,'KOhm'
print 'voltage gain of emitter follower Av = ',round(Av,3)
print 'Output volatge Vout = ',round(Vout,2),'V'
RG=600 #internal resistance of source(KOhm)
B=300 #current gain
Zout=RG/B #Output impedance(KOhm)
print 'Output impedance Zout = ',Zout,'Ohm'
VCC=30 #collector voltage(V)
RE=0.1 #Emitter resistance(KOhm)
R1=10 #Base resistance1 (KOhm)
R2=10 #Base resistance2 (KOhm)
RL=0.1 #Load Resistance(KOhm)
VG=1 #Input voltage(mV)
RG=0.6 #internal resistance of source(KOhm)
B=300 #current gain
VBQ=VCC/2.0 #Base voltage(V)
VEQ=VBQ #Emitter voltage(V), ignore VBE
IEQ=VEQ/RE #Emitter current(mA)
re=(25/IEQ) #AC resistance(Ohm)
Zb=((RG**-1)+(R1**-1)+(R2**-1))**-1 #impedance looking back from base(KOhm)
Z=Zb*1000/B #impedance after current gain (Ohm)
Ze=Z+re #impedance looking back into emitter(Ohm)
Zout=(((RE*1000)**-1)+(Ze**-1))**-1 #Output impedance(Ohm)
print 'Output impedance is Zout = ',round(Zout,2),'Ohm'
VCC=10 #collector voltage(V)
RE=0.68 #Emitter resistance(KOhm)
RC=3.6 #Collector resistance (KOhm)
re=0.18 #Emitter resistance (KOhm)
R1=10 #Base resistance1 (KOhm)
R2=2.2 #Base resistance2 (KOhm)
RG=0.6 #internal resistance of source(KOhm)
VBE=0.7 #Base-emitter voltage drop(V)
RL=0.27 #Load resistance(KOhm)
B=100 #current gain
VBB=(R1*R2/(R1+R2)) #Base voltage(V)
VE=VBB-VBE #Emitter voltage(V)
IE=VE/RE #Emitter current(mA)
re=(25/IE) #AC resistance(Ohm)
Zin=B*RL #input impedance (KOhm)
rc=((RC**-1)+(Zin**-1))**-1 #ac collector resistance(KOhm)
Av=rc/(re/1000) #voltage gain of stage
print 'voltage gain of CE stage Av = ',round(Av,2)
VCC=10 #collector voltage(V)
RE=0.68 #Emitter resistance(KOhm)
RC=3.6 #Collector resistance (KOhm)
re=0.18 #Emitter resistance (KOhm)
R1=10.0 #Base resistance1 (KOhm)
R2=2.2 #Base resistance2 (KOhm)
RG=0.6 #internal resistance of source(KOhm)
VBE=0.7 #Base-emitter voltage drop(V)
RL=0.27 #Load resistance(KOhm)
B=100 #current gain
VBB=10*(R2/(R1+R2)) #Base voltage(V)
VE=VBB-VBE #Emitter voltage(V)
IE=VE/RE #Emitter current(mA)
re=(25/IE) #AC resistance(Ohm)
rc=((RC**-1)+(RL**-1))**-1 #ac collector resistance(KOhm)
Av=rc/(re/1000) #voltage gain of stage
print 'voltage gain of CE stage Av = ',round(Av,2)
VCC=15 #collector voltage(V)
RE=0.06 #Emitter resistance(KOhm)
R1=10.0 #Base resistance1 (KOhm)
R2=20.0 #Base resistance2 (KOhm)
RG=0.6 #internal resistance of source(KOhm)
VBE=0.7 #Base-emitter voltage drop(V)
RL=0.03 #Load resistance(KOhm)
B1=100 #current gain of Q1
B2=100 #current gain of Q2
B=B1*B2 #Overall current gain
VBB=15*(R2/(R1+R2)) #Base voltage(V)
VE=VBB-(2*VBE) #Emitter voltage(V)
IE2=VE/RE #Emitter current(mA)
IB2=IE2/B2 #Base current of Q2(mA)
IE1=IB2 #emiter current of Q1(mA)
IB1=IE1*1000/B1 #base current of Q1(uA)
re=((RE**-1)+(RL**-1))**-1 #ac emitter resistance(KOhm)
Zin_base=B*re #input impedance of Q1(KOhm)
print 'Overall current gain B = ',B
print 'base current of Q1 IB1 = ',round(IB1,2),'uA'
print 'input impedance at base of Q1 Zin(base) = ',Zin_base,'KOhm'
Vin=20 #input voltage (V)
RL=15 #Load resistance(Ohm)
Vz=10 #voltage across zener(V)
B=100 #current gain
Rs=680.0 #series resistor(Ohm)
Vout=Vz-0.7 #Output voltage approx.(V)
Iout=Vout/RL #Load current(A)
IB=Iout*1000/B #base current(mA)
Is=(Vin-Vz)*1000/Rs #current through series resistor(mA)
Iz=Is-IB #zener current(mA)
print 'output voltage Vout = ',Vout,'V'
print 'Zener current Iz = ',round(Iz,2),'mA'
Vin=30 #input voltage (V)
RL=100 #Load resistance(Ohm)
Vz=6.2 #voltage across zener(V)
B=100 #current gain
Rs=680.0 #series resistor(Ohm)
R1=1 #Resistor (KOhm)
R2=2 #Resistor (KOhm)
Vout=(Vz+0.7)*(R1+R2)/R1 #Output voltage approx.(V)
I1=(Vz+0.7)/R1 #Load current(A)
Vout=I1*(R1+R2) #Output voltage(V)
print 'output voltage Vout = ',Vout,'V'
VG=2 #AC input voltage (mV)
Vs=10 #supply volatge(V)
RL=10 #Load resistance(KOhm)
RG=50.0 #source resistor(Ohm)
R1=10 #Resistor (KOhm)
R2=2.2 #Resistor (KOhm)
RC=3.6 #collector resistor (KOhm)
RE=2.2 #emitter resistance(KOhm)
VB=Vs*R2/(R1+R2) #Base voltage(V)
IE=(VB-0.7)*1000/RE #emitter current(uA)
re=(25/IE)*1000 #ac resistance(Ohm)
Zin=1000*((RE**-1)+((re/1000)**-1))**-1 #input impedance(KOhm)
Zout=RC #Output impedance(KOhm)
rc=((RC**-1)+(RL**-1))**-1 #collector resistance(KOhm)
Av=rc*1000/re #voltage gain
Vin=(Zin/(Zin+RG))*VG #input voltage(V)
Vout=Av*Vin #output voltage(mV)
print 'output voltage Vout = ',round(Vout,2),'mVpp'