Impulse Responses and Convolutions

The Sifting or Sampling Property

Summary: The sifting property states that we can represent any signal as a weighted sum of shifted impulses,

    \[x[n] = \sum_{m=-\infty}^{\infty} x[m] \delta[n - m]\]

Step 1: Multiplication of Signal and Impulse

First, consider we multiply a signal x[n] by shifted impulse \delta[n-N], then

    \[x[n] \, \delta[n-N] = x[N] \, \delta[n-N] .\]

We get this result because \delta[n-N] is zero everywhere except at time n = N. Therefore, only the value at x[N] is expressed in the signal.

Step 2: Express a Constant as Shifted Impulses

Second, consider the sum of shifted impulses

    \[\sum_{m=-\infty}^{\infty} \delta[n-m] = 1 .\]

We get this result because we shift an impulse (with amplitude of 1) to every time location and then sum all of the impulses together to get 1’s everywhere.

Step 3: Express Any Signal as Shifted Impulses

We can combine the two results above to get

x[n] = x[n] (1)

x[n] &= x[n] \sum_{m=-\infty}^{\infty} \delta[n-m]

x[n] &= \sum_{m=-\infty}^{\infty} x[n] \delta[n - m]

x[n] &= \sum_{m=-\infty}^{\infty} x[m] \delta[n - m]

Hence, we sample x[n] at every n = m and then sum the samples together to get back x[n]. This is known as the sifting property or the sampling property of an impulse function.

At first glance, this may seem like an exercise in tautology. However, this property is key to understanding linear, time-invariant (LTI) systems.

Deriving the Impulse Response

Summary: The output of any linear, time-invariant (LTI) systems can be expressed as a weighted sum of shifted impulse responses (the system’s output with an impulse input). The weights and shifts are determined by the inputs values,

    \[y[n] = \sum_{m=-\infty}^{\infty} x[m] h[n - m] = x[n] * h[n]\]

Step 1: Start with a time-invariant system

Let the input to a time-invariant system \mathcal{H}\{ \cdot \} be an impulse \delta[n]. Due to time-invariance, we know that delaying or advancing the impulse will delay or advance the output h[n]. Hence, we can say

    \[\mathcal{H}\{ \delta[n + m] \} = h[n + m] \; .\]

Step 2: Add linearity

To now continue to consider the time-invariant system \mathcal{H}\{ \cdot \} discussed in the previous subsection. If this system is also linear, we will know what output to expect from a sum of two or more different \delta inputs. For example, for the input signal x[n] = x[m_1] \delta[n - m_1] + x[m_2] \delta[n - m_2], the output response would be

\mathcal{H}\{ x[n] \} = \mathcal{H}\{ x[m_1] \delta[n - m_1] + x[m_2] \delta[n - m_2] \}
\mathcal{H}\{ x[n] \} = \mathcal{H}\{ x[m_1] \delta[n - m_1] \} + \mathcal{H}\{ x[m_2] \delta[n - m_2] \} \quad (\textrm{due to linearity})
\mathcal{H}\{ x[n] \} = x[m_1] \mathcal{H}\{ \delta[n - m_1] \} + x[m_2] \mathcal{H}\{ \delta[n - m_2] \} \quad (\textrm{due to linearity})
\mathcal{H}\{ x[n] \} = x[m_1] \, h[n - m_1] + x[m_2] \, h[n - m_2] \; .

Step 3: Extend with the sampling property

In the previous subsection, we showed that linearity allowed us to determine the output from a sum of two different \delta functions. We can extend this idea to a sum of any number of delta functions. Furthermore, the sampling property tells us that we can represent any signal x[n] as an infinite sum of amplified delta functions. So, if we now let x[n] be the input to the linear, time-invariant (LTI) system \mathcal{H}\{ \cdot \}, we get

\mathcal{H} \left\{ x[n] \right\} = \mathcal{H} \left\{ \sum_{m=-\infty}^{\infty} x[m] \delta[n - m] \right\}
\mathcal{H} \left\{ x[n] \right\} = \sum_{m=-\infty}^{\infty} x[m] \mathcal{H} \left\{ \delta[n - m] \right\} \quad (\textrm{due to linearity})
\mathcal{H} \left\{ x[n] \right\} = \sum_{m=-\infty}^{\infty} x[m] h[n - m]
\mathcal{H} \left\{ x[n] \right\} = x[n] * h[n]

The result of these steps is known as the convolution sum. To find the output, we need to know the input signal x[n] and and the impulse response h[n]. The function h[n] is the response of the system to an single impulse input at time t=0, i.e., \delta[n].

If an impulse response of a system is infinite in duration, we refer to it as an infinite impulse response system. If an impulse response of a system is finite in duration, we refer to it as a finite impulse response system.

Convolution properties

Commutativity: x[n] * h[n] = h[n] * x[n]

Associativity: g[n] * \left(x[n] * h[n] \right) = \left(g[n] * x[n] \right) * h[n]

Distributivity: g[n] * \left(x[n] + h[n] \right) = g[n] * x[n] + g[n] * h[n]

Associativity with scalar multiplication: a \left( x[n] * h[n] \right) = \left( a x[n] \right) * h[n]

Multiplicative identity: x[n] * \delta[n] = x[n]

Graphically understanding convolution

Convolution can be seen as a graphical process:

  1. Plot x[m] with dependent variable m
  2. Plot h[-m] with dependent variable m (h reflected around m=0).
  3. Plot h[n-m] with dependent variable m (n can shift h[n-m] from -\infty (all the way to the left) to \infty (all the way to the right).
  4. For each shift (i.e. n), compute y[n] = \sum_{m=-\infty}^{\infty} x[m] h[n-m] (i.e., multiply x[m] h[n-m] and then sum the result).

Graphical Convolution Examples

Solving the convolution sum for discrete-time signal can be a bit trickier than solving the convolution integral. As a result, we will focus on solving these problems graphically. Below is a collection of graphical examples of discrete-time convolution.

Box and an impulse

x[n] = u[n] - u[n-3]
h[n] = \delta[n - 2]
y[n] = x[n] * h[n]

An animation of a convolution between a box and a shifted impulse
An animation of a convolution between a box and a shifted impulse

Two boxes

x[n] = u[n] - u[n-3]
h[n] = u[n] - u[n-3]
y[n] = x[n] * h[n]

An animation of a convolution between two boxes
An animation of a convolution between two boxes

Box and exponential

x[n] = u[n] - u[n-3]
h[n] = e^{(-1/2) n} u[n]
y[n] = x[n] * h[n]

An animation of a convolution between a box and exponential.
An animation of a convolution between a box and exponential.

Two exponentials

x[n] = e^{(-1/2) n} u[n]
h[n] = e^{(-1/2) n} u[n]
y[n] = x[n] * h[n]

An animation of a convolution between two exponentials.
An animation of a convolution between two exponentials.

Finite Ramp and Box

x[n] = \delta[n-1] + 2 \delta[n-2]
h[n] = u[n] - u[n-3]
y[n] = x[n] * h[n]

An animation of a convolution between a ramp and box.
An animation of a convolution between a ramp and box.

Random Numbers and Box

x[n] = random signal
h[n] = u[n] - u[n-3]
y[n] = x[n] * h[n]

An animation of a convolution between random numbers and a box.
An animation of a convolution between random numbers and a box.

Step function and an exponential

x[n] = u[n]
h[n] = e^{(-1/2) n} u[n]
y[n] = x[n] * h[n]

An animation of a convolution between a step function and a exponential.
An animation of a convolution between a step function and a exponential.

Step function and a box

x[n] = u[n]
h[n] = u[n] - u[n-2]
y[n] = x[n] * h[n]

An animation of a convolution between a step function and a box.