Analysis of the basic differential amplifier topology

Let's use the following circuit.

1574647367622.png



Ideal Opamp Approximations

We will use the following three assertions based on the assumption that we are working with an ideal opamp:

1) No current flows into either input.
2) The output is an ideal voltage source.
3) The configuration is consistent with the use of negative feedback to make the voltage at the two inputs equal.

Basic Analysis

The basic analysis of this circuit is very straightfoward and only requires looking at the circuit as a collection of simple voltage dividers.

We want Vout in terms of Va and Vb.

The relationship between Vp and Vb is easy since it is a simple voltage divider (due to assertion 1).

\(
(1) \; V_p \; = \; V_b\; \frac{R_o}{(R_b \; + \; R_o)}
\)

The current flowing in Ra is

\(
(2) \ I_n \ = \ \frac{(V_a \, - \, V_n)}{R_a}
\)

The voltage at the output is (again, assertion 1)

\(
(3) \ V_{out} \ = \ V_n \, - \, I_n \cdot R_f
\)

We can leverage assertion 3 to replace Vn with Vp in (2) and (3). Then we can substitute (1) into the first term of (3) and (2) into the second term of (3) to get

\(
(4) \ V_{out} \ = \ V_b\, \frac{R_o}{(R_b \, + \, R_o)} \, - \, \left( V_a \, - \, V_b\, \frac{R_o}{(R_b \, + \, R_o)} \right) \cdot \frac{R_f}{R_a}
\)

Collecting terms according to Va and Vb

\(
(5) \ V_{out} \ = \ V_b\, \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_f}{R_a}\right) \, - \, V_a \, \left( \frac{R_f}{R_a} \right)
\)

Analysis via Superposition

The result in equation (5) gives us a basis for analyzing the circuit in two steps using superpositon. We can first set Va=0 and then set Vb=0 and then add the two together.

\(
(6) \ V_{out_b} \ = \ V_b\, \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_f}{R_a}\right)
\)

\(
(7) \ V_{out_a} \ = \ - \, V_a \, \left( \frac{R_f}{R_a} \right)
\)

\(
(8) \ V_{out} \ = \ V_{out_a} \, + \, V_{out_b} \ = \ A_a \cdot V_a \, + \, A_b \cdot V_b
\)

Where A_a is the gain applied to the voltage input at 'a' and A_b is the gain applied to the voltage input at 'b'.

This shouldn't be too surprising. Consider the single-input opamp circuits you've worked with. You expressed the output in terms of the one input and a single voltage gain, Av, that acts on that input (and sometimes you might have also had a constant offset).

So for this topology, the gains are

\(
(8.1) \ A_a \ = \ - \, \frac{R_f}{R_a}
\)

\(
(8.2) \ A_b \ = \ \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_f}{R_a}\right)
\)

In this form we can sanity check the results and see how we could arrive at them by inspection. With Va=0, we have Vb being fed into a non-inverting amplifier after first going through a voltage divider. With Vb=0, we have Va being fed into an inverting amplifier. Both are evident from the schematic and eqns (6) and (7). So we have a high confidence that the analysis to this point is correct.

Relation to "Standard" Differential Amplifier Gain Formula

The results obtained above don't agree with the formula often thrown out by textbooks, which is of the form

\(
(9) \ V_{out} \ = \ (V_b\, - \, V_a)\, \left( \frac{R_f}{R_a} \right)\)

So what would it take to get (5) into this form? By multiplying and dividing the first term in (5) by Rf/Ra and then factoring out the one we multiplied by, we can rewrite (5) as follows

\(
(10) \ V_{out} \ = \ \left( V_b\, \left[ \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_f}{R_a}\right)\left( \frac{R_a}{R_f} \right) \right] \, - \, V_a \right)\, \left( \frac{R_f}{R_a} \right)
\)

From this, it is obvious that if we can choose Rb and Ro such that we can force the expression in square brackets to be equal to 1, that we will get (9). This means we want

\(
(11) \ \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_f}{R_a}\right)\left( \frac{R_a}{R_f} \right) \ = \ 1
\)

This is actually quite easy to do. First, multiply out the last two terms and put them over a common denominator.

\(
(12) \ \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( \frac{R_a \, + \, R_f}{R_f}\right) \ = \ 1
\)

Then divide both sides by the first factor you get

\(
(13) \ \frac{R_b \, + \, R_o}{R_o} \ = \ \frac{R_a \, + \, R_f}{R_f}
\)

Which reduces immediately to

\(
(14) \ \frac{R_b}{R_o} \ = \ \frac{R_a}{R_f}
\)

So, as long as you choose Ro and Rb such that (14) is satisfied, then equation (9), the one in the textbook, will be valid. A careful examination of most textbooks will reveal that they either simply start with a circuit that satisfies this condition, or actually perform some level of analysis leading to the adoption of this condition. Unfortunately, it is quite easy for people to forget that these ARE conditions that MUST be satisfied in order for (9) to be valid.

Common-mode and Differential Gains

We often hear the term "common mode" thrown around and this causes people a lot of grief, but it is actually quite straightforward.

We have two signals Va and Vb. Let's just write them in terms of two other signals, one of which, Vcm, is the average of the two and the other of which, Vd, is the difference of the two. So

\(
(15) \ V_{cm} \ = \ \frac{(Vb \, + \, Va)}{2}
(16) \ V_{d} \ = \ (Vb \, - \, Va)
\)

These are just arbitrary definitions -- there is nothing mysterious about them. Just a little bit of algebra should convince you that

\(
(17) \ V_a \ = \ V_{cm} \, - \, \frac{Vd}{2}
(18) \ V_b \ = \ V_{cm} \, + \, \frac{Vd}{2}
\)

There are a number of ways of thinking about this, but perhaps the most useful is to realize that we often are interested in the difference of two signals, so we write the two signals in terms of the amount by which they differ summed with everything else, which is the amount by which they don't differ or, putting it more simply, the amount that they have in common.

Stated another way, as reflected by (17) and (18), we can express two signals by writing one as the the average plus half of the amount by which they differ and the other as the average minus half of the amount by which they differ.

It really is that simple.

Now we can substitute (17) and (18) into (5) to get

\(
(19) \ V_{out} \ = \ \left( \ V_{cm} \, + \, \frac{Vd}{2} \right) \, \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_f}{R_a}\right) \, - \, \left( \ V_{cm} \, - \, \frac{Vd}{2} \right) \, \left( \frac{R_f}{R_a} \right)
\)

It is a simple matter to rearrange terms so that we collect Vcm and Vd separately.

NOTE: Apparently not so simple as some people seem to be finding this too taxing on their present algebra skills. So let's be a bit more explicit.

Multiply out (Vcm+Vd/) and (Vcm-Vd/) terms

\(
(19.1) \ V_{out} \ = \ V_{cm} \, \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_f}{R_a}\right) \, + \, \frac{Vd}{2} \, \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_f}{R_a}\right) \, - \, V_{cm} \, \left( \frac{R_f}{R_a} \right) \, + \, \frac{Vd}{2} \, \left( \frac{R_f}{R_a} \right)
\)

Collect the terms involving Vcm and Vd together.

\(
(19.2) \ V_{out} \ = \left[ \ V_{cm} \, \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_f}{R_a}\right) \, - \, V_{cm} \, \left( \frac{R_f}{R_a} \right) \right] \, + \, \left[ \frac{Vd}{2} \, \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_f}{R_a}\right) \, + \, \frac{Vd}{2} \, \left( \frac{R_f}{R_a} \right) \right]
\)

Then just factor out Vcm from the first set of terms in square brackets and Vd/2 from the second set.

\(
(20) \ V_{out} \ = \ V_{cm} \, \left[ \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_f}{R_a}\right) \, - \, \left( \frac{R_f}{R_a} \right)\right] \, + \, Vd \, \left( \frac{1}{2} \right) \left[ \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_f}{R_a}\right) \, + \, \left( \frac{R_f}{R_a} \right)\right]
\)

As with equation (8), we are merely expressing the two gains associated with a circuit that has two independent inputs. There's actually no new information here. If given the separate gains you can calculate the common-mode and differential gains and, given the latter two, can calculate the separate gains.

So why do we need or want to express the same information multiple ways? Expressing them separately makes applying the concept of superposition very easy and intuitive, but in practice it is commonly the case that we are interested in circuits that process the difference of two signals differently than they do their average. Hence it is useful to write the gains in a form where is it clear how the common mode signal is treated separate from how the differential signal is treated. This allows use to express the results as

\(
(21) \ V_{out} \ = \ A_{cm} \cdot V_{cm} \ + \ A_d \cdot V_d
\)

Where Acm is called the common mode gain and Ad is called the differential gain.

Examination of equation (20) shows immediately that, for this topology, we have

\(
(22) \ A_{cm} \ = \ \left[ \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_f}{R_a}\right) \, - \, \left( \frac{R_f}{R_a} \right)\right]
\)

\(
(23) \ A_d \ = \ \left( \frac{1}{2} \right) \left[ \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_f}{R_a}\right) \, + \, \left( \frac{R_f}{R_a} \right)\right]
\)

With this in hand, we are in a position to do something very useful in practical circuits. Typically when we are interested in the difference of two signals we want the output to ONLY be a function of the difference of those two signals (though we might be willing to accept a constant offset voltage, if he really have to). But it is usually very inconvenient if the output is also a function of the common mode signal. What this really says is that we generally would like the common mode gain to be identically zero, and equation (23) gives us exactly what we need to accomplish this.

\(
(24) \ A_{cm} \ = \ \left[ \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_f}{R_a}\right) \, - \, \left( \frac{R_f}{R_a} \right)\right] \ = \ 0
\)

Which means that we need

\(
(25) \ \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_f}{R_a}\right) \ = \ \left( \frac{R_f}{R_a} \right)
\)

We could hammer away at this, which wouldn't be hard, but by multiplying both sides by Ra/Rf we see that we get exactly the condition we had in (11) and, thus, the constraint we must impose to make the common mode gain vanish is exactly the one found in equation (14), namely

\(
(14) \ \frac{R_b}{R_o} \ = \ \frac{R_a}{R_f}
\)

It's worth noting that we originally worked out (14) just to identify the special case in which the result matched the textbook. But now we can recognize that the result in the textbook consists only of a differential signal and, therefore, requires that the common mode gain be zero. Therefore it is not surprising that the constraint needed to make the common mode gain go to zero is exactly the constraint that was needed to match the textbook formula.

The only thing left is to verify that, under the constraint imposed by (14), that the differential gain given in (23) reduces to the gain given by the textbook since, following the reasoning in the last paragraph, it must.

Substituting (14) into (23) gives us

\(
(26) \ A_d \ = \ \left( \frac{1}{2} \right) \left[ \left( \frac{R_o}{R_b \, + \, R_o} \right) \left( 1 \, + \, \frac{R_o}{R_b}\right) \, + \, \left( \frac{R_o}{R_b} \right)\right]
\)

Note that, while we eventially want the result in terms of Rf and Ra, it was trivial to get it in terms of Ro and Rb. We can simplify this expression and then simply use (14) again to get the final solution in the form we want.

\(
(27) \ A_d \ = \ \left( \frac{1}{2} \right) \left[ \frac{R_o}{R_b} \, + \, \frac{R_o}{R_b} \right]
\)

And, sure enough, this reduces very quickly to

\(
(28) \ A_d \ = \ \frac{R_o}{R_b}
\)

which, in light of (14), can also be expressed as

\(
(29) \ A_d \ = \ \frac{R_f}{R_a}
\)

As we expected and require.

Common Mode Rejection Ratio

While we would like the common-mode gain to be identically zero, in practice it never will be. Thus it would be useful to have a measure of how well a given amplifier was able to eliminate the common-mode gain. The standard measure of this is to use the ratio of the differential gain to the common mode gain, with the higher the number being better. This ratio is known as the Common Mode Rejection Ratio, or CMRR.

\(
(30) \ CMRR \ = \ \frac{A_d}{A_{cm}}
\)

Because we want the common-mode gain to be very close to zero, we can expect to get very large numbers for good amplifiers. For this reason, the CMRR is typically expressed in decibels.

\(
(31) \ CMRR_{dB} \ = \ 20 \, \log_{10} \left( \frac{A_d}{A_{cm}} \right)
\)

Technically, this is not a "ratio", and so the preferred terminology would be that the circuit has a CMR (common mode rejection) of so many dB. But the use of CMRR for both the pure ratio and the ratio expressed in decibels is extremely widespread, so get used to it.

It is useful to note that our differential amplifier circuit is based on an operational amplifier which is, itself, a differential amplifier. One of the unstatated assumptions that is virtually always made in working with opamps is that they are purely differential amplifiers and have no common-mode gain. But, being real circuits, this is not the case, though a lot of effort has gone into getting high CMRRs.

Opamps typically have a CMRR of around 80 dB, meaning that the differential gain is 10,000 times the common-mode gain. This might seem like a lot, but with, for example, a differential gain of 200,000, that means the common-mode gain is still on the order of 20 or so.

While this can have very noticeable and undesirable effects in real circuits, it generally doesn't because just as we use negative feed back to reduce the effective gain of the overall circuit to a value much, much lower than the open loop gain, this same process reduces the common-mode gain by a similar factor. In fact, the best way to account for the effect of common-mode inputs is to convert them to an equivalent differential input by dividing the common-mode component by the CMRR. To see that this is valid, one need only play with (21) and (30) a bit.

\(
(21) \ V_{out} \ = \ A_{cm} \cdot V_{cm} \ + \ A_d \cdot V_d
\)

\(
(30) \ CMRR \ = \ \frac{A_d}{A_{cm}}
\)

Therefore

\(
(32) \ V_{out} \ = \ \frac{A_d}{CMRR} \cdot V_{cm} \ + \ A_d \cdot V_d
\)

\(
(33) \ V_{out} \ = \ A_d \cdot \left( V_d \, + \, \frac{V_{cm}}{CMRR} \right)
\)

Experimentally Determining the Gains

Now let's shift gears and consider how we could experimentally determine the gains in the event we didn't have all of the known resistor values. This is valuable because, in practice, we only know what what we wanted the resistor values to be and not what they actually turned out to be. So we can characterize our amplifier by actually measuring the gains.

The key to doing this are to use either equation (8) or (21), depending on whether we want the gains for each input separately, or the common-mode and differential gains.

\(
(8) \ V_{out} \ = \ A_a \cdot V_a \, + \, A_b \cdot V_b
\)

or

\(
(21) \ V_{out} \ = \ A_{cm} \cdot V_{cm} \ + \ A_d \cdot V_d
\)

In either case, we have two unknown gains, and so we need to apply two sets of voltage inputs and measure the corresponding outputs to get the two independent equations we need. As long as we pick voltages that keep the amplifier in its active range, it doesn't matter what specific values we use, though the greater the differences in the two sets of voltages, the better our calculated gains will be.

So let's say that we measure the following data sets:

\(
V_{a1} \ \text{&} \ V_{b1} \ \ \text{produce} \ \ V_{out1}
V_{a2} \ \text{&} \ V_{b2} \ \ \text{produce} \ \ V_{out2}
\)

Thus, using (8), we have the following system of equations:

\(
(34) \ V_{out1} \ = \ A_a \cdot V_{a1} \, + \, A_b \cdot V_{b1}
(35) \ V_{out2} \ = \ A_a \cdot V_{a2} \, + \, A_b \cdot V_{b2}
\)

Solving for A_a and A_b yields

\(
(36) \ A_a \ = \ \frac{V_{a1} \cdot V_{b2} \, - \, V_{a2} \cdot V_{b1} }{V_{out1} \cdot V_{b2} \, - \, V_{out2} \cdot V_{b1} }
\
(37) \ A_b \ = \ \frac{V_{b1} \cdot V_{a2} \, - \, V_{b2} \cdot V_{a1} }{V_{out1} \cdot V_{a2} \, - \, V_{out2} \cdot V_{a1} }
\)

Since the form of equation (21) is the same as that of (8), we can get the common-mode and differential gains very easily by just using equations (15) and (16) to write out two sets of test input voltage in common-mode/differential form.

\(
(38) \ A_{cm} \ = \ \frac{V_{cm1} \cdot V_{d2} \, - \, V_{cm2} \cdot V_{d1} }{V_{out1} \cdot V_{d2} \, - \, V_{out2} \cdot V_{d1} }
\
(39) \ A_d \ = \ \frac{V_{d1} \cdot V_{cm2} \, - \, V_{cm2} \cdot V_{d1} }{V_{out1} \cdot V_{cm2} \, - \, V_{out2} \cdot V_{cm1} }
\)

Blog entry information

Author
WBahn
Views
4,282
Last update

More entries in General

More entries from WBahn

Share this entry

Top