A few words on so-called feedback equation and closed loop gain accuracy - Page 1
Forum section: electronics / projects

author: magic
author_rank: Super Contributor
timestamp: March 20, 2022, 11:56:05 am
content: Most opamp users will recognize this equation, which relates input and output voltage to the open loop gain of the amplifier. Seasoned veterans are aware thatAis actually not a constant and falls with frequency typically at 20dB/decade to reach a low value (usually unity) at the limits of the opamp's useful bandwidth.Vout = A · (Vin+ - Vin-)We may then consider a closed loop, noninverting application, where we feed a certain proportionβof the output (less or equal unity) back to the inverting input.Vin- = β · VoutPutting these together, we arrive at so-called "feedback equation" which is widely believed to give the closed loop gain of the amplifier.G = Vout / Vin+ == A / (1 + Aβ) == 1 / (1/A + β)The primary application of this equation is to subsequently claim that1/Ais "essentially zero" and conclude thatG = 1/β. If you feel satisfied with this answer, the back button of your browser is somewhere up there on the left, but seasoned veterans will appreciate that1/Acan be far from zero and sometimes it makes a difference if gain error is 1% at 1kHz or 0.1% at 100kHz.To calculate gain accuracy, we may divide the calculated gain by the desired gain of1/β, or simply multiply byβ.G · β == β / (1/A + β) == 1 / (1/(Aβ) + 1)The productAβis another familiar term, known as "loop gain" or "feedback factor". It is simply the ratio of open loop gain to the desired closed loop gain, or "excess gain" if you wish. The ratio above is approximately1 - 1/(Aβ)and then the relative gain error is approximately1/(Aβ)- inversely proportional to loop gain.Now it's simply a matter of running a small SPICE simulation and all our theory is confirmedGreen is the simulated output amplitude, blue plots the calculated closed loop gain:frequency/1Megis1/Aand0.01isβ.So where is the catch? It's thephaseresponse of the opamp - naive interpretations of the equations above assume that all signals are in phase, but actual opamps have 90° phase lag from the differential input voltage to the output over most of their useful bandwidth. Time domain simulation of the same circuit demonstrates that a significant differential voltage to drive the opamp is generated simply by delaying the feedback signal a little with respect to the input, with barely any loss of amplitude.In this example, loop gain is only 10, but amplitude error is less than 1% rather than 10%.At 100Hz, loop gain of 100 is enough to provide almost 0.01% accuracy. 0.01% is the limit achievable at DC due to 120dB gain of this amplifier. It appears that as frequency falls, gain error decreases with thesquareof loop gain and then it plateaus because phase response falls from 90° towards 0° and the well-known simple analysis becomes correct.Warning: I don't have a proof of this square-of-loop-gain improvement, it just worked like that in the examples I tried in SPICE.

author: mawyatt
author_rank: Super Contributor
timestamp: March 20, 2022, 01:22:08 pm
content: Quote from: magic on March 20, 2022, 11:56:05 amThe naive interpretations assume the the op amp gain is simply a scalar, it's not!! Gain should be considered as complex since it has the well know "leaky integrator" behavior.Best,

author: magic
author_rank: Super Contributor
timestamp: March 20, 2022, 02:21:54 pm
content: Plugging complex gains and frequencies into those equations does the business.Blue blindly assumes 0° phase as before.Red blindly assumes 90° phase.Truth is in between, depending on frequency.Further complications will appear near the unity gain frequency, where phase increases beyond 90° and heads towards 180°.Note: LTspice ideal opamp has perfect 90° phase margin so it is not a realistic model of what happens up there.