---
title: Systems and their properties
heading: Memory, causality, stability, linearity and time invariance
eyebrow: C9 · Lesson 4 · Systems and their properties
xp: 40
---

::: hook
A system is anything that turns one signal into another: an amplifier, a filter, a room's echo, a line of code that averages the last ten samples. Before computing anything about a system, it pays to ask a few yes-or-no questions about it. Does it remember the past? Can it react to the future? Does a small input always give a small output? Does doubling the input double the output? Does it behave the same today as tomorrow? The last two, **linearity** and **time invariance**, are the ones that matter most, because a system that has both is completely described by a single signal, as the next lessons show.
:::

::: play
- The dashed pulse is the input x(t), centered at t = d. Two systems act on it: $y_1(t) = x^2(t)$ and $y_2(t) = t\,x(t)$.
- Slide the pulse with d. The output of $x^2$ keeps the same shape and just moves along with the input: that system is time invariant.
- The output of $t\,x(t)$ changes as the pulse moves: small near t = 0, bigger further out, upside down for negative t. The same input at a different time gives a different output: that system is time varying.
:::
:::

```sim plot
view: graph
x: t = -6..6
y: y = -4..4
slider: d = -5..5 = 2 step 0.1
plot: exp(-(t - d)^2) | dashed | label: x(t)
plot: exp(-2*(t - d)^2) | label: x²(t)
plot: t*exp(-(t - d)^2) | label: t·x(t)
readout: peak of x² = 1 | digits: 3
readout: t·x(t) at the pulse's center = d | digits: 3
```

::: predict
## Is the system $y(t) = x(t) + 1$ linear?

- [ ] Yes: it's a straight line
- [x] No: zero input gives a nonzero output
- [ ] Yes, but only for positive inputs
- [ ] It depends on the input's frequency

::: reveal
No. A linear system must give zero output for zero input (scale any input by 0), and this one gives 1. It's **incrementally linear**: a linear system plus a constant. Changes in the output are proportional to changes in the input, but superposition fails: the response to $x_1 + x_2$ is not the sum of the responses.
:::
:::

::: nameit
## The properties

| Property | Meaning | Fails for |
|---|---|---|
| memoryless | y at time t depends only on x at time t | $y(t) = x(t - 1)$ |
| causal | y at time t depends only on x at times ≤ t | $y[n] = x[n + 1]$ |
| stable (BIBO) | every bounded input gives a bounded output | the accumulator $y[n] = \sum_{k \le n} x[k]$ |
| invertible | different inputs give different outputs | $y(t) = x^2(t)$ |
| linear | $a x_1 + b x_2 \to a y_1 + b y_2$ | $y(t) = x(t) + 1$, $y = x^2$ |
| time invariant | $x(t - t_0) \to y(t - t_0)$ | $y(t) = t\,x(t)$, $y(t) = x(2t)$ |

## Testing them

- **Linearity:** find the outputs $y_1$ and $y_2$ for two inputs, then the output for $ax_1 + bx_2$, and see whether it equals $ay_1 + by_2$. A quick screen: zero in must give zero out.
- **Time invariance:** compare two things: the output for the shifted input $x(t - t_0)$, and the original output shifted, $y(t - t_0)$. A system whose formula has t (or n) in it outside the input, or that scales time, usually fails.
- **Stability:** look for one bounded input with an unbounded output. The accumulator fed a step grows without limit: $y[n] = n + 1$.

A system that is both linear and time invariant is **LTI**. Most of this course is about LTI systems: circuits of R, L, C and op amps, and digital filters, are all LTI.
:::

::: example
## Classify $y(t) = x(2t)$.

::: solution
1. **Linear.** Scaling or adding inputs scales or adds the output.
2. **Time varying.** Shifting the input by $t_0$ gives $x(2t - t_0)$, but shifting the output gives
   $$\begin{aligned} y(t - t_0) &= x(2(t - t_0)) \\ &= x(2t - 2t_0) \end{aligned}$$
   and the two differ.
3. **Not causal.** y(1) = x(2) needs the future.
4. **Memory and stability.** It has memory, and it's stable (it only rearranges values).
5. **Invertible.** Undo the compression:
   $$x(t) = y(t/2)$$

**Answer:** linear, time varying, not causal, with memory, stable and invertible.
:::
:::

::: example
## Classify $y[n] = x[n] - x[n - 1]$.

::: solution
1. **Linear and time invariant.** It uses only shifts of x, with fixed coefficients.
2. **Causal, with memory.** It uses the present and one past sample.
3. **Stable.**
   $$\lvert y\rvert \le 2\max\lvert x\rvert$$
4. **Invertible.** The accumulator undoes it, if x started at zero:
   $$x[n] = \sum_{k \le n} y[k]$$

**Answer:** linear, time invariant, causal, with memory, stable and invertible.
:::
:::

::: example
## Classify $y(t) = x(t)\cos(\omega_0 t)$, the mixer at the heart of every radio.

::: solution
1. **Linear.** Scaling or adding inputs does the same to the output.
2. **Time varying.** A delayed input meets a different part of the cosine.
3. **Causal and memoryless.** y(t) uses only x(t).
4. **Stable.**
   $$\lvert y\rvert \le \lvert x\rvert$$
5. **Not invertible.** Wherever the cosine is 0 the input is lost.
6. **Why it matters.** A linear but time-varying system is exactly what's needed to move a signal to a new frequency, which no LTI system can do.

**Answer:** linear, time varying, causal, memoryless and stable, but not invertible.
:::
:::

::: check
kind: parts
given: a = 2 | 3 | -1; b = 1 | 4; p = 3 | 5; q = 2 | 7

## A system is $y = \given{a}x + \given{b}$.

::: part
answer: a*(p + q) + b
tolerance: 0.5%

### What is the output when x = {p} + {q}?

::: misses
- [any] Put the sum into the formula.
:::
:::

::: part
answer: a*p + b + a*q + b - (a*(p + q) + b)
tolerance: 0.5%

### By how much does the sum of the outputs for x = {p} and x = {q} differ from that?

::: misses
- [0] It would be 0 for a linear system. Here the constant appears twice in the sum but once in the single response.
- [any] Not yet. Compute both outputs separately and add.
:::
:::
:::

::: check
given: N = 9 | 20 | 99
answer: N + 1
tolerance: 0

## The accumulator $y[n] = \sum_{k=-\infty}^{n} x[k]$ is fed the unit step u[n]. What is y[{N}]?

::: right
Right. N + 1, and it keeps growing: a bounded input with an unbounded output, so the accumulator isn't BIBO stable.
:::

::: misses
- [N] Count n = 0 too.
- [any] Not yet. Add up the ones from 0 to {N}.
:::
:::

::: check
given: k = 2 | 5 | 9
answer: k
tolerance: 0

## The system $y[n] = n\,x[n]$ is fed $\delta[n - \given{k}]$. What is the output's only nonzero sample?

::: right
Right. $k\,\delta[n - k]$: the size depends on when the impulse arrives, so the system is time varying.
:::

::: misses
- [1] The impulse's height is multiplied by the time it arrives.
- [any] Not yet. Evaluate n x[n] at n = {k}.
:::
:::

::: check
given: M = 1 | 2 | 5; a = 0.5 | 0.8 | -0.9
answer: M/(1 - abs(a))
tolerance: 0.5%

## An LTI system has impulse response $h[n] = (\given{a})^n u[n]$. If $\lvert x[n]\rvert \le \given{M}$ always, what is the largest $\lvert y[n]\rvert$ can be?

::: right
Right. $M\sum\lvert h\rvert = M/(1 - \lvert a\rvert)$ = {answer}.
:::

::: misses
- [M] The output adds up many past inputs.
- [any] Not yet. $M \sum \lvert h[n]\rvert$.
:::
:::

::: check
kind: choice

## Which system is causal?

- [ ] $y[n] = x[n + 1]$
- [ ] $y(t) = x(2t)$
- [x] $y[n] = \frac{1}{3}(x[n] + x[n - 1] + x[n - 2])$
- [ ] $y(t) = x(-t)$

::: misses
- [1] It needs the next sample, which hasn't arrived.
- [2] At t = 1 it needs x(2).
- [4] At t = −1 it needs x(1), the future.
:::
:::

::: check
kind: choice

## Which system is linear and time invariant?

- [ ] $y(t) = x^2(t)$
- [ ] $y(t) = \cos(t)\,x(t)$
- [x] $y(t) = 3x(t - 2)$
- [ ] $y(t) = x(t) + 1$

::: misses
- [1] Doubling the input quadruples the output: nonlinear.
- [2] Linear, but cos(t) changes with time: a shifted input meets a different multiplier.
- [4] Zero in gives 1 out: not linear.
:::
:::

::: check
kind: choice

## Which system is not invertible?

- [ ] $y(t) = 5x(t)$
- [ ] $y(t) = x(t - 3)$
- [x] $y(t) = \lvert x(t)\rvert$
- [ ] $y(t) = x(t) + 2$

::: misses
- [1] Divide by 5.
- [2] Shift back by 3.
- [4] Subtract 2.
:::
:::

::: check
kind: parts
given: a = 1 | 2 | 5; g = 2 | 3

## A system computes $y = \given{g}x + 3$. Test it with the inputs x = {a} and x = 2 × {a}.

::: part
answer: g*a + 3
tolerance: 0

### What is y for x = {a}?

::: misses
- [any] Substitute.
:::
:::

::: part
answer: 2*g*a + 3
tolerance: 0

### What is y for x = 2 × {a}? (Doubling the input doesn't double the output, so the system isn't linear.)

::: misses
- [2*(g*a + 3)] That's what a linear system would give; this one doesn't.
- [any] Substitute 2 × {a}.
:::
:::
:::

::: check
kind: parts
given: b = 0.5 | 0.8 | 0.9; K = 2 | 3 | 5

## $y[n] = \sum_{k=0}^{\given{K}} b^k x[n - k]$ with b = {b} and K = {K}, and the input stays within ±1.

::: part
answer: (1 - b^(K + 1))/(1 - b)
tolerance: 0.5%

### What is the largest the output can be?

::: misses
- [1/(1 - b)] The sum stops at k = {K}.
- [any] Every input at +1: a finite geometric sum.
:::
:::

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

### What would the bound be if the sum ran forever?

::: misses
- [any] The infinite geometric sum.
:::
:::
:::

::: explain
## Why is $y(t) = x(2t)$ time varying, even though its formula has no t outside the input?

::: model
Time invariance asks whether delaying the input just delays the output by the same amount. Delay the input by $t_0$ and the system produces $x(2t - t_0)$. Delaying the original output by $t_0$ instead gives $x(2(t - t_0)) = x(2t - 2t_0)$. The two differ by $t_0$, because the system squeezes time: a delay at the input becomes only half as long at the output. So a shift doesn't pass through unchanged, and the system is time varying.
:::
:::

::: practice

::: check
given: N = 4 | 15 | 49
answer: N + 1
tolerance: 0

## An accumulator starting at zero is fed u[n]. What is its output at n = {N}?

::: misses
- [any] The count of ones from 0 to {N}.
:::
:::

::: check
given: M = 1 | 3; a = 0.6 | -0.75
answer: M/(1 - abs(a))
tolerance: 0.5%

## $h[n] = (\given{a})^n u[n]$ and $\lvert x\rvert \le \given{M}$. What bound holds on $\lvert y\rvert$?

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

::: check
given: a = 2 | 5; b = 3 | 1; p = 1 | 4; q = 2 | 6
answer: b
tolerance: 0.5%

## For $y = \given{a}x + \given{b}$, by how much does $y(p) + y(q) - y(p + q)$ miss zero (p = {p}, q = {q})?

::: misses
- [any] The constant is counted once too often.
:::
:::
:::
