Two op amp circuit

WBahn

Joined Mar 31, 2012
29,976
Rather curiously, I have ...

\( V_{o1} - V_{o2 }=(V_2-V_1) \frac{(R_2+R_4)}{(R_1+R_3)}\)

.....????
I get this for the case where V1 and V2 are floating (i.e., a voltage is a applied between them that is not ground references). It has the same problem in that the actual output voltages are not uniquely defined, just the difference. Also, if there is ANY common mode path at the inputs, then this solution no longer applies.
 
I asked you to give a numerical counterexample because I thought post #17 wasn't very clear as to showing that there is no unique solution.

Now, consider the case where the opamp gains are finite; is there a unique solution then?
 

MrAl

Joined Jun 17, 2014
11,389
I don't think there is a unique solution for a given set of input. Consider a load line analysis. Pick a ratio for R2/R1 and then plot Vo1 vs Vy for a series of inputs values for V1. In essence, you are pretending the Vy is a reference signal supplied by a separate circuit (which is exactly what it is). Now pick a ratio for V4/R3 and plot Vo2 vs Vy on the same set of axes. Now focus on the curve for a particular value of V1 and a particular value of V2 and ignore the rest. These are the load lines for the circuit. Since they were plotted using the same axis for Vx and Vy, ANY vertical line that you care to draw satisfies the requirement that Vx=Vy and, as you can see, each choice of Vx=Vy results in a pair of values for Vo1 and Vo2 that are suitable. But any other choice produces a different pair of values that are equally suitable. So you don't have a unique solution.
Hi,

I think all that proves is that Vx=Vy is not a sufficient condition for obtaining the solution.
Vx-Vy=K
where K is a constant, may show a unique solution and this would happen with non infinite gain.
So in other words the differentials before amplification would be K and -K, and of course then Vx!=Vy, but is slightly different and that difference (K) depends on the op amp internal gain.

I think it may also be a mistake in assuming that the gains of the two op amps are equal, because if they are not that could imbalance the network.
If they are close it might still work though, at least in real life.
In theory it may not actually work without using a non infinite gain, because the network is just too symmetrical with infinite gain. If we allow non infinite gain we definitely get a unique solution, and starting with non infinite gain and then later allowing it to go to infinity we also get a unique solution.

What we should probably do next is look at the circuit when the gains are non infinite but are also not exactly equal for both op amps because that would be a real life situation.

Another interesting property seems to be that Vo2=-Vo1 no matter what we make the resistor values or inputs (with equal op amp gains).
 
Last edited:

WBahn

Joined Mar 31, 2012
29,976
Hi,

I think all that proves is that Vx=Vy is not a sufficient condition for obtaining the solution.
Vx-Vy=K
where K is a constant, may show a unique solution and this would happen with non infinite gain.
So in other words the differentials before amplification would be K and -K, and of course then Vx!=Vy, but is slightly different and that difference (K) depends on the op amp internal gain.

I think it may also be a mistake in assuming that the gains of the two op amps are equal, because if they are not that could imbalance the network.
If they are close it might still work though, at least in real life.
In theory it may not actually work without using a non infinite gain, because the network is just too symmetrical with infinite gain. If we allow non infinite gain we definitely get a unique solution, and starting with non infinite gain and then later allowing it to go to infinity we also get a unique solution.

What we should probably do next is look at the circuit when the gains are non infinite but are also not exactly equal for both op amps because that would be a real life situation.

Another interesting property seems to be that Vo2=-Vo1 no matter what we make the resistor values or inputs (with equal op amp gains).
Using non-equal, non-infinite gains has the same problem. Consider the load line description I gave earlier. The only difference is that instead of a single vertical line you now have two vertical lines slightly offset from each other, one for Vx and one for Vy.

How are you claiming that Vo2=-Vo1? Look at the example I gave.
 
Last edited:

t_n_k

Joined Mar 6, 2009
5,455
I get this for the case where V1 and V2 are floating (i.e., a voltage is a applied between them that is not ground references). It has the same problem in that the actual output voltages are not uniquely defined, just the difference. Also, if there is ANY common mode path at the inputs, then this solution no longer applies.
Agreed on your points.

As an observation ...
If one simulates a solution using a virtually ideal op amp model, the two simulators I actually tried give outputs Vo1 & Vo2 as +/- half their difference.
Perhaps the active sources in the model are constrained in some way (by the software algorithm?) to equalize their notional active powers.
 

WBahn

Joined Mar 31, 2012
29,976
Perhaps the gold standard for seeing if the circuit is statically stable is to perform the analysis with a noise source connected between one of the outputs and its feedback path and then see if the derivative of that output signal with respect to the noise source is negative. I may do that at some point and turn it into a blog post.
 
Using non-equal, non-infinite gains has the same problem. Consider the load line description I gave earlier. The only difference is that instead of a single vertical line you now have two vertical lines slightly offset from each other, one for Vx and one for Vy.
That's not the only difference. The situation is no longer controlled by these two equations:

Vo1(V1, Vy) = Vy·[1 + (R2/R1)] - V1·(R2/R1)
Vo2(V2, Vx) = Vx·[1 + (R4/R3)] - V2·(R4/R3)

The opamp gain(s) must be taken into account.

Using the original circuit's resistor values, setting V1=2, V2=-1, and both opamps having a gain of 20, solve the circuit.

A solution is Vx=0.252252, Vy=0.414414, Vo1=-3.24324, Vo2=3.24324

I think this solution is unique; can you find another?
 

WBahn

Joined Mar 31, 2012
29,976
That's not the only difference. The situation is no longer controlled by these two equations:

Vo1(V1, Vy) = Vy·[1 + (R2/R1)] - V1·(R2/R1)
Vo2(V2, Vx) = Vx·[1 + (R4/R3)] - V2·(R4/R3)

The opamp gain(s) must be taken into account.

Using the original circuit's resistor values, setting V1=2, V2=-1, and both opamps having a gain of 20, solve the circuit.

A solution is Vx=0.252252, Vy=0.414414, Vo1=-3.24324, Vo2=3.24324

I think this solution is unique; can you find another?
How about:

Vx = 0.403101 V; Vy = 0.263566 V
Vo1 = 20*(Vy-Vx) = -2.79070 V
V02 = 20*(Vx-Vy) = +2.79070 V

Does this satisfy KCL?

Current from Vo1 to V1 = I1 = (Vx - V1)/R1 = -1.59690 mA ?= (Vo1-Vx)/R2 = -1.59690 mA (YES)
Current from Vo2 to V2 = I2 = (Vy - V2)/R3 = 1.26357 mA ?= (Vo2-Vy)/R4 = 1.26357 mA (YES)
 

Tesla23

Joined May 10, 2009
542
I think it is easier to understand the problem in this circuit by drawing the top part as:


and similarly for the bottom circuit. So when you connect them together, as far as nodes Vx and Vy are concerned you have back to back buffers:



At this point I lose interest, but I suspect that with ideal components this will appear stable and allow any voltage to be put in for Vx (=Vy). For real op-amps there will inevitably be some phase shift and WBahn's instinct for instability will be realised, either in oscillation or a tendency for oscillation that drives one (possibly both) op amps to limit on the rails.
 

Attachments

How about:

Vx = 0.403101 V; Vy = 0.263566 V
Vo1 = 20*(Vy-Vx) = -2.79070 V
V02 = 20*(Vx-Vy) = +2.79070 V

Does this satisfy KCL?

Current from Vo1 to V1 = I1 = (Vx - V1)/R1 = -1.59690 mA ?= (Vo1-Vx)/R2 = -1.59690 mA (YES)
Current from Vo2 to V2 = I2 = (Vy - V2)/R3 = 1.26357 mA ?= (Vo2-Vy)/R4 = 1.26357 mA (YES)
I made a sign error in post #28; the results I gave were for an opamp gain of -20. The results you give here are indeed the correct results for an opamp gain of 20.

In both cases, I believe those results are unique. Do you believe otherwise? If so, can you exhibit another set of results for the opamp gain of 20 case?
 
I think it is easier to understand the problem in this circuit by drawing the top part as:

This is only a unity gain buffer if V1 is left floating; if V1 is not floating then it's more than unity gain which exacerbates the problem with the loop you show in your next image.

But if a floating source is connected between V1 and V2, there's feedback there; a source of zero volts in this case amounts to just connecting V1 and V2 together; what then for overall feedback?.

Whatever is done with V1 and V2, at some very low opamp gain (less than unity for sure) the circuit will be stable. How do we assess that? Part of the practical problem is that the opamps have gain and phase shift that is frequency dependent.

Some time ago an IEEE prize paper appeared that dealt with the problem of assessing stability in circuits that (apparently) don't have any reactive circuit elements. As far as I know, the general problem remains unsolved.

and similarly for the bottom circuit. So when you connect them together, as far as nodes Vx and Vy are concerned you have back to back buffers:



At this point I lose interest, but I suspect that with ideal components this will appear stable and allow any voltage to be put in for Vx (=Vy). For real op-amps there will inevitably be some phase shift and WBahn's instinct for instability will be realised, either in oscillation or a tendency for oscillation that drives one (possibly both) op amps to limit on the rails.
The part in red is what, in my opinion, makes this and similar circuits interesting. Why doesn't the ordinary mathematics we use to solve circuits like this give an indication of DC instability?
 

WBahn

Joined Mar 31, 2012
29,976
I made a sign error in post #28; the results I gave were for an opamp gain of -20. The results you give here are indeed the correct results for an opamp gain of 20.

In both cases, I believe those results are unique. Do you believe otherwise? If so, can you exhibit another set of results for the opamp gain of 20 case?
I was thinking about this problem while I was soaking in the tub and these are the thoughts I had (I haven't put anything to paper yet, so I may prove myself wrong).

In general there are four unknowns, Vo1, Vo2, Vx, and Vy. Let's assume that by adding finite gain to the opamps (perhaps even finite gains that are different to break the symmetry if that is what it ends up taking) we get a unique solution. Well, at that point we have a quandary because we know that in the limit of infinite gain that we have a continuum of solutions. So at what point as we move from low gain to high gain do we go from uniqueness to mutlivaluedness? The fact that we do at all would seem to argue that the circuit is not statically stable and that using finite gain merely allows us to find a unique, but unstable, equilibrium point.
 

Tesla23

Joined May 10, 2009
542
This is only a unity gain buffer if V1 is left floating; if V1 is not floating then it's more than unity gain which exacerbates the problem with the loop you show in your next image.
U1 is an ideal op amp so it will adjust V01 until Vx = Vy, exactly, regardless as to whether V1 is floating or not. This is unity gain.
 

MrAl

Joined Jun 17, 2014
11,389
Using non-equal, non-infinite gains has the same problem. Consider the load line description I gave earlier. The only difference is that instead of a single vertical line you now have two vertical lines slightly offset from each other, one for Vx and one for Vy.

How are you claiming that Vo2=-Vo1? Look at the example I gave.

Hi,

Which example is that?
With equal gains for the op amps, the output always seems to go to Vo2=-Vo1.
With unequal gains the output changes, but still seems stable.
I am not sure i can accept perturbation of Vx as a proof of any type, because that's not really an input. If we had two resistors forming a junction, they would determine what the voltage was in between, and any forced perturbation would still result in a valid circuit but it would no longer be the same circuit.

Anyway...

One thing to point out here is that positive feedback is not always bad. Positive feedback can be used to boost input impedance for example. What matters is the gain around the loop, which must be less than 1.
Also keep in mind that with finite gains Vx is not equal to Vy but is minutely different, and because they present a small voltage to the op amps that appears opposite in sign to each input one op amp output MUST go positive while the other goes negative, and if the finite gains are equal the outputs must be equal and opposite in sign.

It should not be hard to analyze this with finite gains for the op amps. We did it (and Jony's first post) already but then let the gains go to infinity, all we have to do is make them separate (A1 and A2) and then keep them finite. Should be easy. We could then look at the gain around the loop and see if it is less than 1 or not. I think it will be otherwise my Spice simulations with two different op amp models would not be so nice and stable. A quick guess would be that when the gains both go to infinity the gain around the loop goes to exactly 1, which means we are borderline stable. The equations still work out because a gain around the loop of exactly 1 is still ok if the solution converges when the gain reaches exactly 1 (a gain of 1 with zero input means the output is still just zero so the input is still zero, and with an input of 1 the output is 1 so the input is still 1, and so on and so forth).

As a matter of fact we might even find an interesting relationship between the gains A1 and A2 and the outputs.
 
Last edited:
U1 is an ideal op amp so it will adjust V01 until Vx = Vy, exactly, regardless as to whether V1 is floating or not. This is unity gain.
I agree if the opamps are ideal; then with zero ohms output impedance, infinite gain and bandwidth and no phase shift, ever, the loop will be meta-stable. Whatever voltage appears at Vx or Vy or Vo1 or Vo2, for whatever reason, well circulate around the (exactly unity gain) loop forever. If something changes that voltage momentarily, the new voltage will circulate, etc.

But, we've pretty much dealt with the ideal opamp case. The circuit behavior is indeterminate. I'm thinking about real opamp behavior.

WBahn has voiced what is to me a very interesting question: "So at what point as we move from low gain to high gain do we go from uniqueness to mutlivaluedness?"
 
Jony130 owns this thread and we haven't heard from him for a while. I would like to continue the path we're on, and Jony130 might speak up about his feelings about the discussion so far. We could start a new thread if he would prefer, but so far the discussion is directly relevant to the circuit he posted.
 

WBahn

Joined Mar 31, 2012
29,976
This is only a unity gain buffer if V1 is left floating; if V1 is not floating then it's more than unity gain which exacerbates the problem with the loop you show in your next image.

But if a floating source is connected between V1 and V2, there's feedback there; a source of zero volts in this case amounts to just connecting V1 and V2 together; what then for overall feedback?.

Whatever is done with V1 and V2, at some very low opamp gain (less than unity for sure) the circuit will be stable. How do we assess that? Part of the practical problem is that the opamps have gain and phase shift that is frequency dependent.

Some time ago an IEEE prize paper appeared that dealt with the problem of assessing stability in circuits that (apparently) don't have any reactive circuit elements. As far as I know, the general problem remains unsolved.



The part in red is what, in my opinion, makes this and similar circuits interesting. Why doesn't the ordinary mathematics we use to solve circuits like this give an indication of DC instability?
The ordinary approaches that we use to analyze circuits like this assume that the circuit is configured properly for negative feedback and the analysis only tries to find the equilibrium point, stable or not. It's like the classic case of finding the equilibrium position for a ball on a hill by analyzing the moments on the ball and determining that it is in static equilibrium at the top of the hill. Well, this is true, but the analysis method only sought equilibrium and not stability.

We have the exact same situation with all of the classic opamp circuits we use all the time. Let's take the example of the classic inverting amplifier with input resistance R0 and feedback resistance Rf. Using the ideal opamp assumptions, we get that

\(
Vout = -Vin \frac{R_f}{R_0}
\)

Reverse the inputs and you get the same answer. But of course we know that this is unstable.

This doesn't improve even if we assume a finite gain. For the proper configuration we get:

\(
Vout = -Vin \frac{R_f}{1+ \( \frac{R_0+R_f}{A_v} \)}
\)

For the wrong configuration, we get:

\(
Vout = -Vin \frac{R_f}{1-\( \frac{R_0+R_f}{A_v} \) }
\)

Don't read anything into the plus sign changing to a minus sign -- it tells us nothing about stability because the analysis never sought to inquire about stability. If you analyze the classic non-inverting amplifier you get a similar pair of equations but this time the signs on the term with Av are swapped.

So how can we analyze a circuit for stability (static stability in this case, so we'll limit it to that case which simplifies things quite a bit)? Well, what does it mean for a system to be statically stable? Think of the ball on a surface -- a point of static equilibrium is stable only if a small perturbation from that point causes the system to move back toward the equilibrium point and not further away from it. We can apply this same notion to our circuits by adding a noise source in the feedback loop and asking if a small change in the output voltage due to that noise source causes a response that moves the output back. Notice that this generally does NOT mean that the derivative of the output with respect to the noise source is negative since if we have noise that tends to move the output in one direction we don't expect the negative feedback to completely counter this. But we do expect the output of the opamp to move in a direction that reduces the noise excursion. So we expect the output of the opamp (before the noise source) to move in the direction opposite the noise source. If we keep Vout as the system output, we'll call Vo the opamp output.

Mathematically, this equates to the requirement:

\(
\frac{dV_{o}}{dV_n} < 0
\)

It actually doesn't matter which polarity we use for our noise source, but it makes more sense to put the negative terminal at the opamp (Vo) and the positive terminal at the feedback tap (Vout).
If we use this model for our properly configured inverting amplifier we get:

\(
V_{o} = -Vin \frac{R_f}{1 + \( \frac{R_0+R_f}{A_v} \)}-V_n \frac{1}{1+\frac{R_0+R_f}{A_v}}
\)

The derivative we are looking for is:

\(
\frac{dV_{o}}{dV_n} = - \frac{1}{1+\frac{R_0+R_f}{A_v}} < 0
\)

We can see that the derivative we are looking for is, indeed, negative for all positive values of Av including infinity.

For the improperly configured inverting amplifier we get:

\(
V_{o} = -Vin \frac{R_f}{1 - \( \frac{R_0+R_f}{A_v} \)} + V_n \frac{1}{1 - \( \frac{1+\frac{R_f}{R_0}}{A_v} \)}
\)

And the derivative is negative only if the open loop gain is smaller than the nominal closed loop gain.
 

Tesla23

Joined May 10, 2009
542
It is a bit more interesting than I first thought.

Solving for finite op amp gain

\(
V_x = \frac{\beta(1+\beta+A_v)V_1 + \beta A_v V_2}{(1+\beta)^2 + 2(1+\beta)A_v}
\)

\(
V_y = \frac{\beta(1+\beta+A_v)V_2 + \beta A_v V_1}{(1+\beta)^2 + 2(1+\beta)A_v}
\)

where \(\beta = \frac{R_2}{R_1} = \frac{R_4}{R_3}\)

You can do it for asymmetric \(A_v, \beta\) but it's not much more informative.

This is interesting as it tends to a limit as \(A_v \to \infty \)

\(
V_x = V_y = \beta \frac{V_1 + V_2}{2(1+\beta)}
\)

although, as has been discussed, this is not the only solution.

I've changed my mind, the Vx,Vy feedback loop is stable, as the loop gain is always less than unity. I haven't studied exactly how stable, but it is stable.

WBahn's approach is interesting, if you add a voltage source \(V_n\) between Vy and the non-inverting input of U1 then you find that

\(
V_x = V_{x0} + \frac{A_v(1+\beta+A_v)}{(1+\beta)^2+2(1+\beta)A_v}V_n
\)

where \(V_{x0} \) is the original \(V_x \) solution.

This is interesting as it shows that this is amplified (enormously) by the op amp voltage gain, although I'm not sure of the exact consequence of this.
 

MrAl

Joined Jun 17, 2014
11,389
Hello,

See post #35.

Also, i have found something more concrete now.

We have two op amps i'll call OP1 (top) and OP2 (bottom). If we start with a positive input at V1 it will increase Vx which ill cause a negative output from OP1, and also increase the voltage at the non inverting terminal of OP2 which will get amplified greatly by OP2 and the output will feed back to Vy which will increase the voltage at the non inverting terminal of OP1 which will increase the output of OP1 and that looks like positive feedback, but then the output of OP1 increases Vx which means we get more negative feedback into OP1 also. So it's not all positive feedback.

This kind of thing is not that unusual when we have both positive and negative feedback, as long as the negative feedback is either greater or exactly equal to the positive feedback. This probably happens here when the internal gains of the op amps are finite.
 
Top