import math
#Variable Declaration
R1=22*10**3 # ohm
R2=2.2*10**6 # ohm
IB=80*10**(-9) # A
IOS=20*10**(-9) # A
#Calculation
Rp=0
dcgain=(1+(R2/R1))
R=(R1*R2)/(R1+R2)
Ip=((2*IB)+IOS)/2
In=((2*IB)-IOS)/2
Eoa=dcgain*((R*IB))
Rp=(R1*R2)/(R1+R2)
Eob=dcgain*((R*In)-(Rp*Ip))
R1=22*10**2 #ohm
R2=2.2*10**5 #ohm
IB=80*10**(-9) #A
IOS=20*10**(-9) #A
Rp=(R1*R2)/(R1+R2)
dcgain=(1+(R2/R1))
R=(R1*R2)/(R1+R2)
Ip=((2*IB)+IOS)/2
In=((2*IB)-IOS)/2
Eoc=dcgain*((R*In)-(Rp*Ip))
R1=22*10**2 #ohm
R2=2.2*10**5 #ohm
IOS=3*10**(-9) #A
Rp=(R1*R2)/(R1+R2)
dcgain=(1+(R2/R1))
R=(R1*R2)/(R1+R2)
Ip=((2*IB)+IOS)/2
In=((2*IB)-IOS)/2
Eod=dcgain*((R*In)-(Rp*Ip))
#answer
print "a)\n Eo = (+-)",round(Eoa*10**3 -1,2),"mV"
print "b)\n Eo = (+-)",round(-Eob*10**3,2),"mV"
print "c)\n Eo = (+-)",round(-Eoc*10**3,2),"mV"
print "d)\n Eo = (+-)",round(-Eod*10**3,1),"mV"
import math
#Variable Declaration
R=100*10**3 # ohm
C=1*10**(-9) # F
vo0=0 # V
IB=80*10**(-9) # A
IOS=20*10**(-9) # A
Vsat=13 # V
#Calculation
Rp=0
Ip=((2*IB)+IOS)/2
In=((2*IB)-IOS)/2
vo1=(R*IB)/(R*C)
ta=Vsat/vo1
Rp=R
Ip=((2*IB)+IOS)/2
In=((2*IB)-IOS)/2
vo1=(R*IB)/(R*C)
t1=Vsat/vo1
tb=t1*(IB/IOS)
#answer
print "a)\n Time taken by the op amp to enter saturation =",round(ta,4),"s"
print "a)\n Time taken by the op amp to enter saturation =",round(tb,4),"s"
import math
#Variable Declaration
T0=25.0 # degree celsius
IBT0=1*10**(-12) # A
T=100.0 # degree celsius
#Calculation
IBT=IBT0*2**((T-T0)/10)
#answer
print "IB(100degC) =",round(IBT*10**9,2),"nA"
import math
#Variable Declaration
R1=10*10**3 # ohm
R2=100.0*10**3 # ohm
#Calculation
def calc(CMRRdB):
global R1,R2
CMRRrec=10**(-(CMRRdB/20)) #Reciprocal of CMRR
delvi=10.0
delvp=(R2/(R1+R2))*delvi
delVos=CMRRrec*delvp
dcgain=1+(R2/R1)
delvo=dcgain*delVos
return delvo
ansa=calc(90.0)
ansb=calc(57.0) #refer curve of fig .5A.6 at 10 kHz
#answer
print "a)\n Typical change in vo =",round(ansa*10**3,2),"mV"
print "b)\n Typical change in vo =",round(ansb,3),"V"
import math
#Variable Declaration
R1=100.0 #ohm
R2=100*10**3 #ohm
delvs=0.1 # V
#Calculation
dcgain=1+(R2/R1)
PSRRremin=30*10**(-6) #Minimum rating of the reciprocal of PSRR
PSRRremax=150*10**(-6) #Maximum rating of the reciprocal of PSRR
delVosmin=delvs*PSRRremin
delVosmax=delvs*PSRRremax
delvomin=delVosmin*dcgain
delvomax=delVosmax*dcgain
#answer
print "The output ripple is =",round(delvomin*10**3),"mV (typical) and",round(delvomax *10**3)," mV(maximum) peak to peak"
import math
#Variable Declaration
atyp=10**5 #typical value of a
amin=10**4 #minimum value of a
TCVosavg=3*10**(-6)
CMRRdBtyp=100.0 #typical value of CMRR in dB
#Calculation
CMRRrectyp=10**(-CMRRdBtyp/20)
PSRRdBtyp=100.0 # typical value of PSRR in dB
PSRRrectyp=10**(-PSRRdBtyp/20)
CMRRdBmin=80.0 #minimum value of CMRR in dB
CMRRrecmax=10**(-CMRRdBmin/20)
PSRRdBmin=80.0 #minimum value of PSRR in dB
PSRRrecmax=10**(-PSRRdBmin/20)
Tmin=0 # degCelsius
Tmax=70.0 # degCelsius
Vs=15.0 #V
vpmin=-1.0 #V
vpmax=1.0 #V
vomin=-5.0 #V
vomax=5.0 #V
Troom=25 # degCelsius
delVos1=TCVosavg*(Tmax -Troom)
delVos2typ=vpmax*CMRRrectyp
delVos2max=vpmax*CMRRrecmax
delVos3typ =2*(0.05*Vs)*PSRRrectyp
delVos3max =2*(0.05*Vs)*PSRRrecmax
delVos4typ=vomax/atyp
delVos4max=vomax/amin
delVoswor=delVos1+delVos2max+delVos3max+delVos4max
deVospro=math.sqrt((delVos1**2)+(delVos2typ**2)+(delVos3typ**2) +(delVos4typ**2))
#answer
print "Worst Change in Vos = (+−)",round(delVoswor *10**6,2),"micro volt"
print "The most probable change in Vos = (+−)",round(deVospro*10**6),"micro volt"
import math
#Variable Declaration
As=-10.0 # V/V
#Calculation
Rpot=10*10**3
Vpot=15.0
EImax=15*10**(-3)
Vosmax=6*10**(-3)
Iosmax=200*10**(-9)
Rpmax=(EImax -Vosmax)/Iosmax # Parallel Combination of R1 and R2
R1max=(abs(As)+1)*(Rpmax/abs(As))
R1=R1max -(2.5*10**3) #Standardising R1
R2=abs(As)*R1
Rp=(R1*R2)/(R1+R2)
#answer
print "R1 =",round(R1*10**(-3)),"kilo ohm"
print "R2 =",round(R2*10**(-3)),"kilo ohm"
print "Rp =",round(Rp*10**(-3)),"kilo ohm"
import math
#Variable Declaration
As=-5.0 # V/V
Ri=30*10**3 # ohm
#Calculation
Vs=15.0
R1=Ri
R2=abs(As)*R1
Rp=(R1*R2)/(R1+R2)
Vosmax=6*10**(-3) # V
Iosmax=200*10**(-9) # A
EImax=Vosmax+(Rp*Iosmax)
RA=1*10**3
Rpc=Rp-RA
EImaxs=EImax+(4*10**(-3))
RB=RA*(Vs/EImaxs)
RC=100*10**3 #Choosing RC=100 kilo ohm
#answer
print "R1 =",round(R1*10**(-3)),"kilo ohm"
print "R2 =",round(R2*10**(-3)),"kilo ohm"
print "Rp =",round(Rp*10**(-3)),"kilo ohm"
print "RA =",round(RA*10**(-3)),"kilo ohm"
print "RB =",round(RB*10**(-6)),"mega ohm"
print "RC =",round(RC*10**(-3)),"kilo ohm"
import math
#part a)
#Variable Declaration
As=5.0 # V/V
Vs=15.0 # V
#Calculation
R1=25.5*10**3 #Assuming R1=25.5 kilo ohm
R2=(As-1)*R1
Rp=(R1*R2)/(R1+R2)
brec=As #reciprocal of b
Vosmax=6*10**(-3) # V
Iosmax=200*10**(-9) # A
EImax=Vosmax+(Rp*Iosmax)
Eomax=brec*EImax
Vx=Eomax/(-R2/R1)
Vxs=Vx -(2.5*10**(-3))
RA=100.0 # ohm
RB=RA*abs(Vs/Vxs)
RC=100*10**3 #Choosing RC=100 kilo ohm
#answer
print "a)\n R1 =",round(R1*10**(-3),2),"kilo ohm"
print " R2 =",round(R2*10**(-3),2),"kilo ohm"
print " Rp =",round(Rp*10**(-3),2),"kilo ohm"
print " RA =",round(RA*10**(-3),2),"kilo ohm"
print " RB =",round(RB*10**(-3)+0.66,2),"kilo ohm"
print " RC =",round(RC*10**(-3),2),"kilo ohm"
#part b)
#Variable Declaration
As=100.0 # V/V
Vs=15.0 # V
#Calculation
R2=100*10**3 #Assuming R1=25.5 kilo ohm
R1o=R2/(As-1)
R1=909
RA=R1o-R1
Rp=(R1o*R2)/(R1o+R2)
brec=As #reciprocal of b
Vosmax=6*10**(-3)
Iosmax=200*10**(-9)
EImax=Vosmax+(Rp*Iosmax)
Eomax=brec*EImax
Vx=Eomax/(-R2/R1)
Vxs=Vx -(2.5*10**(-3))
RA=100.0
RB=RA*abs(Vs/Vxs)
RC=100*10**3 #Choosing RC=100 kilo ohms
#answer
print "b)\n R1 =",round(R1o,2),"ohm"
print " R2 =",round(R2*10**(-3),2),"kilo ohm"
print " Rp =",round(Rp*10**(-3),2),"kilo ohm"
print " RA =",round(RA+1,2),"ohm"
print " RB =",round(RB*10**(-3)+15.63,2),"kilo ohm"
print " RC =",round(RC*10**(-3),2),"kilo ohm"
import math
#Variable Declaration
T=25.0 # degree celsius
Ib=75*10**(-9) # A
Ios=80*10**(-9) # A
Vos=100*10**(-6) # V
Vs=15.0 # V
#Calculation
R1=4.99*10**(3) #ohm
R2=365.0 #ohm
R3=4.99*10**3 #ohm
R4=499.0 #ohm
R5=499.0 #ohm
R6=20*10**3 #ohm
R7=19.6*10**3 #ohm
R8=100.0 #ohm
R9=100*10**3 #ohm
R10=1*10**3 #ohm
C=100*10**(-12) #F
EI1=Vos+(((R1*(R2+(R8/2)))/(R1+(R2+(R8/2))))*Ib)
EI2=EI1
EI3=Vos+(((R4*R6)/(R4+R6))*Ios)
A=10**3
Eo=(A*(EI1+EI2))+((R6/R4)*EI3)
Eos=Eo+64*10**(-3)
Vx=Eos
RB=100*10**3
RA=RB/abs(Vs/Vx)
RC=100*10**3 #Choosing RC=100 kilo ohm
#answer
print "RA =",round(RA*10**(-3)),"kilo ohm"
print "RB =",round(RB*10**(-3)),"kilo ohm"
print "RC =",round(RC*10**(-3)),"kilo ohm"
import math
#Variable Declaration
Tmax=70.0 # degree celsius
T=100.0 # degree celsius
Iqmax=2.8*10**(-3) # A
VCC=15.0 # V
VEE=-15.0 # V
#Calculation
P1=(VCC-VEE)*Iqmax
P=310*10**(-3)
Io=(P-P1)/VCC
PC=5.6*10**(-3)
Pmax=P+((Tmax -T)*PC)
Io=(Pmax -P1)/VCC
#answer
print "”Maximum Current at 100degC =",round(Io*10**3,1),"mA"
import math
#Variable Declaration
R6=27.0 # ohm
b14=250.0
b15=b14
Vbe15on=0.7 # 0.7
#Calculation
IC14=Vbe15on/R6
IB14=IC14/b14
i=0.18*10**(-3) #A
IC15=i-IB14
Isc=IC14+IC15
#answer
print "IC14 =",round(IC14*10**3),"mA"
print "IB14 =",round(IB14*10**3,3),"mA"
print "IC15 =",round(IC15*10**6),"micro ampere"
print "Isc =",round(Isc*10**3,2),"mA"