Chapter 2: Interpretation of Data Sheets and Characteristics of an Op-Amp

Example 2.1_a

In [5]:
#Example 2.1_a
#Determine the Output voltage for open-loop differential amplifier for figure 2_9

#Variable declaration
vin1=5*10**-6    #input voltage in volts
vin2=-7*10**-6   #input voltage in volts
A=200000         #Voltage gain

#Calculation
vo=A*(vin1-vin2) #Output voltage in volts

#Result
print "Output voltage is vo",vo,"Volts"
Output voltage is vo 2.4 Volts

Example 2.1_b

In [6]:
#Example 2.1_b
#Determine the Output voltage for open-loop differential amplifier for figure 2_9

#Variable declaration
vin1=10*10**-3   #input voltage in volts
vin2=20*10**-3   #input voltage in volts
A=200000         #Voltage gain

#Calculation
vo=A*(vin1-vin2) #Output voltage in volts

#Result
print "Output voltage is vo",vo,"Volts"
Output voltage is vo -2000.0 Volts

Example 2.2_a

In [9]:
#Example 2.2_a
#Determine the Output voltage for an inverting amplifier for figure 2_10

#Variable declaration
vin1=20*10**-3   #input voltage in volts
A=200000         #Voltage gain

#Calculation
vo=-A*(vin1)     #Output voltage in volts

#Result
print "Output voltage is vo",vo,"Volts"
Output voltage is vo -4000.0 Volts

Example 2.2_b

In [8]:
#Example 2.2_b
#Determine the Output voltage for an inverting amplifier for figure 2_10

#Variable declaration
vin1=-50*10**-6  #input voltage in volts
A=200000         #Voltage gain

#Calculation
vo=-A*(vin1)     #Output voltage in volts

#Result
print "Output voltage is vo",vo,"Volts"
Output voltage is vo 10.0 Volts