Basic Op Amp Model
Basic Op Amp Model
CIRCUIT
OPMODEL1.CIR Download the SPICE file
One of the challenges of simulating opamp circuits is modeling the op amp itself. How is that accomplished? There's a couple of ways. You can create a circuit of many transistors, resistors and caps that closely replicate the internals of an op amp. Or, you can create a simpler model that reproduces the basic behavior of the op amp. The benefit of the simpler model is one that uses less components and typically simulates faster. As you begin to look at more complex or subtle behaviors, you can create a more complex op amp model.
To simulate more complex behaviors, check out the Intermediate Op Amp Model. For a description of all available op amp models, see Op Amp Models.
OP AMP MODEL
What are the three basic stages of an op amp? The circuit above shows 1) a differential amplifier, 2) a voltage gain stage with single-pole frequency roll-off and 3) an output buffer. (As a convenience, we'll define this model as a subcircuit. See Why Use Subcircuits?)
The subcircuit models the following behaviors:
Input impedance RIN
Differential Gain EGAIN
Single Pole Frequency RP1, CP1
Output Impedance ROUT
If you're designing a precision amplifier, you can see how gain and input / output resistance effect accuracy. If your designing a high-speed amplifier, you can determine your circuit's bandwidth. You can also see how stray and load capacitances may cause your amplifier to ring or oscillate.
OPEN-LOOP FREQUENCY RESPONSE
The open-loop response gives you some powerful insight into the op amp’s performance. Open-loop means NO feedback; the response of the “naked” op amp. Two important features are
1. DC Gain – the gain at DC. ( The more you have, the more accurate your amplifier. )
2. First-Pole Frequency, fp1 – the frequency where the open-loop begins to fall. A direct result of fp1 and the DC Gain is the Unity-Gain Frequency, fu – the frequency where the open-loop gain falls to 1 V/V. The greater the fu, the faster your op amp can respond.
CIRCUIT INSIGHT The op amp is driven by AC source VS. There are no feedback resistors here – its running open-loop. Try out the model by running a simulation and plotting the AC magnitude VM(3). Can you see the DC gain = 100k V/V and the first-pole at fp1 = 100 Hz? What is the unity gain frequency? Try changing the Y-Axis to a log scale to get a better view at high frequencies. If your plotting in dB, the unity-gain level is 0 dB.
You might ask, what if I don’t need a gain of 100k V/V? Op amps are actually intended for lower gains set by feedback resistors connected around the device (Closed-Loop Gain). The higher the internal gain (like 100k V/V and above) the more accurate your lower Closed-Loop Gain will be (set by the feedback resistors only.)
UNITY-GAIN FREQUENCY
As stated before, the greater the unity-gain frequency, the faster your op amp can respond. What determines the this frequency? It’s set by the DC Gain and fp1.
where the pole frequency is formed by a simple RC filer
HANDS-ON DESIGN Suppose you need to model an op amp with the same DC gain but a higher unity-gain frequency fu. Simply solve for a new fp1 in the 1st equation. Then, calculate the new CP1 from the 2nd equation to achieve that desired fp1. For example,
Choose a new fu, such as 50 MHz.
Then, calculate fp1 = fu / DCGAIN = 50 MHz / 100 k = 500 Hz
CP1 = 1/( 2 * π * 1k * 500 Hz) = 0.318 uF.
Try out your new op amp model. Did the magnitude VM(3) hit the unity-gain where you expected?
PHASE SHIFT
CIRCUIT INSIGHT So far we’ve looked at the gain / attenuation of the input signal by the op amp. At some point, you may need to know the phase shift (time shift) as well. To check out the phase shift, add another plot to the window, then, add trace VP(3) where the P tells SPICE to display the Phase. A maximum of -90 degrees of phase shift should occur beyond the first pole fp1.
What’s the big deal about phase anyway? Turns out, the phase shift (and gain) of the signal in a feedback circuit reveals how well a circuit performs. Too much negative phase can cause an amplifier circuit to overshoot, ring or even oscillate. Knowing the phase shift will help you fix the problem. On the other hand, if you’re designing an oscillator, you’ll need to know how to add the right amount of phase at the right frequency. More on these topics in Op Amp Feedback Analysis.
OP AMP CIRCUITS
This op amp model is used for the innards of many op amp circuits in this site: Inverting Amplifier, Non-Inverting Amplifier, etc. Go ahead and turbo-charge some of the op amps by upping the Unity-Gain Frequency of the model and checking out its effect on the closed-loop bandwidth (with feedback components) of the amplifier.
SIMULATION NOTE
The op amp model is created from several simple SPICE devices. The differential input and DCGAIN stage are implemented by a Voltage-Controlled Voltage Source (VCVS) named EGAIN. The device
EGAIN 3 0 1 2 100K
follows the syntax
E{name} {+output} {-output} {+control} {-control} {gain}
which creates a voltage source having positive and negative output terminals at nodes 3 and 0. The source is controlled by the voltage at positive and negative sense leads 1 and 2. This voltage is then multiplied by the gain 100k and applied at the output terminals. The output buffer EBUFFER is simply another VCVS.
SPICE makes three other controlled sources available: a Current-Controlled Voltage Source (CCVS), a Voltage-Controlled Current Source (VCCS) and Current-Controlled Current Source (CCCS). Check them out at the SPICE Command Summary.
RELATED TOPICS
To simulate more complex behaviors, check out the Intermediate Op Amp Model.
See a description of all available op amps at Op Amp Models.
For a quick review of subcircuits, check out Why Use Subcircuits?
Get a crash course on SPICE simulation at SPICE Basics.
To see how open-loop gain and bandwidth influence closed-loop bandwidth, see Op Amp Bandwidth.
This op amp model can be used many of the op amp circuits available from the Circuit Collection page.
SPICE FILE
Download the file or copy this netlist into a text file with the *.cir extention.
OPMODEL1.CIR - OPAMP MODEL SINGLE-POLE
*
VS 1 0 AC 1
XOP 1 0 3 OPAMP1
RL 3 0 1K
*
* OPAMP MACRO MODEL, SINGLE-POLE
* connections: non-inverting input
* | inverting input
* | | output
* | | |
.SUBCKT OPAMP1 1 2 6
* INPUT IMPEDANCE
RIN 1 2 10MEG
* DC GAIN=100K AND POLE1=100HZ
* UNITY GAIN = DCGAIN X POLE1 = 10MHZ
EGAIN 3 0 1 2 100K
RP1 3 4 1K
CP1 4 0 1.5915UF
* OUTPUT BUFFER AND RESISTANCE
EBUFFER 5 0 4 0 1
ROUT 5 6 10
.ENDS
*
* ANALYSIS
.AC DEC 5 1 100MEG
* VIEW RESULTS
.PLOT AC VM(3)
.PROBE
.END
Seja o primeiro a comentar
Post a Comment