---
title: Stability, phase margin and step response
heading: From a loop gain's second pole to overshoot and settling
eyebrow: S2 · Lesson 15 · Stability, phase margin and step response
xp: 50
---

::: hook
An op amp's data sheet promises a phase margin; its user sees overshoot and ringing on a step, and a settling time. Those are the same fact in two languages. With a loop gain that has one dominant pole and a second pole at $p_2$, the closed loop is a second-order system whose damping depends only on how far $p_2$ sits above the loop's unity-gain frequency. This lesson makes the translation exact, so a designer choosing where to put the second pole knows what step response it buys, and why "60 degrees" is the usual target.
:::

::: play
- The step response of a unity-feedback amplifier whose loop gain has a dominant pole and a second pole at r times the unity-gain frequency $\omega_u$. Time is in units of $1/\omega_u$.
- With $p_2$ well above $\omega_u$ the response is a clean, slightly slow rise. As $p_2$ approaches $\omega_u$, it overshoots and rings; below it, the ringing grows.
- The readouts translate r into phase margin, damping ratio and overshoot.
:::
:::

```sim plot
view: graph
x: t = 0..20
y: y = 0..1.8
slider: r = 0.2..3.9 = 1.5
plot: 1 - exp(-0.5*sqrt(r)*sqrt(r)*t)*(cos(sqrt(r)*sqrt(1 - r/4)*t) + 0.5*sqrt(r)/sqrt(1 - r/4)*sin(sqrt(r)*sqrt(1 - r/4)*t)) | samples: 600 | label: output (t in units of 1/ωu)
plot: 1 | dashed | color: ch2 | label: final value
readout: phase margin, degrees = 90 - atan(sqrt((-r^2 + sqrt(r^4 + 4*r^2))/2)/r)*180/pi
readout: damping ratio = 0.5*sqrt(r)
readout: overshoot, % = exp(-pi*0.5*sqrt(r)/sqrt(1 - r/4))*100
```

::: predict
## An amplifier's loop gain has its second pole exactly at the loop's unity-gain frequency. How much does its closed-loop step response overshoot?

- [ ] None
- [ ] About 4%
- [x] About 16%
- [ ] It oscillates

::: reveal
About 16%. With $p_2 = \omega_u$, the closed loop has damping ratio ζ = 0.5 and phase margin 52°, and a second-order system with ζ = 0.5 overshoots by $e^{-\pi\zeta/\sqrt{1 - \zeta^2}}$ = 16%. Moving $p_2$ to 1.5$\omega_u$ gives 60° and 8.8%; to 2$\omega_u$, 65° and 4.3%. Designers pick a margin by deciding how much overshoot and settling time the application can take.
:::
:::

::: nameit
## The two-pole loop

With a dominant pole well below the band, the loop gain near crossover is $T(s) \approx \frac{\omega_up_2}{s(s + p_2)}$. Closing the loop gives a second-order response with

$$\omega_n = \sqrt{\omega_up_2}, \qquad \zeta = \frac{1}{2}\sqrt{\frac{p_2}{\omega_u}}$$

## Phase margin

The phase margin is 180° plus the loop's phase where $|T| = 1$. With $p_2 = r\omega_u$, the crossover is at $\omega_c$ with $\left(\frac{\omega_c}{\omega_u}\right)^2 = \frac{-r^2 + \sqrt{r^4 + 4r^2}}{2}$, and

$$\text{PM} = 90° - \arctan\frac{\omega_c}{p_2}$$

The quick estimate, taking $\omega_c \approx \omega_u$, is $\text{PM} \approx 90° - \arctan\frac{\omega_u}{p_2}$, slightly pessimistic.

| $p_2/\omega_u$ | PM | ζ | Overshoot |
|---|---|---|---|
| 0.71 | 45° | 0.42 | 23% |
| 1 | 52° | 0.50 | 16% |
| 1.5 | 60° | 0.61 | 8.8% |
| 2 | 66° | 0.71 | 4.3% |
| 3 | 72° | 0.87 | 0.4% |

Below about 30° the response rings badly; at 0° it oscillates.

## Step response

For ζ < 1, overshoot is $e^{-\pi\zeta/\sqrt{1 - \zeta^2}}$, and settling to within 1% takes about $\frac{4.6}{\zeta\omega_n} = \frac{9.2}{p_2}$. A higher $p_2$ settles faster as well as more cleanly.

## The feedback factor

With feedback fraction β the loop's unity-gain frequency is $\beta\omega_u$, so the same $p_2$ gives more phase margin at higher closed-loop gain. Unity-gain followers (β = 1) are the hardest case, which is why "unity-gain stable" is a data-sheet promise and some fast op amps aren't.

## Gain margin

The other number: how far below 1 the loop gain is where its phase reaches −180°, in dB. A margin of 10 dB or more guards against gain variations.
:::

::: example
## An op amp has its unity-gain frequency at 10 MHz and its second pole at 20 MHz. As a unity-gain follower, what are its phase margin, overshoot and 1% settling time?

::: solution
1. **Damping.** The pole ratio is r = 2, so ζ = 0.71.
2. **Phase margin and overshoot.** That gives PM = 66° and 4.3% overshoot.
3. **1% settling time.**
   $$\begin{aligned} t_s &= \frac{9.2}{p_2} \\ &= \frac{9.2}{2\pi \times 20\ \text{MHz}} \\ &= 73\ \text{ns} \end{aligned}$$
4. **At a closed-loop gain of 10.** With β = 0.1 the loop crosses over at 1 MHz, twenty times below $p_2$: PM near 87° and no visible overshoot.

**Answer:** a phase margin of 66°, 4.3% overshoot and 73 ns to settle to 1%.
:::
:::

::: example
## A designer wants at most 5% overshoot. Where must the second pole go?

::: solution
1. **Damping needed.** 5% overshoot needs
   $$e^{-\pi\zeta/\sqrt{1 - \zeta^2}} = 0.05 \quad\text{so}\quad \zeta = 0.69$$
2. **Pole ratio.**
   $$\begin{aligned} \frac{p_2}{\omega_u} &= 4\zeta^2 \\ &= 1.9 \end{aligned}$$
   That's a phase margin of about 65°.
3. **Quick estimate.** The quick estimate gives 62°, a little pessimistic as usual:
   $$90° - \arctan(1/1.9) = 62°$$

**Answer:** the second pole must sit at 1.9 times the unity-gain frequency or higher, a phase margin of about 65°.
:::
:::

::: example
## A two-pole amplifier used as a follower has its second pole at twice the unity-gain frequency. What damping and overshoot does it have?

::: solution
1. **Closed-loop denominator.**
   $$s^2 + p_2s + \omega_up_2$$
2. **Damping.**
   $$\begin{aligned} \zeta &= \tfrac12\sqrt{p_2/\omega_u} \\ &= 0.707 \end{aligned}$$
3. **Overshoot.**
   $$e^{-\pi\zeta/\sqrt{1 - \zeta^2}} = 4.3\%$$
4. **Phase margin.** This is the familiar rule that about 60° gives a clean step:
   $$90° - \arctan(0.5) = 63.4°$$

**Answer:** ζ = 0.707 and 4.3% overshoot, with a phase margin of 63.4°.
:::
:::

::: check
given: r = 0.5 | 1 | 2 | 3
answer: 0.5*sqrt(r)
tolerance: 1%

## A loop gain's second pole sits at {r} times its unity-gain frequency. What's the closed-loop damping ratio?

::: right
Right. $\zeta = \frac{1}{2}\sqrt{p_2/\omega_u}$ = {answer}.
:::

::: misses
- [sqrt(r)] Include the factor ½.
- [any] Not yet. Compare the closed-loop denominator with $s^2 + 2\zeta\omega_ns + \omega_n^2$.
:::
:::

::: check
given: z = 0.4 | 0.5 | 0.6 | 0.75
answer: exp(-pi*z/sqrt(1 - z^2))*100
unit: %
tolerance: 1%

## A second-order system has ζ = {z}. How much does its step response overshoot?

::: right
Right. $e^{-\pi\zeta/\sqrt{1 - \zeta^2}}$ = {answer}%.
:::

::: misses
- [exp(-pi*z)*100] Include the $\sqrt{1 - \zeta^2}$.
- [any] Not yet. The peak of the underdamped response.
:::
:::

::: check
given: r = 1.5 | 2 | 3 | 5
answer: 90 - atan(1/r)*180/pi
unit: °
tolerance: 1%

## Using the quick estimate ($\omega_c \approx \omega_u$), what phase margin does a second pole at {r} times the unity-gain frequency give?

::: right
Right. $90° - \arctan\frac{\omega_u}{p_2}$ = {answer}°.
:::

::: misses
- [atan(1/r)*180/pi] That's the phase the second pole takes; subtract it from 90°.
- [any] Not yet. The dominant pole contributes 90°, the second $\arctan(\omega/p_2)$.
:::
:::

::: check
given: r = 0.7071 | 1 | 2
answer: 90 - atan(sqrt((-r^2 + sqrt(r^4 + 4*r^2))/2)/r)*180/pi
unit: °
tolerance: 1%

## Exactly, with the true crossover frequency, what phase margin does a second pole at {r} times $\omega_u$ give?

::: right
Right. {answer}°.
:::

::: misses
- [90 - atan(1/r)*180/pi] That's the quick estimate; find the true crossover first.
- [any] Not yet. Solve $|T(j\omega_c)| = 1$, then take the phase.
:::
:::

::: check
given: p = 5 | 20 | 100
answer: 9.2/(2*pi*p*1e6)*1e9
unit: ns
tolerance: 1%

## A two-pole loop has its second pole at {p} MHz. Roughly how long does it take to settle to 1%?

::: right
Right. $\frac{4.6}{\zeta\omega_n} = \frac{9.2}{p_2}$ = {answer} ns.
:::

::: misses
- [4.6/(2*pi*p*1e6)*1e9] $\zeta\omega_n = p_2/2$, so it's $9.2/p_2$.
- [any] Not yet. The envelope decays as $e^{-\zeta\omega_nt}$.
:::
:::

::: check
given: f = 10 | 50; b = 0.1 | 0.3 | 0.5; p = 30 | 100
answer: 90 - atan(b*f/p)*180/pi
unit: °
tolerance: 1%

## An op amp with $\omega_u/2\pi$ = {f} MHz and a second pole at {p} MHz is used with feedback fraction β = {b}. Quick-estimate its phase margin.

::: right
Right. The loop crosses over at $\beta\omega_u$: $90° - \arctan\frac{\beta\omega_u}{p_2}$ = {answer}°.
:::

::: misses
- [90 - atan(f/p)*180/pi] That's for β = 1; the loop's crossover moves down to $\beta\omega_u$.
- [any] Not yet. The loop gain is βa.
:::
:::

::: check
given: g = 0.05 | 0.2 | 0.5
answer: -20*log(g)
unit: dB
tolerance: 1%

## Where a loop's phase reaches −180°, its gain is {g}. What's its gain margin?

::: right
Right. $-20\log|T|$ = {answer} dB.
:::

::: misses
- [20*log(g)] The margin is positive: how far below 1 the gain is.
- [any] Not yet. Express $1/|T|$ in dB.
:::
:::

::: check
kind: parts
given: k = 1.5 | 2 | 3

## A two-pole amplifier used as a follower has its second pole at {k} times its unity-gain frequency.

::: part
answer: 90 - asin((1/k)/sqrt(1 + 1/k^2))*180/pi
unit: °
tolerance: 0.5%

### What is its phase margin?

::: misses
- [any] $90° - \arctan(\omega_u/p_2)$.
:::
:::

::: part
answer: 100*exp(-pi*0.5*sqrt(k)/sqrt(1 - 0.25*k))
unit: %
tolerance: 1%

### What overshoot does it give, with $\zeta = \tfrac12\sqrt{p_2/\omega_u}$?

::: misses
- [any] $e^{-\pi\zeta/\sqrt{1 - \zeta^2}}$.
:::
:::
:::

::: check
kind: derivation
vars: w = 1e6..1e9, k = 0.5..3

## A follower's unity-gain frequency is w and its second pole k·w.

::: step
answer: 0.5*sqrt(k)

### What is the closed loop's damping ratio?
:::

::: step
answer: sqrt(k)*w

### What is its natural frequency?
:::

::: right
Right. Pushing the second pole out to twice the unity-gain frequency gives ζ = 0.707, the usual design target.
:::
:::

::: explain
## Why does a second pole close to the loop's unity-gain frequency cause overshoot and ringing?

::: model
Feedback corrects the output by comparing it with the input and pushing the difference back through the amplifier. At frequencies where the loop gain is near 1, the correction is as large as the error itself, so its timing matters. Each pole delays the signal, and two poles together can delay it by nearly 180°, turning the correction into a push in the wrong direction. If the second pole is far above the crossover frequency, the delay there is only a little more than one pole's 90°, and the correction stays well behaved. If it sits near the crossover, the delay approaches 135° or more, the loop overcorrects, and the output overshoots and rings before settling. At 180° of total lag with a gain of 1, the loop sustains its own oscillation.
:::
:::

::: practice

::: check
given: r = 0.8 | 1 | 1.5 | 2 | 2.5 | 3
answer: 0.5*sqrt(r)
tolerance: 1%

## Damping ratio for $p_2$ = {r}$\omega_u$?

::: misses
- [any] $\frac{1}{2}\sqrt{p_2/\omega_u}$.
:::
:::

::: check
given: z = 0.3 | 0.45 | 0.5 | 0.6 | 0.65 | 0.7 | 0.8
answer: exp(-pi*z/sqrt(1 - z^2))*100
unit: %
tolerance: 1%

## Overshoot for ζ = {z}?

::: misses
- [any] $e^{-\pi\zeta/\sqrt{1 - \zeta^2}}$.
:::
:::

::: check
given: p = 5 | 10 | 20 | 40 | 60 | 100
answer: 9.2/(2*pi*p*1e6)*1e9
unit: ns
tolerance: 1%

## 1% settling with $p_2/2\pi$ = {p} MHz?

::: misses
- [any] $9.2/p_2$.
:::
:::
:::
