---
title: The differential pair with an active load
heading: Five transistors that make a complete amplifier
eyebrow: C6 · Lesson 7 · The differential pair with an active load
xp: 40
---

::: hook
Load a differential pair with a current mirror instead of two resistors, and the mirror does something clever: it copies the current change on one side over to the other, so both halves of the signal add up at a single output. The result is a **five-transistor operational transconductance amplifier** (OTA): a differential input, a single-ended output, a gain in the hundreds or thousands, and good common-mode rejection. With a capacitive load and feedback it's already a usable op amp, and it's the first stage of most real ones.
:::

::: play
- The five-transistor OTA connected as a follower: its output is tied to its inverting input, and a 1 MHz sine swings the other input between 1 V and 2 V.
- The sine's steepest slope is 3.1 V/µs, but the output can't follow: it becomes straight ramps, because the whole 100 µA tail current flows to one side and charges the load capacitor at only $I/C_L$ = 1 V/µs, the **slew rate**.
- Lower $C_L$ to 10 pF: the slew rate rises tenfold and the output follows the sine again.
:::
:::

```sim circuit
VDD vdd 0 3.3                                   @ 9,-3 down 9
M3 x x vdd pmos VTO=-0.5 KP=2m LAMBDA=0.05      @ 3,-1 left flip
M4 out x vdd pmos VTO=-0.5 KP=2m LAMBDA=0.05    @ 4,-1 flip
M1 x inp tail nmos VTO=0.5 KP=4m LAMBDA=0.05    @ 1,2
M2 out out tail nmos VTO=0.5 KP=4m LAMBDA=0.05  @ 6,2 left
I1 tail 0 100u                                  @ 3,3 down 3
CL out 0 100p                                   @ 7,0 down 6
VIN inp 0 sine 0.5 V 1M Hz 0 ° 1.5              @ 0,2 down 4
slider: CL 10p..1n log
scope: v(inp), v(out)
time: 0..5u s
```

::: predict
## A five-transistor OTA has a 100 µA tail and drives 100 pF. How fast can its output change?

- [ ] 100 V/µs
- [ ] 10 V/µs
- [x] 1 V/µs
- [ ] 0.1 V/µs

::: reveal
1 V/µs: $\frac{100\ \mu\text{A}}{100\text{ pF}}$. When a large step arrives, one input transistor turns fully off and the other takes the whole tail current; the mirror steers all of it into or out of the load capacitor, and nothing can make it go faster. That's the slew rate, the large-signal speed limit of every op amp.
:::
:::

::: nameit
## How the mirror doubles the output

With a differential input $v_{id}$, $M_1$'s current rises by $g_mv_{id}/2$ and $M_2$'s falls by the same. $M_3$ and $M_4$ copy $M_1$'s increase to the output side, where it meets $M_2$'s decrease, so the output node receives $g_mv_{id}$ in all: the full differential signal, from one output. The stage is a transconductor with

$$G_m = g_{m1} \qquad R_\text{out} = r_{o2} \parallel r_{o4} \qquad A_d = g_{m1}(r_{o2} \parallel r_{o4})$$

For BJTs at equal currents that's $\frac{V_{An}V_{Ap}}{(V_{An} + V_{Ap})V_T}$, independent of the tail current; for MOSFETs, $\frac{2}{(\lambda_n + \lambda_p)V_{OV}}$, which is $\frac{1}{\lambda V_{OV}}$ when all the λ match, with $V_{OV}$ the input devices' overdrive.

## Common-mode rejection

A common-mode change shifts both input currents equally, and the mirror cancels them at the output, leaving only the effect of finite tail resistance:

$$A_{cm} \approx -\frac{1}{2g_{m3}R_{SS}} \qquad \text{CMRR} \approx 2g_{m3}R_{SS}\cdot g_{m1}(r_{o2} \parallel r_{o4})$$

## Speed

The output node has $R_\text{out}$ in parallel with the load capacitance $C_L$, so the open-loop gain has a pole at $f_p = \frac{1}{2\pi R_\text{out}C_L}$, and its **gain-bandwidth** is

$$\text{GBW} = A_df_p = \frac{g_{m1}}{2\pi C_L}$$

For large steps the speed is set instead by the **slew rate**,

$$\text{SR} = \frac{I}{C_L}$$

Both scale with current: more current, more speed, more power.
:::

::: example
## An OTA has a 100 µA tail, input devices at $V_{OV}$ = 0.2 V, λ = 0.05 V⁻¹ for all devices, and drives 1 pF. Find its gain, GBW and slew rate.

::: solution
1. **Input transconductance.** Each side carries 50 µA:
   $$\begin{aligned} g_{m1} &= \frac{2 \times 50\ \mu\text{A}}{0.2\ \text{V}} \\ &= 0.5\ \text{mS} \end{aligned}$$
2. **Output resistance.**
   $$\begin{aligned} r_o &= \frac{1}{0.05 \times 50\ \mu\text{A}} \\ &= 400\ \text{k}\Omega \end{aligned}$$
   Two of them in parallel give $R_\text{out}$ = 200 kΩ.
3. **Gain.**
   $$\begin{aligned} A_d &= 0.5\ \text{mS} \times 200\ \text{k}\Omega \\ &= 100 \end{aligned}$$
   which is 40 dB.
4. **Gain-bandwidth.**
   $$\begin{aligned} \text{GBW} &= \frac{0.5\ \text{mS}}{2\pi \times 1\ \text{pF}} \\ &= 80\ \text{MHz} \end{aligned}$$
5. **Slew rate.** The whole 100 µA tail charges the 1 pF, so SR = 100 V/µs.

**Answer:** the gain is 100 (40 dB), the GBW 80 MHz and the slew rate 100 V/µs.
:::
:::

::: example
## A BJT OTA uses NPN inputs ($V_A$ = 80 V) and a PNP mirror ($V_A$ = 40 V). What is its gain?

::: solution
1. **Gain.** The tail current cancels between $g_m$ and the $r_o$'s:
   $$\begin{aligned} A_d &= \frac{80 \times 40}{120 \times 0.02585} \\ &= 1032 \end{aligned}$$

**Answer:** the gain is 1032, about 60 dB, at any tail current.
:::
:::

::: example
## In the first example's OTA (50 µA per side, $g_{m1}$ = 0.5 mS), the mirror's two devices differ in width by 2%. What input offset does that cause?

::: solution
1. **Unbalanced current.** The mirror copies 2% more (or less) than it receives, so with the inputs equal the output side is unbalanced by
   $$\begin{aligned} \Delta I &= 50\ \mu\text{A} \times 0.02 \\ &= 1\ \mu\text{A} \end{aligned}$$
2. **Input that cancels it.** Holding the output steady needs an input that makes the pair cancel it:
   $$\begin{aligned} V_{OS} &= \frac{\Delta I}{g_{m1}} \\ &= \frac{1\ \mu\text{A}}{0.5\ \text{mS}} \\ &= 2\ \text{mV} \end{aligned}$$
3. **What this shows.** A mismatch in the load acts like a signal at the input divided by the input stage's $g_m$. That's why layouts make mirror devices large and place them side by side.

**Answer:** the 2% mismatch causes a 2 mV input offset.
:::
:::

::: check
given: I = 20 | 100 | 400; Vov = 0.1 | 0.25; lam = 0.02 | 0.08
answer: (I/Vov)/(2*lam*I/2)/1000
tolerance: 0.5%

## A MOSFET OTA has a {I} µA tail, input overdrive {Vov} V and λ = {lam} V⁻¹ for all devices. What is its differential gain?

::: right
Right. $g_{m1}(r_{o2} \parallel r_{o4}) = \frac{1}{\lambda V_{OV}}$ = {answer}.
:::

::: misses
- [(I/Vov)/(lam*I/2)/1000] $r_{o2}$ and $r_{o4}$ are in parallel: half of one $r_o$.
- [any] Not yet. $g_{m1} = I/V_{OV}$, $r_o = 1/(\lambda I/2)$.
:::
:::

::: check
given: VAn = 50 | 150; VAp = 25 | 80
answer: VAn*VAp/((VAn + VAp)*0.02585)
tolerance: 0.5%

## A BJT OTA has NPN inputs with $V_A$ = {VAn} V and a PNP mirror with $V_A$ = {VAp} V. What is its gain?

::: right
Right. $\frac{V_{An}V_{Ap}}{(V_{An} + V_{Ap})V_T}$ = {answer}.
:::

::: misses
- [VAn*VAp/((VAn + VAp)*0.02585)/2] The mirror delivers the whole differential signal to the output; don't halve it.
- [any] Not yet. $g_m(r_{o2} \parallel r_{o4})$; the current cancels.
:::
:::

::: check
given: I = 10 | 100 | 1000; C = 1 | 10 | 100
answer: I/C
unit: V/µs
tolerance: 0.5%

## An OTA with a {I} µA tail drives {C} pF. What is its slew rate?

::: right
Right. $I/C_L$ = {answer}.
:::

::: misses
- [I/(2*C)] In a slew, the whole tail current reaches the load, not half.
- [any] Not yet. $\text{SR} = I/C_L$.
:::
:::

::: check
given: gm = 0.1 | 1; C = 1 | 10
answer: gm*1e-3/(2*pi*C*1e-12)/1e6
unit: MHz
tolerance: 0.5%

## An OTA with $g_{m1}$ = {gm} mS drives {C} pF. What is its gain-bandwidth?

::: right
Right. $\frac{g_{m1}}{2\pi C_L}$ = {answer}.
:::

::: misses
- [gm*1e-3/(C*1e-12)/1e6] Divide by $2\pi$ for hertz.
- [any] Not yet. $\text{GBW} = g_{m1}/(2\pi C_L)$.
:::
:::

::: check
given: Rout = 100 | 1000; C = 1 | 20
answer: 1/(2*pi*Rout*1000*C*1e-12)/1000
unit: kHz
tolerance: 0.5%

## An OTA's output resistance is {Rout} kΩ and it drives {C} pF. Where is its open-loop pole?

::: right
Right. $\frac{1}{2\pi R_\text{out}C_L}$ = {answer}.
:::

::: misses
- [any] Not yet. The output node's RC.
:::
:::

::: check
given: gm3 = 0.2 | 1; RSS = 100 | 1000
answer: 1/(2*gm3*RSS)
tolerance: 0.5%

## A mirror-loaded pair has $g_{m3}$ = {gm3} mS and a tail resistance of {RSS} kΩ. What is the magnitude of its common-mode gain?

::: right
Right. $\frac{1}{2g_{m3}R_{SS}}$ = {answer}.
:::

::: misses
- [any] Not yet. The mirror cancels most of it; what's left is $1/(2g_{m3}R_{SS})$.
:::
:::

::: check
kind: parts
given: I = 20 | 100 | 400; ov = 0.15 | 0.25; m = 1 | 3

## An OTA has a {I} µA tail, input devices at {ov} V of overdrive, and a load mirror whose devices differ by {m}%.

::: part
answer: I/ov/1000
unit: mS
tolerance: 0.5%

### What's $g_{m1}$?

::: misses
- [2*I/ov/1000] Each input device carries half the tail.
- [any] $\frac{2(I/2)}{v_{OV}}$.
:::
:::

::: part
answer: I/2*m/100/(I/ov)*1000
unit: mV
tolerance: 0.5%

### What input offset does the mirror mismatch cause?

::: misses
- [I*m/100/(I/ov)*1000] The mismatch applies to the half-tail current.
- [any] $V_{OS} = \frac{\Delta I}{g_{m1}}$.
:::
:::
:::

::: check
kind: derivation
vars: I = 0.000001..0.001, v = 0.05..0.5, l = 0.01..0.2, C = 0.0000000000001..0.00000000001

## A MOSFET OTA has tail I, input overdrive v, all devices with channel-length modulation l, and drives C.

::: step
answer: I/v

### What's $g_{m1}$?
:::

::: step
answer: 1/(l*I)

### What's its output resistance, $r_{o2} \parallel r_{o4}$?
:::

::: step
answer: 1/(l*v)

### What's its gain?
:::

::: step
answer: I/v/(2*pi*C)

### What's its gain-bandwidth product?
:::

::: right
Right. The gain depends only on λ and the overdrive, not on the current.
:::
:::

::: explain
## Why does an OTA's slew rate depend on its tail current and not on its gain?

::: model
For small signals the input pair shares its tail current smoothly and the output current is proportional to the input difference, so the gain and bandwidth set how fast the output follows. A large step overwhelms that: one input transistor turns off completely and the other carries the entire tail current. The mirror then delivers exactly that current, no more, into the load capacitance, so the output ramps at the tail current divided by the capacitance, however large the input step or the gain. To slew faster you have to spend more current or drive less capacitance.
:::
:::

::: practice

::: check
given: A = 10 | 50 | 100 | 500 | 1000 | 3000 | 10000 | 200000
answer: 20*log(A)
unit: dB
tolerance: 0.5%

## What is a gain of {A} in dB?

::: misses
- [any] $20\log_{10}A$.
:::
:::

::: check
given: A0 = 100 | 10000; fp = 1 | 50
answer: A0*fp
unit: kHz
tolerance: 0.5%

## An amplifier has DC gain {A0} and a single pole at {fp} kHz. What is its gain-bandwidth?

::: misses
- [any] $A_0f_p$.
:::
:::

::: check
given: SR = 1 | 20; V = 1 | 5
answer: V/SR
unit: µs
tolerance: 0.5%

## How long does an output slewing at {SR} V/µs take to move {V} V?

::: misses
- [any] $V/\text{SR}$.
:::
:::
:::
