from __future__ import division
Vcc=10#
Rc=10*10**3#
Rb=1*10**6#
beta=100#
Vbe=0.7#
Ib=(Vcc-Vbe)/Rb#
print 'Ib=%0.2f microA'%(Ib*10**6)
Ic=beta*Ib#
print 'Ic=%0.2f mA'%(Ic*10**3)
Ie=Ic#
re=25/(Ie*10**3)
print 're=%0.2f ohm'%re
Ri=beta*re#
print 'Ri=%0.2f kohm'%(Ri*10**-3)
Ris=(Rb*beta*re)/(Rb+beta*re)
print 'Ris=%0.2f kohm'%(Ris*10**-3)
R0=Rc#
print 'R0=%0.2f kOhm'%(R0*10**-3)
Av=Rc/re#
print "Av=%0.2f"%Av
from __future__ import division
from math import log10
Ri=2.5*10**3#
Av=200#
Vs=5*10**-3#
beta=50#
ib=(Vs/Ri)
print 'ib=%0.2f microA'%(ib*10**6)
ic=beta*ib#
print 'ic=%0.2f microA'%(ic*10**6)
Ai=beta#
Ap=Ai*Av#
print "Ap=%0.2f"%Ap
Gp=10*log10(Ap)
print 'Gp=%0.2f dB'%Gp
from __future__ import division
from math import log10
Vcc=20#
Rc=5*10**3#
Re=1*10**3#
Rb=100*10**3#
beta=150#
Vbe=0.7
Ic=Vcc/(Re+(Rb/beta))
print 'Ic=%0.2f mA'%(Ic*10**3)
Ie=Ic#
re=25/(Ie*10**3)
print 're=%0.2f ohm'%re
Ri=beta*(re+Re)
print 'Ri=%0.2f kohm'%(Ri*10**-3)
Ris=(Rb*Ri)/(Rb+Ri)
print 'rIS=%0.2f kohm'%(Ris*10**-3)
Av=Rc/Re#
print "Av=%0.2f"%Av
Gp=10*log10(Av)
print 'Gp=%0.2f dB'%Gp
from __future__ import division
Vcc=12#
Rc=10*10**3#
Re=1*10**3#
Rb=500*10**3#
beta=50#
Ic=Vcc/(Re+(Rb/beta))
print 'Ic=%0.2f mA'%(Ic*10**3)
Ie=Ic#
re=25/(Ie*10**3)
print 're=%0.2f ohm'%re
Ri=beta*re#
print 'Ri=%0.2f ohm'%Ri
Ris=(Rb*Ri)/(Rb+Ri)
print 'Ris=%0.2f ohm'%Ris
R0=Rc#
Av=R0/re#
print "Av=%0.2f"%Av
Av=Rc/Re#
print "Av=%0.2f"%Av
from __future__ import division
Vcc=30#
Rc=10*10**3#
RL=3.3*10**3#
R1=47*10**3#
R2=15*10**3#
Re=8.2*10**3#
beta=200#
Vs=5*10**-3#
Vbe=0.7#
Vth=(Vcc*R2)/(R1+R2)
print 'Vth=%0.2f V'%Vth
Rth=(R1*R2)/(R1+R2)
print 'Rth=%0.2e ohm'%Rth
Ie=(Vth-Vbe)/(Re+(Rth/beta))
print 'IE=%0.2f mA'%(Ie*10**3)
re=25/(Ie*10**3)
print 're=%0.2f ohm'%re
rl=(Rc*RL)/(Rc+RL)
print 'rl=%0.2f kohm'%(rl*10**-3)
Av=rl/re#
print "Av=%0.2f "%Av
Vin=5#
V0=Av*Vin
print 'V0=%0.2f mV'%V0
Ri=beta*re#
print 'Ri=%0.2f kohm'%(Ri*10**-3)
Ris=(Rth*Ri)/(Rth+Ri)
print 'Ris=%0.2f kohm'%(Ris*10**-3)
from __future__ import division
Vcc=10#
Rc=5*10**3#
Re=1*10**3#0
RL=50*10**3#
R1=50*10**3#
R2=10*10**3#
Rs=600#
beta=50#
Vs=10*10**-3#
Vbe=0.7#
Vth=(Vcc*R2)/(R1+R2)
print 'Vth=%0.2f V'%Vth
Rth=(R1*R2)/(R1+R2)
print 'Rth=%0.2e ohm'%Rth
Ie=(Vth-Vbe)/(Re+(Rth/beta))
print 'IE=%0.2f mA'%(Ie*10**3)
re=25/(Ie*10**3)
print 're=%0.2f ohm'%re
Ri=beta*re#
Ris=(Rth*Ri)/(Rth+Ri)
print 'Ris=%0.2f ohm'%Ris
rl=(Rc*RL)/(Rc+RL)
print 'rl=%0.2f kohm'%(rl*10**-3)
Av=rl/re#
print "Av=%0.2f"%Av
Vin=(Vs*Ris)/(Ris+Rs)
print 'Vin=%0.2f mV'%(Vin*10**3)
V0=Av*Vin#
print 'V0=%0.2f mV'%V0
Avs=(Av*Vin)/Vs#
print "Avs=%0.2f"%Avs
from __future__ import division
Vcc=-18#
Rc=4.3*10**3#
Re=1*10**3#0
RL=3*10**3#
R1=39*10**3#
R2=8.2*10**3#
beta1=200#
Vbe=-0.7#
Vth=(Vcc*R2)/(R1+R2)
print 'Vth=%0.2f V'%Vth
Rth=(R1*R2)/(R1+R2)
print 'Rth=%0.2f kohm'%(Rth*10**-3)
Ie=(Vth-Vbe)/(Re+(Rth/beta1))
print 'IE=%0.2f mA'%(Ie*10**3)
re1=(30*10**-3)/(-Ie)
print 're1=%0.2f ohm'%re1
Ri=beta1*re#
Ris=(Rth*Ri)/(Rth+Ri)
print 'Ris=%0.2f kohm'%(Ris*10**-3)
re=(Rc*RL)/(Rc+RL)
print 're=%0.2f kohm'%(re*10**-3)
Av=re/re1#
print "Av=%0.2f"%Av
from __future__ import division
Vcc=20#
Rc=5.7*10**3#
Re=1*10**3#
R1=100*10**3#
R2=10*10**3#
Rs=100#
beta1=100#
Vbe=0.7#
Vth=(Vcc*R2)/(R1+R2)
print 'Vth=%0.2f V'%Vth
Rth=(R1*R2)/(R1+R2)
print 'Rth=%0.2f kohm'%(Rth*10**-3)
Ie=(Vth-Vbe)/(Re+(Rth/beta1))
print 'IE=%0.2f mA'%(Ie*10**3)
re=25/(Ie*10**3)
print 're=%0.2f ohm'%re
Ri=beta1*re#
Ris=(Rth*Ri)/(Rth+Ri)
print 'Ris=%0.2f ohm'%Ris
rl=Rc#
Av=rl/re#
print "Av=%0.2f"%Av
Vin=(Vs*Ris)/(Ris+Rs)
print 'Vin=%0.2f mV'%Vin
V0=Av*Vin#
print 'V0=%0.2f V'%(V0*10**-3)
Avs=(Av*Vin)/Vs#
print "Avs=%0.2f"%Avs
from __future__ import division
Vcc=10#
Rc=5*10**3#
RE1=500#
R1=50*10**3#
R2=10*10**3#
Rs=600#
rE=500#
beta1=50#
Vbe=0.7#
vs=100*10**-3#
Rl=50*10**3#
Vth=(Vcc*R2)/(R1+R2)
print 'Vth=%0.2f V'%Vth
Rth=(R1*R2)/(R1+R2)
print 'Rth=%0.2e ohm'%(Rth*10**-3)
RE=RE1+rE#
print 'RE=%0.2f ohm'%RE
Ie=(Vth-Vbe)/(RE+(Rth/beta1))
print 'Ie=%0.2f mA'%(Ie*10**3)
re=25/(Ie*10**3)
print 're=%0.2f ohm'%re
Ri=beta1*(re+rE)
print 'Ri=%0.2f kohm'%(Ri*10**-3)
Ris=(Rth*Ri)/(Rth+Ri)
print 'Ris=%0.2f ohm'%Ris
rl=(Rc*Rl)/(Rc+Rl)
print 'rl=%0.2f kohm'%(rl*10**-3)
Av=rl/(re+rE)
print "Av=%0.2f "%Av
VinBYVs=(Ris)/(Ris+Rs)
print "VinBYVs=%0.2f"%VinBYVs
Avs=Av*VinBYVs#
print "Avs=%0.2f"%Avs
V0=Avs*vs#
print 'V0=%0.2f mV'%(V0*10**3) #answer printed in the book is wrong(variation in decimal point)
from __future__ import division
from math import log10
VS=10*10**-3#
a=0.98#
VBE=0.7#
VCC=10#
RC=10*10**3#
RL=5.1*10**3#
RE=20*10**3#
VEE=10#
IE=(VEE-VBE)/RE#
re=25/IE*10**-3#
Ri=re#
Ris=(RE*re)/(RE+re)
print 'Ris=%0.2f ohm'%Ris
Ai=a#
print "Ai=%0.2f"%Ai
rL=(RC*RL)/(RC+RL)
Av=rL/re#
print "Av=%0.2f"%Av
Ap=Av*Ai#
print "Ap=%0.2f"%Ap
Gp=10*log10(Ap)
print 'Gp=%0.2f dB'%Gp
Vin=VS#
Vo=Av*Vin#
print 'Vo=%0.2f mV'%(Vo*10**3)
from __future__ import division
Rs=50#
IE=0.465*10**-3#
re1=53.8#
Ri=53.8#
Ris=52.4#
rL=3.38*10**3#
Avs=rL/(Rs+re1)
print "Avs=%0.2f"%Avs
Av=rL/re1#
print "Av=%0.2f"%Av
Vs=10#
vo=Avs*Vs#
vin=vo/Av#
print 'vin=%0.2f mV'%vin
from __future__ import division
VEE=10#
RE=10*10**3#
RB=100*10**3#
B=50#
VBE=0.7#
IE=(VEE-VBE)/(RE+(RB/B))
re=25/IE*10**-3#
Ri=B*(RE+re)
print 'Ri=%0.2f kohm'%(Ri*10**-3)
Ris=(RB*Ri)/(RB+Ri)
Rs=0#
Ro=re+((RB*Rs)/(RB+Rs))/B#
print 'Ro=%0.2f ohm'%Ro
Av=RE/(re+RE)
print "Av=%0.2f "%Av
from __future__ import division
B=80#
VBE=0.7#
VCC=15#
R1=20*10**3#
R2=20*10**3#
RS=2*10**3#
VS=5*10**-3#
RE=8.2*10**3#
RL=1.5*10**3#
VTH=VCC*R2/(R1+R2)
RTH=(R1*R2)/(R1+R2)
IE=(VTH-VBE)/(RE+(RTH/B))
print 'IE=%0.2f mA'%(IE*10**3)
re=25/IE*10**-3#
rL=(RE*RL)/(RE+RL)
Ri=B*(rL+re)
Ris=(RTH*Ri)/(RTH+Ri)
print 'Ris=%0.2f kohm'%(Ris*10**-3)
Ro=re+((RS*RTH)/(RS+RTH))/B#
print 'Ro=%0.2f ohm'%Ro
Vin=VS*Ris/(RS+Ris)
print 'Vin=%0.2f mV'%(Vin*10**3)