#Given
m = 100.0 #Differential Gain
E1 = 10*10**-3
E2 = 10*10**-3 #input voltages
E3 = 0*10**-3
E4 = -20*10**-3 #input voltages
#Calculation
Vout1 = (m*E1)-(m*E2)
Vout2 = (m*E1)-(m*E3)
Vout3 = (m*E1)-(m*E4)
#Result
print" Output Voltages are ", Vout1,"V, ",Vout2,"V ,",Vout3,"V"
#Given
V=5 #V
d=2 #mV
E1=V+d*10**-3
E2=V-d*10**-3
#Calculation
Eds=E1-E2
Ecm=(E1+E2)/2.0
#Result
print"Input signal voltage is",Eds*1000,"mV"
print"Common mode voltage is",Ecm,"V"
#Given
a = 2/9.0 #Differential Gain
E1 = 10*10**-3
E2 = 5*10**-3 #Input Voltages
#Calculation
Vout = (E1 - E2)*(1+(2/a))
#Result
print" output voltage = ", Vout*1000,"mV"
#Given
R = 25*10**3
aR = 50.0
#Calculation
a = aR / R
Gain = 1 + (2/a)
#Result
print"Voltage Gain = " , Gain
#Given
import numpy
a=numpy.inf
#Calculation
Gain = 1+(2/a)
#Result
print" Voltage Gain = ", Gain
#Given
m = 1001.0 #Gain
E1 = 5.001
E2 = 5.002
E3 = 5.001
E4 = 5.000
E5 = -1.001
E6 = -1.002
#Calculation
Vout1 = m*(E1-E2)
Vout2 = m*(E3-E4)
Vout3 = m*(E5-E6)
#result
print" Output Voltages are ", Vout1,"V ",Vout2,"V ",Vout3,"V"
#Given
Vout = 5.0 #Output Voltage
#Calculation
Vce = Vout
#Result
print" Vce=",Vce,"V"
#Given
Vre = 1.2
Re = 1*10**3
Vce = 5
Vcc = 15 #Voltages in the circuit
#Calculation
Ie = Vre / Re
Vcol = Vce + Vre
Vrl = Vcc - Vcol
#Result
print" Collector Voltage = ", Vcol,"V"
print" Voltage across Rl =", Vrl,"V"
#Given
Rs = 1*10**3
E1 = 100*10**-3
E2 = 0
Rl = 5*10**3
Gain = 10
#Calculation
Il = 10*((E1-E2)/Rs)
Vr = Il * Rs
Vref = Il * Rl
V9 = Vref + Gain*(E1 - E2)
#Result
print" Current across Load Resistor = ", Il*1000 ,"mA"
print" Voltage across R = ", Vr,"V"
print" Reference Voltage = ", Vref,"V"
print" Voltage at terminal 9 =", V9,"V"
#Given
GF = 2.0 #Gage factor
DR = 0.001
R = 120.0
#calculation
L = DR /(R*GF)
#result
print" Change in length is ",round(L*10**6,1),"microinches per inch"
#Given
E = 1.0
DR = 0.001
R = 120.0 #Resistance in Ohm
#Calculation
Vout = (E*DR)/(4*R)
#Result
print" Output of the Bridge = ", round(Vout*10**6,1),"micro voltage"
#Given
Vout = 100*10**-3
E = 5.0
R = 120.0
Gain = 1000.0
E1 = 30 *10**6
Gf = 2.0 #Gage factor
#calculation
Vbridge = Vout / Gain
DL = 20*10**-6
DR = (R * Vbridge)/E
Rratio = DR / R #Change in Resistance
Strain = DL / Gf #Change in Length
Stress = E1 * Strain
#Result
print " Change in Resistance = ", DR*1000 ,"mohm"
print " Ratio of Resistance = ", Rratio,"micro ohm/ohm"
print " Strain value = ", Strain ,"micro inch/inch"
print " Stress value = ", Stress ,"psi"
#Given
T1=25 #C Temprature
T2=50
Tref=25 #C Reference temprature
Rref=10000
Rtrans=3603 #ohm, at 50 C
#Calculation
dR=Rtrans-Rref
R1=10 #Kohm say
E=1 #V trial choice
I=E/(R1+Rref/1000.0)
Vo=-I*dR
#result
print"The value of dR for each temprature is",dR,"ohm"
print"The current is",I,"mA"
print"Vo for each value of R",Vo,"mV"
#NOTE: In the book the value of Vo is calculated wrong