# 差动放大器

\begin{align*} \newcommand{\dif}{\mathop{}\!\mathrm{d}} \newcommand{\belowarrow}[1]{\mathop{#1}\limits_{\uparrow}} \newcommand{\bd}{\boldsymbol} \newcommand{\tx}{\text} \newcommand{\L}{\mathscr{L}} \newcommand{\p}{\partial\,} \end{align*}

# Single-Ended and Differential

• Single-End: 相对于固定电势（一般是地）
• Differential: 相对于一个相反的信号

An important advantage of differential operation over single-ended signaling is higher immunity to“environmental” noise. Assume

$V_1 = V+\Delta V\\ V_2 = -V+\Delta V$

The differential signal of $V_1$ and $V_2$ is

$V_1-V_2=2V$

which cancels the noise $\Delta V$

# Basic Differential Pair

Here, two differential inputs, $V_\tx{in1}$ and $V_\tx{in2}$, having a certain CM (common mode) level, $V_\tx{in,CM}=\dfrac{V_\tx{in1}+V_\tx{in2}}{2}$. The output also have $V_\tx{out,CM}$

if we use two independent cs stage amplifier, a low $V_\tx{in,CM}$ may lead to clipping at the output. (Why?) Therefore, we use the circuit below:

• $I_{SS}=I_{D1}+I_{D2}$ is independent of $V_\tx{in,CM}$.
• If $V_\tx{in1}=V_\tx{in2}$, the output CM level is $V_{DD}-R_DI_{SS}/2$.
• $V_\tx{out1}$ reaches its minimum value $V_{DD}-R_DI_{SS}$ when $V_\tx{out2}$ is at its maximum value $V_{DD}$, therefore the maximum differential output is $\pm R_DI_{SS}$

1. $V_\tx{in,CM}=0$, $M_1,M_2$ is off, $I_{D3}=0$, $M_3$ operates in the deep triode region ($V_b>V_\tx{TH}$，and $V_{S}=V_{D}=0$)
2. $V_\tx{in,CM}\geq V_\tx{TH}$, $M_1,M_2$ is on, $V_P$ also rise. In a sense, $M_1,M_2$ constitute a source follow, $V_P$ follows $V_\tx{in,CM}$（此时 $M_3$ 可看作电阻）
3. $V_\tx{in,CM}>V_{GS1}+V_{GS3}-V_\tx{TH3}$, i.e. $V_P>V_{GS3}-V_\tx{TH3}$, $M_3$ operate in saturation, 即 Fig 4.7，$I_{D1,2}$ reaches maximum
4. $V_\tx{in,CM}>V_\tx{out1,max}+V_\tx{TH}=V_{DD}-R_DI_{SS}/2+V_\tx{TH}$, $V_\tx{out}$ remains its minimum.

$V_{GS1}+(V_{GS3}-V_\tx{TH3}) \leq V_\tx{in,CM} \leq \min \left\{ V_{DD}-R_DI_{SS}/2+V_\tx{TH}, V_{DD} \right\}$

## Quantitative Analysis

### Large-Signal Behavior

\begin{aligned} &V_\tx{out1}-V_\tx{out2}\\ =& (V_{DD}-R_{D1}I_{D1})-(V_{DD}-R_{D2}I_{D2})\\ =& R_{D2}I_{D2}-R_{D1}I_{D1}\\ =& R_D(I_{D2}-I_{D1}) \quad \tx{if} R_{D1}=R_{D2}=R_D \end{aligned} \begin{aligned} &V_\tx{in1}-V_\tx{in2}\\ &= (V_{GS1}+V_P)-(V_{GS2}+V_P)\\ &= V_{GS1}-V_{GS2} \end{aligned}

$I_D = \frac{1}{2} \mu_n C_\tx{ox} \frac{W}{L} (V_{GS}-V_\tx{TH})^2$

$\sqrt{\frac{I_D}{\frac{1}{2} \mu_n C_\tx{ox} \frac{W}{L}}} = V_{GS}-V_\tx{TH}$

\begin{aligned} V_{GS1}-V_{GS2} &= \sqrt{\frac{I_{D1}}{\frac{1}{2} \mu_n C_\tx{ox} \frac{W}{L}}} - \sqrt{\frac{I_{D2}}{\frac{1}{2} \mu_n C_\tx{ox} \frac{W}{L}}} \end{aligned}

\begin{aligned} (V_{GS1}-V_{GS2})^2 &= \frac{2}{\mu_n C_\tx{ox} \frac{W}{L}} (I_{D1}-2\sqrt{I_{D1}I_{D2}}+I_{D2})\\ &= \frac{2}{\mu_n C_\tx{ox} \frac{W}{L}} (I_{SS}-2\sqrt{I_{D1}I_{D2}}) \end{aligned}\\ -2 \sqrt{I_{D1}I_{D2}} = \frac{1}{2} \mu_n C_\tx{ox} \frac{W}{L}(V_{GS1}-V_{GS2})^2-I_{SS}

$4I_{D1}I_{D2}=(I_{D1}+I_{D2})^2-(I_{D1}-I_{D2})^2=I_{SS}^2-(I_{D1}-I_{D2})^2$

$\left[ \frac{1}{2} \mu_n C_\tx{ox} \frac{W}{L}(V_\tx{in1}-V_\tx{in2})^2-I_{SS} \right]^2=I_{SS}^2-(I_{D1}-I_{D2})^2$

$I_{D1}-I_{D2} = \frac{1}{2} \mu_n C_\tx{ox} \frac{W}{L}(V_\tx{in1}-V_\tx{in2})\sqrt{\frac{4I_{SS}}{\mu_n C_\tx{ox}\frac{W}{L}}-(V_\tx{in1}-V_\tx{in2})^2}$

$G_m = \frac{\p \Delta I_D}{\p \Delta V_\tx{in}}=\frac{1}{2} \mu_n C_\tx{ox} \frac{W}{L} \frac{\dfrac{4I_{SS}}{\mu_n C_\tx{ox}\frac{W}{L}}-2\Delta V_\tx{in}^2}{\sqrt{\dfrac{4I_{SS}}{\mu_n C_\tx{ox}\frac{W}{L}}-\Delta V_\tx{in}^2}}$

$\vert A_v \vert = \sqrt{\mu_n C_\tx{ox}\frac{W}{L}I_{SS}} \cdot R_D$

$\Delta V_\tx{in1}=V_{GS}-V_\tx{TH}$

$I_{SS}=\frac{1}{2}\mu_n C_\tx{ox} \frac{W}{L} \Delta V_\tx{in}^2\\ \Rightarrow \Delta V_\tx{in1} = \sqrt{\dfrac{2 I_{SS}}{\mu_n C_\tx{ox} \frac{W}{L}}}$

$\Delta V_\tx{in1}$ is the maximum differential input, and for zero differential input, $I_{D1}=I_{D2}=I_{SS}/2$, yielding

$(V_{GS}-V_\tx{TH})_{1,2}=\sqrt{\dfrac{I_{SS}}{\mu_n C_\tx{ox}\frac{W}{L}}}$

Thus, $\Delta V_\tx{in1}$ is equial to $\sqrt{2}$ times the equilibrium overdrive.

### Small-Signal Analysis

\begin{aligned} \vert A_v \vert &= \sqrt{\mu_n C_\tx{ox} I_{SS} W/L} \cdot R_D\\ &= g_m R_D \end{aligned}

#### Method 1

superposion (叠加定理): The circuit of Fig. 4.16 is driven by two independent signals.

First, let’s set $V_\tx{in2}$ to zero, and only calculate the effect of $V_\tx{in1}$ at $X$ and $Y$.

To calculate $V_X$: the impedance seen looking into the source of $M_2$ is $R_s=1/g_{m2}$, therefore $M_1$ forms a common-source stage with a degeneration resistance (Fig. 4.17a), and

$\frac{V_X}{V_\tx{in1}} = \frac{-R_D}{\dfrac{1}{g_{m1}}+\dfrac{1}{g_{m2}}} \tag{4.18}$

To calculate $V_Y$: replace $V_\tx{in1}$ and $M_1$ by Thevenin equivalent (Fig. 4.18), the Thevenin voltage $V_T = V_\tx{in1}$ and the resistance $R_T=1/g_m$, therefore $M_2$ operates as a common-gate stage, and

$\frac{V_Y}{V_\tx{in1}}=\frac{R_D}{\dfrac{1}{g_{m1}}+\dfrac{1}{g_{m2}}} \tag{4.19}$

The overall voltage gain for $V_\tx{in1}$ is

$(V_X-V_Y)\Big\vert_\tx{Due to Vin1} = \frac{-2R_D}{\dfrac{1}{g_{m1}}+\dfrac{1}{g_{m2}}} V_\tx{in1} \tag{4.20}$

which, for $g_{m1}=g_{m2}=g_m$, reduces to

$(V_X-V_Y)\Big\vert_\tx{Due to Vin1} = -g_m R_D V_\tx{in1} \tag{4.21}$

By virue of symmetry, the voltage gain for $V_\tx{in2}$ is identical to that of $V_\tx{in1}$ except for a change in the polarities:

$(V_X-V_Y)\Big\vert_\tx{Due to Vin2} = g_m R_D V_\tx{in2} \tag{4.22}$

Adding $(4.21)$ and $(4.22)$, we have

$\frac{(V_X-V_Y)}{V_\tx{in1}-V_\tx{in2}}=-g_m R_D$

#### Method 2

Consider the symmetrc circuit shown in Fig. 4.20. 如果 $V_\tx{in1}$ 和 $V_\tx{in2}$ 变化幅度相反（电路保持线性性），那么 $V_p$ 不变。
![Figure 4.20 Illustration of why node P is a virtual ground](assets/images/Figure%204.20%20Illustration%20of%20why%20node%20P%20is%20a%20virtual%20ground.jpg)

$$V_1 = V_a+ \Delta V_1\\ V_2 = V_a- \Delta V_2$$

$$\Delta I_1 = g_m \Delta V_1\\ \Delta I_2 = -g_m \Delta V_2$$

$$\Delta I_1 +\Delta I_2=0\\ \Rightarrow \Delta V_1=\Delta V_2$$

\begin{aligned} V_P&=V_\tx{in1}-V_1\\ &=(V_0+\Delta V_\tx{in}) - (V_a+\Delta V_1)\\ &=V_0-V_a\\ &或\\ &=V_\tx{in2}-V_2\\ &=(V_0-\Delta V_\tx{in}) - (V_a-\Delta V_2)\\ &=V_0-V_a \end{aligned}

## Degenerated Differential Pair

V_\tx{in1}-V_{GS1}-R_S I_{SS} = V_\tx{in2}-V_\tx{TH}\\ \begin{aligned} \Rightarrow V_\tx{in1}-V_\tx{in2} &= V_{GS1}-V_\tx{TH}+R_SI_{SS}\\ &= \sqrt{\frac{2 I_{SS}}{\mu_n C_\tx{ox} (W/L)}} + R_S I_{SS} \end{aligned}

$\vert A_v \vert = \frac{R_D}{\frac{1}{g_m} + R_S}$

The circuit thus trades gain for linearity—as is also observed from the slopes of the characteristics in Fig. 4.27(b)

# Common-Mode Response

\begin{aligned} A_{v,\tx{CM}} &= \frac{V_\tx{out}}{V_{in,\tx{CM}}}\\ &= - \frac{R_D/2}{1/(2g_m)+R_{SS}} \end{aligned}

\begin{aligned} \Delta V_X &= -\Delta V_{in,\tx{CM}} \frac{g_m}{1+2g_mR_{SS}} R_D\\ \Delta V_Y &= -\Delta V_{in,\tx{CM}} \frac{g_m}{1+2g_mR_{SS}} (R_D+\Delta R_D) \end{aligned}

\begin{aligned} (I_{D1}+I_{D2})R_{SS}&=V_P\\ (g_{m1}+g_{m2})(V_\tx{in,CM}-V_P)R_{SS} &= V_P \end{aligned}

$V_P = \frac{(g_{m1}+g_{m2})R_{SS}}{(g_{m1}+g_{m2})R_{SS}+1} V_\tx{in,CM}$

\begin{aligned} V_X &= -g_{m1} (V_\tx{in,CM}-V_P)R_D\\ &= \frac{-g_{m1}}{(g_{m1}+g_{m2})R_{SS}+1} R_D V_\tx{in,CM} \end{aligned} \begin{aligned} V_Y &= -g_{m2} (V_\tx{in,CM}-V_P)R_D\\ &= \frac{-g_{m2}}{(g_{m1}+g_{m2})R_{SS}+1} R_D V_\tx{in,CM} \end{aligned}

\begin{aligned} A_\tx{CM-DM} &= \frac{V_X-V_Y}{V_\tx{in,CM}}\\ &= -\frac{\Delta g_m R_D}{(g_{m1}+g_{m2})R_{SS}+1} \end{aligned}

$\tx{CMRR} = \left\vert \frac{A_\tx{DM}}{A_\tx{CM-DM}} \right\vert$

\begin{aligned} \vert A_\tx{DM} \vert &= \frac{R_D/2}{\dfrac{1}{g_{m1}+g_{m2}}+R_{SS}}+\frac{2g_{m1}g_{m2}R_D}{\dfrac{1}{R_{SS}}+g_{m1}+g_{m2}}\\ &= \frac{R_D}{2} \left( \frac{g_{m1}+g_{m2}+4g_{m1}g_{m2}R_{SS}}{1+(g_{m1}+g_{m2})R_{SS}} \right) \end{aligned}

\begin{aligned} \tx{CMRR} &= \frac{g_{m1}+g_{m2}+4g_{m1}g_{m2}R_{SS}}{2 \Delta g_{m}}\\ &\approx \frac{g_m}{\Delta g_m}(1+2g_m R_{SS}) \end{aligned}\\ 此处 g_m = \frac{g_{m1}+g_{m2}}{2}