How does a differential amplifier works ? PART II (Udemy Course)

Terrific Physics
37 followers
Before we start calculating all the components necessary for this circuit to work, let's
just understand at the beginning what is this circuit doing.
We have the two inputs, IN1 and IN2, and the output is taken off the collector.
The output is equal to the voltage difference between the two inputs, right?
This is the common mode case, where both inputs are the same in voltage, as well as in phase.
This is just like the case when the noise is induced in both inputs, having the same
voltage and phase, so in this application there is no useful information that we want
to transmit and amplify, because the purpose of this application is to show you how the
output behaves when both inputs are the same.
As we mentioned previously, there are two types of gain that we have to account for.
The first type of gain is the differential gain, and the second type is the common gain.
There is no point in talking about differential gain right now, because we don't have differential
signals at the inputs.
The other type of gain is the common gain, which is the gain of the circuit when both
inputs are the same.
So how big should the common gain or common amplification if you want to say like that
be?
Well, since the main property of a differential amplifier is to get rid of the noise induced
in both inputs, the common gain in ideal case should be zero.
The common mode change in output is much less than in differential mode, but as shown here,
the output still fluctuates more than we would like.
The output signal is 1V peak-to-peak, and the input signal is 2V peak-to-peak.
So as you can see, the common gain is basically 0.5 since the output peak-to-peak amplitude
is half of the input.
If we change one of the input voltages to let's say 2V instead of 1, then we can start
talking about differential gain.
We will shortly see how to calculate the differential gain, but if we look at the output, the differential
gain is so high that the voltage starts clipping at power supply voltage and ground.
So in conclusion, we can say that differential gain is much, much higher than common mode gain.
Now let's put the voltage of this back to 1V, and as you can see, the output is almost
like a DC voltage.
The problem that we are facing right now is that the output voltage still has some fluctuations.
Ideally this should be a clean DC voltage with no fluctuations whatsoever.
In order to solve this problem, a more clever circuit has to be designed, but for that,
we have to understand the purpose of each component in our circuit.
Before we do that, let's see a much practical real-world use case where an information is
added along with the noise that is already present in the circuit.
Alright, the same circuit, the only difference is that we feed one of the inputs with a 200Hz
signal that has a voltage of 100mV.
The input signal at input 1 looks like this, and at input 2 looks like a mixture of 200Hz
and a 40Hz signal.
The fun part starts here, because as you can see, at the output, the only clean 200Hz is
present without any noise.
So the input 2 is a mixture of noise and information, and if we want to get rid of this noise, just
feed the first input with the same noise, and the output will be a noise-free signal.
Of course, in real-world, the noise will be induced in both inputs without human intervention.
And also, you won't see applications where the information is feeded only at one input,
in real-world applications, information is fed at both inputs, but one is out of phase
with 180 compared to another.
So this is how a real-world application might look like.
Both inputs contain the same information, but one has opposite phase.
If the transmission is happening over long distances, noise can be induced in both inputs,
but since the phase and amplitude will be the same, the differential amplifier will
get rid of them, leaving only the noise-free information to pass through.
The second advantage is that our 200Hz, which has a voltage of 100mV, got amplified very
well, we can talk about a gain of around 130.
So the output voltage is 130 times bigger than the input voltage.
Alright let's see how this circuit works in more detail.
There are two cases, so we will treat them separately.
The first case is differential mode case, which is the case when input 1 rises and input
2 falls by the same amount.
When input 1 rises and input 2 falls, there is more voltage across the left 1kΩ resistor,
and so more current.
This means that there is less voltage and current across the right 1kΩ resistor, right?
It adds up to the same voltage and current through the 75kΩ resistor.
It adds up to the same amount of current because this resistance is trying to sink the same
amount of current.
So if I go over this resistance, you can notice that the current is almost constant,
but there are still some fluctuations in current.
Now if there is a reduced current flowing through this right transistor, this means
nothing else but the output will start to rise, right?
There will be less voltage drop across this resistance, so the output will start to rise
towards the power supply voltage.
Now when input 1 falls and input 2 rises, the right transistor is turning on more and
more, pulling the output pin towards ground, or in this case to minus 15V.
So when input 1 falls and input 2 rises, the output falls.
There is a second case, which is the common mode case, when input 1 and input 2 rise together.
We already know that if both inputs are on the same voltage and phase, the output voltage
should be 0, right?
But why?
So if input 1 and input 2 rise together, this means that more voltage and current flows
across both 1kΩ resistors, which in turn means more voltage and current across the
75kΩ as well.
But the 75kΩ is a large resistor, right?
And so a small increase in current produces a large increase in voltage.
So the change in current through the right transistor and the voltage change in output
is much less in common mode than in differential mode.
Even though the common mode gain is much less than differential mode gain, unfortunately
the common mode gain is still not 0 as you can see here.
The output still fluctuates more than we would like.
But no problem because the circuit can be improved using a current source in place of
this 75kΩ resistor.
One more thing, how to calculate the common mode rejection ratio of this circuit?
We can use this formula here, where R1 is this resistance, little rE is the internal
emitter resistance of this transistor, which as we know is very small, and capital RE is
the emitter resistance.
If we assume the emitter intrinsic resistance is 0, then the common mode rejection ratio
is equal to 75kΩ divided by 1kΩ, which is equal to 75.
Now try to remember this value because we will compare this value to the common mode
rejection ratio of our improved circuit.
Alright so this is a very simple current source, but one that doesn't provide current to a
load or something else, but this time it sinks a constant 1.9mA current.
So current sources can provide a constant current, but they can also sink a constant
current.
This is a much better and cleaner design.
As you can see, we got rid of the two emitter resistances, and we replaced the big 75kΩ
resistance with a current source.
Now if we remember when we studied the most basic current source, also a big resistance
had to be used compared to the load resistance, so a change in load resistance won't be able
to change the current that is provided by the current source.
But the problem is that the current will always fluctuate a little bit no matter how big the
value of the resistor is, unless you design a current sink like here.
So how did we set this 1.9mA current?
Hmm, I'm glad you asked.
Don't be afraid by this minus 15V here, this time look at it like a positive 15V.
If we look at this as a positive 15V, then we will notice right away that actually there
is a voltage divider formed by these two resistances.
The output voltage of this voltage divider is –12.4V, so the emitter voltage is one
diode drop less than the base voltage, right?
So it's –12.4 – 0.6, which will be –13V.
Now the voltage drop across this resistance is 2V, since from this point to this point
there is a 2V difference.
Now if this voltage difference which is a little bit less than 2V is divided with the
value of the emitter resistance, we will get a current of 1.9mA flowing on the emitter,
but since the emitter current is equal to the collector current, the collector current
will have the same current on it.
So this is how this current source will sink a constant 1.9mA, because the base voltage
will be always constant, which in turn means that the emitter voltage will be constant
too.
Alright, but why is this current sink necessary here after all?
How does it help us?
Well, let's apply the same signal on both bases.
So I will take this out, and connect the 40Hz signal to the base.
Do you observe how better the output signal looks compared to the one that had a 75kΩ
resistance here?
The output voltage doesn't change at all.
So we completely got rid of any common signal, so we can say that the common mode rejection
ratio of this circuit is much better than on the previous example.
The 40Hz sine wave is not visible at all in the output.
The equation of the common mode rejection ratio is the same, but this time the resistance
of our current source is much higher than the previous 75kΩ resistance here.
In fact, an ideal current source has infinite resistance, right?
So you can imagine that R1 is much larger than 75kΩ.
Let me put this fancy pulse generator back to its place, and notice that this time we
are using a pulse generator just to show you how clean the pulses are at the output.
We use pulse generator instead of a sine wave generator like we used to because these tiny
pulses are more sensible to noises, and you would clearly see the distortion of the pulses
if the circuit is poorly designed, in other words, the common mode rejection ratio would
be too low.
So the higher the common mode rejection ratio, the better.
In a real world application, but I already mentioned that this 300Hz signal which represents
our information should be present at the other input 2 with opposite phase, but it's just
easier to visualize things like this.
If the same information is present with opposite phase at the other input, it means that when
input 1 rises, input 2 falls, right?
This is what opposite phase means.
Now in differential mode case, which means when input 1 rises and input 2 falls by the
same amount, there is more base current through transistor 1 and less through transistor 2.
There is also a corresponding increase in collector current.
The total current through the current source does not change, right?
The reduced current through the right transistor causes the output to rise, so when input 1
falls and input 2 rises, the output falls.
In the common mode case, when input 1 and input 2 rise together, the current source
resists any change in base current, so the emitter voltages rise to match the input changes.
Since transistor 2's collector current hasn't changed, the output stays the same as well.
Now you might ask yourself how to choose the value of this collector resistance.
Well, collector resistor is chosen as usual, so that we put the collector at half of the
power supply voltage in order to get a large dynamic range, in other words, to get a maximum
excursion.
I already explained what maximum excursion for a signal means in my previous courses,
so I assume you get it.
If I stop the simulator, we can see that when we don't have any pulse, the voltage is fixed
between power supply voltage and ground, which allows the signal to move up to power supply
voltage and down to 0.
So this is the end of the course, thanks for watching and see you next course.
