---
title: What the impulse response tells you
heading: Causality, stability, inverses and connected systems from h alone
eyebrow: C9 · Lesson 8 · What the impulse response tells you
xp: 40
---

::: hook
Since an LTI system is completely described by its impulse response, every question about the system is really a question about h. Can it react before the input arrives? Look at h for negative time. Can it blow up? Add up the size of h. Can its effect be undone, as when a phone cancels an echo? Find another impulse response that convolves with h to give back an impulse. And two systems connected in a chain or side by side are just one new impulse response. This lesson turns each property into a test you can run on h.
:::

::: play
- The stems are the impulse response $h[n] = a^n u[n]$; the second set is the step response s[n], its running sum.
- For |a| < 1, h dies away and s levels off at $1/(1 - a)$: the system is stable.
- Push a to 1 or beyond: s grows without limit, even though the input, a step, is bounded. With a negative, h alternates and s settles by oscillating.
:::
:::

```sim plot
view: graph
x: n = 0..30
y: v = -3..6
slider: a = -1.1..1.1 = 0.7 step 0.05
plot: a^n | stems | label: h[n]
plot: (1 - a^(n + 1))/(1 - a + 0.0000001) | stems | label: s[n]
readout: sum of |h| (if |a| < 1) = 1/(1 - abs(a)) | digits: 4
readout: final step response (if |a| < 1) = 1/(1 - a) | digits: 4
```

::: predict
## $h[n] = \frac{1}{n + 1}u[n]$ dies away to zero. Is the system BIBO stable?

- [ ] Yes, because h goes to zero
- [x] No, because the sum of |h| grows without limit
- [ ] Yes, because h is never negative
- [ ] It can't be decided from h

::: reveal
No. $\sum 1/(n + 1)$ is the harmonic series, which grows without bound (like ln n). Feed in a step and the output is that sum, growing forever. Dying away isn't enough: h has to die away fast enough for its total size to be finite.
:::
:::

::: nameit
## Properties from h

| Property | Test on h |
|---|---|
| memoryless | $h = K\delta$ |
| causal | $h(t) = 0$ for t < 0 (h[n] = 0 for n < 0) |
| BIBO stable | $\int \lvert h(t)\rvert\,dt < \infty$ (or $\sum \lvert h[n]\rvert < \infty$) |
| invertible | some $h_\text{inv}$ has $h * h_\text{inv} = \delta$ |

If $\lvert x\rvert \le M$, then $\lvert y\rvert \le M\sum\lvert h\rvert$, which is why a finite sum of |h| guarantees stability. Useful sums: $\sum_{n \ge 0} \lvert a\rvert^n = 1/(1 - \lvert a\rvert)$ and $\sum_{n \ge 0} n a^n = a/(1 - a)^2$ for |a| < 1.

## Step response

The step response is the running sum (or integral) of h, so h is the step response's difference (or derivative): $h[n] = s[n] - s[n - 1]$, $h(t) = s'(t)$. Measuring a step response in the lab is often easier than producing an impulse, and gives h the same way.

## Connecting systems

- **Cascade** (one after the other): $h = h_1 * h_2$, in either order.
- **Parallel** (same input, outputs added): $h = h_1 + h_2$.
- **Inverse:** an echo $h[n] = \delta[n] + a\,\delta[n - D]$ is undone by $h_\text{inv}[n] = \sum_{k \ge 0} (-a)^k\delta[n - kD]$, which subtracts the echo, then the echo of the subtraction, and so on. It's stable only for |a| < 1.
:::

::: example
## Is $h[n] = n(0.5)^n u[n]$ stable?

::: solution
1. **Sum the response.**
   $$\begin{aligned} \sum n(0.5)^n &= \frac{0.5}{(1 - 0.5)^2} \\ &= 2 \end{aligned}$$
   That's finite, so the system is stable.
2. **Why it still decays.** The factor n makes h rise at first (h[1] = h[2] = 0.5), but the exponential wins.

**Answer:** yes, it's stable: the sum comes to 2.
:::
:::

::: example
## Find the inverse of the echo $y[n] = x[n] + 0.5\,x[n - 3]$.

::: solution
1. **Write the inverse.** Each term cancels the echo the previous one created:
   $$\begin{aligned} h_\text{inv}[n] &= \delta[n] - 0.5\,\delta[n - 3] \\ &\quad + 0.25\,\delta[n - 6] \\ &\quad - 0.125\,\delta[n - 9] + \cdots \end{aligned}$$
2. **Stability.** With |0.5| < 1 the terms shrink and the inverse is stable.
3. **The limit.** An echo as loud as the original (a = 1) couldn't be canceled this way.

**Answer:** the inverse is $\delta[n] - 0.5\,\delta[n - 3] + 0.25\,\delta[n - 6] - \cdots$, a stable train of shrinking echoes.
:::
:::

::: example
## A system's step response is $s[n] = 2 - 0.5^n$ for n ≥ 0 (and 0 before). Find its impulse response.

::: solution
1. **Impulse from steps.** The impulse is a step minus a delayed step, so
   $$h[n] = s[n] - s[n - 1]$$
2. **At n = 0.**
   $$\begin{aligned} h[0] &= 2 - 1 \\ &= 1 \end{aligned}$$
3. **For n ≥ 1.**
   $$\begin{aligned} h[n] &= (2 - 0.5^n) \\ &\quad - (2 - 0.5^{n-1}) \\ &= 0.5^{n-1} - 0.5^n \\ &= 0.5^n \end{aligned}$$
4. **Check.** So $h[n] = 0.5^n u[n]$, whose sum, 2, is where the step response settles.

**Answer:** $h[n] = 0.5^n u[n]$.
:::
:::

::: check
given: a = 0.5 | -0.6 | 0.8 | -0.9
answer: 1/(1 - abs(a))
tolerance: 0.5%

## What is $\sum_n \lvert h[n]\rvert$ for $h[n] = (\given{a})^n u[n]$?

::: right
Right. A geometric series in |a|: {answer}, so the system is stable.
:::

::: misses
- [any] Not yet. $\sum \lvert a\rvert^n = 1/(1 - \lvert a\rvert)$.
:::
:::

::: check
given: a = 0.25 | 0.6 | 0.8
answer: a/(1 - a)^2
tolerance: 0.5%

## What is $\sum_n \lvert h[n]\rvert$ for $h[n] = n(\given{a})^n u[n]$?

::: right
Right. $a/(1 - a)^2$ = {answer}: finite, so stable.
:::

::: misses
- [1/(1 - a)] That's for $a^n$ alone; the factor n changes the sum.
- [any] Not yet. $\sum n a^n = a/(1 - a)^2$.
:::
:::

::: check
kind: parts
given: a = 0.3 | 0.5 | 0.9; D = 2 | 4 | 10

## An echo system is $h[n] = \delta[n] + \given{a}\,\delta[n - \given{D}]$.

::: part
answer: a^2
tolerance: 0.5%

### What is its inverse's sample at n = 2 × {D}?

::: misses
- [-a^2] Each step multiplies by −a; two steps give $+a^2$.
- [any] Not yet. $(-a)^k$ at n = kD, with k = 2.
:::
:::

::: part
answer: -a
tolerance: 0.5%

### What is the inverse's sample at n = {D}?

::: misses
- [a] The inverse subtracts the echo.
- [any] Not yet. $(-a)^1$.
:::
:::
:::

::: check
kind: parts
given: L = 4 | 10; M = 3 | 8; g1 = 1 | 2; g2 = 0.5 | 3

## Two FIR systems are cascaded: the first has {L} samples summing to {g1}, the second {M} samples summing to {g2}.

::: part
answer: L + M - 1
tolerance: 0

### How many samples long is the combined impulse response?

::: misses
- [any] Cascades convolve, and lengths add less one.
:::
:::

::: part
answer: g1*g2
tolerance: 0.5%

### What do its samples sum to?

::: misses
- [g1 + g2] That would be a parallel connection. A cascade's sums multiply.
- [any] Not yet. Sums multiply under convolution.
:::
:::
:::

::: check
given: s0 = 0.2 | 1; s1 = 0.7 | 1.5; s2 = 0.9 | 2.4
answer: s2 - s1
tolerance: 0.5%

## A causal system's step response begins s[0] = {s0}, s[1] = {s1}, s[2] = {s2}. What is h[2]?

::: right
Right. $h[n] = s[n] - s[n - 1]$ = {answer}.
:::

::: misses
- [s2] The step response is the running sum of h; difference it to get h.
- [s2 - s0] Take the difference of neighboring samples.
- [any] Not yet. s[2] − s[1].
:::
:::

::: check
given: A = 2 | 5; tau = 0.01 | 0.5; M = 1 | 10
answer: M*A*tau
tolerance: 0.5%

## A system has $h(t) = \given{A}e^{-t/\given{tau}}u(t)$. If $\lvert x(t)\rvert \le \given{M}$, what is the largest $\lvert y(t)\rvert$ can be?

::: right
Right. $M\int\lvert h\rvert = MA\tau$ = {answer}.
:::

::: misses
- [M*A] Multiply by the area of h, which includes τ.
- [any] Not yet. M times $\int_0^\infty Ae^{-t/\tau}dt$.
:::
:::

::: check
kind: choice

## Which impulse response belongs to a causal, stable system?

- [ ] $h(t) = e^{-\lvert t\rvert}$
- [x] $h(t) = te^{-t}u(t)$
- [ ] $h(t) = u(t)$
- [ ] $h[n] = 2^n u[n]$

::: misses
- [1] It's nonzero for t < 0, so the system responds before the impulse arrives: not causal.
- [3] Its integral grows without bound: an integrator isn't stable.
- [4] It grows: not stable.
:::
:::

::: check
kind: parts
given: a = -0.5 | -0.6 | -0.9 | -0.95

## An LTI system has $h[n] = a^n u[n]$ with a = {a}.

::: part
answer: 1/(1 - abs(a))
tolerance: 0.5%

### What is $\sum\lvert h[n]\rvert$?

::: misses
- [1/(1 - a)] Take absolute values: the signs alternate when a < 0.
- [any] A geometric sum of $\lvert a\rvert^n$.
:::
:::

::: part
answer: 1/(1 - a)
tolerance: 0.5%

### What is its step response's final value?

::: misses
- [any] The sum of h, signs included.
:::
:::
:::

::: check
kind: parts
given: b = 0.5 | -1 | 2; c = 0.25 | 3

## Two FIR filters, $h_1 = [1, \given{b}]$ and $h_2 = [1, \given{c}]$, are in cascade.

::: part
answer: b + c
tolerance: 0.5%

### What is h[1] of the combination?

::: misses
- [any] Convolve: the middle term is b + c.
:::
:::

::: part
answer: b*c
tolerance: 0.5%

### And h[2]?

::: misses
- [any] The product of the end terms.
:::
:::
:::

::: explain
## Why is "the sum of |h| is finite" exactly the condition for every bounded input to give a bounded output?

::: model
If the sum is finite, any input bounded by M gives an output bounded by M times that sum, since each output sample is a weighted sum of inputs with weights h, and the worst case is every input lined up with the sign of its weight. Conversely, if the sum is infinite, choose the input to be ±1 matching the sign of $h[n - k]$ at each k: it's bounded, yet at that n the output equals the sum of |h|, which is as large as you like. So a finite sum is both enough and necessary.
:::
:::

::: practice

::: check
given: a = -0.9 | -0.7 | -0.5 | -0.2 | 0.25 | 0.4 | 0.6 | 0.8
answer: 1/(1 - abs(a))
tolerance: 0.5%

## $\sum\lvert h\rvert$ for $h[n] = (\given{a})^n u[n]$?

::: misses
- [any] $1/(1 - \lvert a\rvert)$.
:::
:::

::: check
given: s1 = 0.5 | 2; s2 = 1.2 | 3.5
answer: s2 - s1
tolerance: 0.5%

## s[1] = {s1} and s[2] = {s2}. What is h[2]?

::: misses
- [any] Difference the step response.
:::
:::

::: check
given: a = 0.6 | 0.8; D = 3 | 5
answer: -a
tolerance: 0.5%

## The echo $\delta[n] + \given{a}\delta[n - \given{D}]$ is inverted. What is the inverse at n = {D}?

::: misses
- [any] The first correction subtracts the echo.
:::
:::
:::
