Op-Amp Simulation Measurements

Thread Starter

stinkimy

Joined Apr 9, 2021
8
I'm learning from home about Op-Amps but I've got stuck trying to simulate a circuit and get readings.

So far I've put meters in to measure the currents at the inputs and I want to check that I'm right in thinking that (Ib+) - (Ib-) = Input offset current

The figures displayed are from a DC Analysis, I'm not sure why 1mV is the output and input? I understand it's a unity gain amplifier but I thought that would be how I measure the input offset voltage?

(The VIN is 1V @ 1MHz)
1626805914531.png



This is my transient analysis, if I measure the peak-to-peak of the Vout will the rise over run be the slew rate? I understand it's v/s it's the rate of change of the output right?

1626807122123.png

I don't know if this is a stupid question, but is it possible to measure the open-loop voltage gain when it's a closed loop?

I'd like to have a go at simulating properly and then see if I can breadboard them and take some measurements but it's all new to me and I don't have a class for support. Any useful resources or pointers would be gratefully received. Thank you.
 

Papabravo

Joined Feb 24, 2006
17,316
Why would you ever need to know the open loop gain. In practice it assumed sufficiently large so that the actual value just doesn't matter.
 

crutschow

Joined Mar 14, 2008
28,227
It would seem the model for the ancient 741 you are using has an offset voltage of 1mV which you are measuring.

It's similar to the model I have. Below is the LTspice simulation:
It shows +1mV of offset at the output.

1626815593587.png
 

Thread Starter

stinkimy

Joined Apr 9, 2021
8
Why would you ever need to know the open loop gain. In practice it assumed sufficiently large so that the actual value just doesn't matter.
That's why I don't understand how to measure it. The question asks to me to find the open-loop gain at 1MHz.
 

Thread Starter

stinkimy

Joined Apr 9, 2021
8
To make the offset easier to measure with a real circuit, you can amplify the value
Below is the value for a non-inverting gain of 101:
Brilliant thank you, I will give that a try.

I'm studying from home and that was the OpAmp they gave in the question. The workbook they provided gives no practical examples about measuring any of these and don't even mention input offset current/voltage.
 

Ian0

Joined Aug 7, 2020
3,785
Why would you ever need to know the open loop gain. In practice it assumed sufficiently large so that the actual value just doesn't matter.
It might be at DC, but the compensation brings it down at 6dB/octave starting, in some cases, at <100Hz. For something like a TL071 it's only about 300 at 20kHz.
 

Thread Starter

stinkimy

Joined Apr 9, 2021
8
It might be at DC, but the compensation brings it down at 6dB/octave starting, in some cases, at <100Hz. For something like a TL071 it's only about 300 at 20kHz.
Just watched a video where the guy set the AV and VOS as a parameter of the OpAmp and simulates it so will try and figure out how to do that.
 

crutschow

Joined Mar 14, 2008
28,227
Below is a simple way to measure an op amp's open-loop gain in simulation.
R1 provides DC feedback to stabilize the bias, while C1 decouples it so there is no AC feedback at the frequencies of interest.
A more complicated circuit is needed for a real measurement due to the large capacitor value required for this circuit.

1626874224217.png
 

Papabravo

Joined Feb 24, 2006
17,316
That would make a dandy low frequency relaxation oscillator. With V3 at Ground, I make it 4.55 μHz. or one cycle every 2.55 days. A 741 might even have the bandwidth to make it work.
 

Ian0

Joined Aug 7, 2020
3,785
That circuit doesn’t perform so badly in real life. Use the biggest capacitor that you have lying around, perhaps it’s 4700uF with an ESR of about 1Ω, and a 100k feedback resistor. It’s going to work above about 33Hz.
 

Ian0

Joined Aug 7, 2020
3,785
That would make a dandy low frequency relaxation oscillator. With V3 at Ground, I make it 4.55 μHz. or one cycle every 2.55 days. A 741 might even have the bandwidth to make it work.
Perhaps you could use one of them “super caps”, there will be plenty left over when people on the forum realise they can’t use them as batteries.
 

Papabravo

Joined Feb 24, 2006
17,316
That's why I don't understand how to measure it. The question asks to me to find the open-loop gain at 1MHz.
OK, but why the requirement to do it in a closed loop configuration? Does it really matter what configuration you use as long it provides some insight. Simulation does allow you to do things that would be more difficult in the lab.
 

Thread Starter

stinkimy

Joined Apr 9, 2021
8
OK, but why the requirement to do it in a closed loop configuration? Does it really matter what configuration you use as long it provides some insight. Simulation does allow you to do things that would be more difficult in the lab.
Because the question gives a specific schematic with that closed loop configuration and asks to measure the open-loop voltage gain, slew rate and input offset current/voltage at 1MHz.
 

Thread Starter

stinkimy

Joined Apr 9, 2021
8
Below is a simple way to measure an op amp's open-loop gain in simulation.
R1 provides DC feedback to stabilize the bias, while C1 decouples it so there is no AC feedback at the frequencies of interest.
A more complicated circuit is needed for a real measurement due to the large capacitor value required for this circuit.
Ok thank you, so is it a matter of adding R1 and C1 in order to be able to measure the circuits open-loop, rather than to change the original circuit?
 

Papabravo

Joined Feb 24, 2006
17,316
Ok thank you, so is it a matter of adding R1 and C1 in order to be able to measure the circuits open-loop, rather than to change the original circuit?
It is one way to do it. The symbols in your schematic are not completely obvious, but if the voltage source sweeps from a negative voltage to a positive voltage and you and can measure the slope of the output as it transitions from the negative rail to the positive rail, that will also indicate the open loop gain.
 

Papabravo

Joined Feb 24, 2006
17,316
Here is another example for measuring Offset Voltage from an Analog Devices Application Note MT-037. It also demonstrates the use of the .measure SPICE command.

1626893014768.png
 

MrAl

Joined Jun 17, 2014
8,562
I'm learning from home about Op-Amps but I've got stuck trying to simulate a circuit and get readings.

So far I've put meters in to measure the currents at the inputs and I want to check that I'm right in thinking that (Ib+) - (Ib-) = Input offset current

The figures displayed are from a DC Analysis, I'm not sure why 1mV is the output and input? I understand it's a unity gain amplifier but I thought that would be how I measure the input offset voltage?

(The VIN is 1V @ 1MHz)
View attachment 243995



This is my transient analysis, if I measure the peak-to-peak of the Vout will the rise over run be the slew rate? I understand it's v/s it's the rate of change of the output right?

View attachment 243996

I don't know if this is a stupid question, but is it possible to measure the open-loop voltage gain when it's a closed loop?

I'd like to have a go at simulating properly and then see if I can breadboard them and take some measurements but it's all new to me and I don't have a class for support. Any useful resources or pointers would be gratefully received. Thank you.

Real op amps are different than ideal op amps. Ideal op amps dont have input offset and limited open loop gain while real ones have both and models used in simulators usually have a way to mimic these values also.

To measure the input offset with the closed loop gain equal to 1 just measure the DC output voltage with zero volts input signals.
To measure the open loop gain at 1MHz just open the loop and apply some voltage at 1MHz and measure the output voltage AC.

The thing about the open loop gain is that it will change for different frequencies because the op amp has built in compensation which amounts to amplitude rolloff. If you vary the input frequency only you will see the output amplitude change even though the input may always be 0.1vac or 0.2vac or 1vac for all frequencies. So if you input say 1vac and you get 1vac out, the open loop gain is 1, but if you get 2vac out then the open loop gain is 2, but if you get 0.1vac out then the open loop gain is 1/10, etc.
With a constant 1vac input and at 100kHz you may get 5vac out, but at 1MHz you may only see 1vac out.

You might also want to consider how the slew rate affects the output at various input AC frequencies. It is not really enough to consider just the open loop gain because the slew rate could distort the waveform changing it from a clean sine wave to a strange triangular shape wave.
You also have to watch out for clipping and if you do see that you have to lower the input voltage for the test.

You can also get some idea what to expect by looking at the data sheet for the op amp you are using.
 

Papabravo

Joined Feb 24, 2006
17,316
@MrAl makes an important point about simulation models. Some of them are better than others. There have been several threads about BJT models and how come there can be numerous different models for the same device. The answer is that some or all of them may or may not be valid for any particular purpose. Some of them even try to match the datasheet, but that won't help much when purchasing buys a reel of 3000 and only a few of them match the simulations or the datasheet typical numbers. The only defense is to design circuits where the actual performance can be derived from parts whose values can be tightly controlled.

Working with RF devices we never used anything that we hadn't put on an analyzer and swept. We never believed or trusted the datasheets except for the initial screen.
 
Top