First of all, I will make it clear, I would like to investigate the open loop gain while a negative feedback loop is active. You may ask why. The simple reason is, because a differential amplifier is only interested in the difference between the signals at the inputs. No matter how much negative or positive feedback is applied, it will amplify the difference according to the 'infamous' open loop gain.
Remembering my long long journey to design my amplifier, which at this moment is accompanying me with beautiful instrumental music, I can recall some writing that a raw gain of 100 times is sufficient. Others still, yes, yes, on this very forum, claimed to reduce the open loop gain as far as possible. However, the few helping individuals, made it very clear, open loop gain must be big for an amplifier to perform well. Thanks to these individuals, this amplifier is a reality which works, and is stable enough to remain on for days without switching off.
The fact that the amplifier works and the music it pushes into the speakers sounds nice, is an indication the open loop gain is sufficient. However, let us see!
So, if a is the non-inverting instantaneous voltage and b the inverting voltage, and the open loop gain is G while the instantaneous output voltage with these parameters is v, these should be related by:
G = v/(a - b) .... {G, itself being a function of frequency}
Remembering my long long journey to design my amplifier, which at this moment is accompanying me with beautiful instrumental music, I can recall some writing that a raw gain of 100 times is sufficient. Others still, yes, yes, on this very forum, claimed to reduce the open loop gain as far as possible. However, the few helping individuals, made it very clear, open loop gain must be big for an amplifier to perform well. Thanks to these individuals, this amplifier is a reality which works, and is stable enough to remain on for days without switching off.
The fact that the amplifier works and the music it pushes into the speakers sounds nice, is an indication the open loop gain is sufficient. However, let us see!
So, if a is the non-inverting instantaneous voltage and b the inverting voltage, and the open loop gain is G while the instantaneous output voltage with these parameters is v, these should be related by:
G = v/(a - b) .... {G, itself being a function of frequency}
Last edited:
There are several threads here in the use of the so called Tian probe to do exactly what you want.
And yes, well observed, the amp itself ALWAYS runs open loop, Vo being (Vin+ - Vin-) * Aol. Not many realize that.
Jan
And yes, well observed, the amp itself ALWAYS runs open loop, Vo being (Vin+ - Vin-) * Aol. Not many realize that.
Jan
Thanks for pointing me out the Tian Probe as it is a ready made tools which is well tried and tested. Right now, I would like to further analyse the circuit by studying waveforms at crucial points in the circuit at different frequencies. The points are the output voltage, the current through the Miller compensating capacitor, the actual base current into the base of the VAS, and finally, the voltage difference at the inverting input and non-inverting input. Plotting the output voltage versus the voltage difference at the input produced Lissajous figures from which I obtained estimates for the open loop gain at 1000Hz and 16kHz. These estimates are a raw gain of 32000 at 1kHz and 3200 at 16kHz. The raw closed loop gain is about 55 times. This means, there is enough open loop gain across the entire audio frequency range. The fact there are phase differences between the output voltage and the various waveforms makes calculation difficult. The graphs show very clearly the dominant effect of Miller compensation as the voltage difference at the inputs and output are 90 degrees out of phase in accordance with the current through a capacitor.
Using the .meas LTSpice directive I did several simulations starting with an input frequency of 1000Hz and ending with a frequency of 20kHz. The results show the open loop gain remains large enough throughout the entire audio range. The results are summarised below:
The phase difference between V(non_inv) - V(inv) remains at 90 degrees throughout the entire audio spectrum and beyond. This is a clear indication of the dominant role of the Miller capacitor acting on the VAS. The output voltage lags the voltage difference between the inputs by 90.
Code:
Freq = 1kHz, open_loop_gain = 38001.1
Freq = 2kHz, open_loop_gain = 27905.7
Freq = 3kHz, open_loop_gain = 21966
Freq = 5kHz, open_loop_gain = 15384
Freq = 10kHz, open_loop_gain = 8118.04
Freq = 13kHz, open_loop_gain = 6282.48
Freq = 16kHz, open_loop_gain = 5083.2
Freq = 20kHz, open_loop_gain = 4111.14
The phase difference between V(non_inv) - V(inv) remains at 90 degrees throughout the entire audio spectrum and beyond. This is a clear indication of the dominant role of the Miller capacitor acting on the VAS. The output voltage lags the voltage difference between the inputs by 90.
Last edited:
Open loop gain is not a sufficient metric. The phase of the feedback determines whether this gain is useful. The Tian probe provides this info.
You are right of course, but I think his mentioning that the input signal phase remains constant over the bandwidth gives a similar assurance for stability.
But the Tian probe is awesome, I have just started to use it a few weeks ago and it is very powerful.
But I also wonder, if just plotting Vo / (Vin+ - Vin-), both mag and phase, would not give the same info. Thinking further about that, it could be measured on real hardware with something like a Bode 100 network analyzer. That would give you the option of measuring open loop response in real closed loop hardware!
Unless I am dreaming ...
Jan
But the Tian probe is awesome, I have just started to use it a few weeks ago and it is very powerful.
But I also wonder, if just plotting Vo / (Vin+ - Vin-), both mag and phase, would not give the same info. Thinking further about that, it could be measured on real hardware with something like a Bode 100 network analyzer. That would give you the option of measuring open loop response in real closed loop hardware!
Unless I am dreaming ...
Jan
I do not know whether LTSpice allows for custom functions through the use of a built-in programming language. Functions that would be extremely powerful are like the following. The language used for these function names is the "C language".
Empowered with these functions, the gain at every frequency would be easy to plot. The same can be written about the other function.
Code:
double phase_difference(char* signal_a, signal_b);
double root_mean_square(char* signal);
Empowered with these functions, the gain at every frequency would be easy to plot. The same can be written about the other function.
LTspice supports user-defined functions, but I don't think it is C compatible. It is defined in the Help file.
Jan
Jan
Personally, I find it easier to study open loop gain behavior the old fashioned way, without the Tian probe. So I break the loop at a point where a very low impedance circuit node, drives a high impedance load. Often this is the point where the input stage diff pair's negative input, connects to the feedback voltage divider (resistor pair).
Apply an AC input on one side of the loop break, measure the AC output on the other side of the loop break, and plot V(out)/V(in) both magnitude and phase. Presto: open loop gain.
To allow the simulator to converge onto the right DC operating point, the "loop break" is in fact a -40dB/decade lowpass filter whose corner frequency is 1E-3 radians per second. Far far lower than the lowest audio frequency of interest for AC analysis . . . BUT it passes DC without attenuation, so the simulator gets the correct DC operating point. The unusual looking "1E-3 rad/sec" arises from the easily remembered component values (L = 1000 Henry) + (C = 1000 Farad). Add in a couple of LTSPICE elements "E" to make infinite input impedance, zero output impedance buffers, one at the input and the other at the output. Bob's your uncle.
This approach has the benefit that you only need to run one single .AC analysis to get OLGain and OLPhase. So you can .STEP component values and immediately see their effect upon gain & phase, in the overlay plots. You can also plot V(out)/V(in) at every individual stage or every individual device in the circuit, and figure out where unexpected "excess phase shift" is coming from. If you're nervous about gate stopper resistors in MOSFET output stages, this will reassure you. Now you can see how much phase margin you're sacrificing, in exchange for insurance against MOSFET parasitic oscillation.
If the above is confusing, if you need someone to explain it further and draw a bunch of diagrams, and walk you through it step by step: just put it aside, forget about it, and use the Tian probe instead. Tian is easier to grasp.
Apply an AC input on one side of the loop break, measure the AC output on the other side of the loop break, and plot V(out)/V(in) both magnitude and phase. Presto: open loop gain.
To allow the simulator to converge onto the right DC operating point, the "loop break" is in fact a -40dB/decade lowpass filter whose corner frequency is 1E-3 radians per second. Far far lower than the lowest audio frequency of interest for AC analysis . . . BUT it passes DC without attenuation, so the simulator gets the correct DC operating point. The unusual looking "1E-3 rad/sec" arises from the easily remembered component values (L = 1000 Henry) + (C = 1000 Farad). Add in a couple of LTSPICE elements "E" to make infinite input impedance, zero output impedance buffers, one at the input and the other at the output. Bob's your uncle.
This approach has the benefit that you only need to run one single .AC analysis to get OLGain and OLPhase. So you can .STEP component values and immediately see their effect upon gain & phase, in the overlay plots. You can also plot V(out)/V(in) at every individual stage or every individual device in the circuit, and figure out where unexpected "excess phase shift" is coming from. If you're nervous about gate stopper resistors in MOSFET output stages, this will reassure you. Now you can see how much phase margin you're sacrificing, in exchange for insurance against MOSFET parasitic oscillation.
If the above is confusing, if you need someone to explain it further and draw a bunch of diagrams, and walk you through it step by step: just put it aside, forget about it, and use the Tian probe instead. Tian is easier to grasp.
I like your approach, because it instigates me to understand, instead of memorising facts without supporting proof. This is truly 'mind' empowerment. With understanding, anything become more and more versatile.Mark Johnson said:If the above is confusing, if you need someone to explain it further and draw a bunch of diagrams, and walk you through it step by step: just put it aside, forget about it, and use the Tian probe instead. Tian is easier to grasp.
If my understanding is correct, I am understanding that the loop is actually not broken, but instead of a break, an LC extremely low pass filter is inserted.
Rest assured, I will try this mouth watering method. It reminds me when I was an A-Level student, and saw a problem on Pure Mathematics Paper 2 advicing that the derivation of the equation presented, was beyong the exam's scope. That was a challenge for me, and using complex numbers and series, I derived the equation. Of course, this was not done during an exam, that would be utterly stupid. The equation was a formula for the summation of sin(a) + sin(2a) + sin(3a) + .... + sin(na).
Thanks for sharing your 'antique' method: I love such methods.
Last edited:
Tian is the method that provides the highest accuracy wrt to loading on the feedback by the input stage. It may be the only method that gives high accuracy for feedback to low impedance nodes. It is worth learning how to use. How it works is extremely well documented in IEEE and other publications.
It is also the one method that takes in account forward transmission via the feedback network. That improves accuracy at high frequencies.
Jan
Jan
Just getting into OLG simulations.
So there´s "big inductor", Middlebrook, Tian.
But what is this guy doing?:
LTspice: Stability of Op Amp Circuits | Analog Devices
He is just putting a 0V-DC-source with an AC value of 1 where the big inductor would be.
I thought it would be equivalent to the big inductor method but it doesn´t seem so (compared in sim) or am I missing something?
So there´s "big inductor", Middlebrook, Tian.
But what is this guy doing?:
LTspice: Stability of Op Amp Circuits | Analog Devices
He is just putting a 0V-DC-source with an AC value of 1 where the big inductor would be.
I thought it would be equivalent to the big inductor method but it doesn´t seem so (compared in sim) or am I missing something?
Just getting into OLG simulations.
So there´s "big inductor", Middlebrook, Tian.
- Big inductor blocks the loading effects of the input devices.
- Middlebrook works, but has some limitations compared to Tian. My memory fails me on exactly what. I think, mostly, that it's a pita to use.
- Tian is a built-in method in some simulators. I got used to its accuracy, so I was happy to see someone had figured out how to implement it in "free" SPICE (LTspice).
- Another method I've used: some simulators let you give a resistor different values depending on AC, DC, or TRAN.
He is just putting a 0V-DC-source with an AC value of 1 where the big inductor would be.
That was my most-used method before Tian came along. The accuracy is not as good up near the 0dB loop gain frequency.
It's a poor craftsman who blames his tools.
Equivalently, an expert craftsman can get best-in-class results using not-best-in-class tools. It's the painter not the paintbrush. When I visited the Rijksmuseum I didn't admire the tools that were used; I admired the results that experts were able to achieve using them.
_
Equivalently, an expert craftsman can get best-in-class results using not-best-in-class tools. It's the painter not the paintbrush. When I visited the Rijksmuseum I didn't admire the tools that were used; I admired the results that experts were able to achieve using them.
_
Last edited:
Engineers are not craftsmen. The circuits and models are now complex enough that no one is able to do accurate hand calculations. Accuracy of simulation tools and models are indispensable for designing good integrated circuits that work the first time without revision.
Mask sets for fabicating ICs in leading edge processes cost millions of dollars or Euros. There's not room for crafting. It just has to work.
Discrete transistor designs are different. The base design can be etched into a PCB, and final performance can be crafted from there. Is AC OLG analysis as shown in the LTspice video good enough? Probably. I want to not be able to blame my tools.
Mask sets for fabicating ICs in leading edge processes cost millions of dollars or Euros. There's not room for crafting. It just has to work.
Discrete transistor designs are different. The base design can be etched into a PCB, and final performance can be crafted from there. Is AC OLG analysis as shown in the LTspice video good enough? Probably. I want to not be able to blame my tools.
Just getting into OLG simulations.
So there´s "big inductor", Middlebrook, Tian.
But what is this guy doing?:
LTspice: Stability of Op Amp Circuits | Analog Devices
He is just putting a 0V-DC-source with an AC value of 1 where the big inductor would be.
I thought it would be equivalent to the big inductor method but it doesn´t seem so (compared in sim) or am I missing something?
The 'big inductor' is used to block AC but keep the DC conditions the same. In the video, that is done by giving the test voltage source a DC value of zero, so for DC there is no disconnection.
It is possible in this specific situation where you have an inverting amp with one input grounded, so it is not universally useable.
Getting to grips with the principle of how to measure open loop gain lets you take shortcuts like this, but it is not always that simple.
As Russell mentioned, Tian and Middlebrook probes are more universal. It pays to spend some time to get to grips with the concept behind this stuff.
Jan
Thanks Russel and Jan!
I was confused because "big inductor" and AC-source had completely different phase-graphs. One of them must be wrong.
I´m gonna compare with Tian and try to understand each different method.
I was confused because "big inductor" and AC-source had completely different phase-graphs. One of them must be wrong.
I´m gonna compare with Tian and try to understand each different method.
The big inductor is not the alternative to the ac source. The ac source is the measurement source, the big inductor is just to make sure the DC conditions in the amp remain the same.
In some cases, like in the AD video, the big inductor is not needed.
This DC-conditions stuff is completely separate from the measurement method.
Jan
In some cases, like in the AD video, the big inductor is not needed.
This DC-conditions stuff is completely separate from the measurement method.
Jan
- Home
- Amplifiers
- Solid State
- Calculating open loop gain using LTSpice