Skip to main content

Graphical convolution of two rectangles

Short answer

Graphical convolution of two length-3 pulses (from −1 to 1) gives a triangular output: y[n] = {1,2,3,2,1} for n=−2,…,2. The sum of products of overlapped samples yields maximum 3 at n=0.

A discrete time LTI system has input signal x[n] = 1 for −1 ≤ n ≤ 1 (0 elsewhere) and impulse response h[n] = 1 for −1 ≤ n ≤ 1 (0 elsewhere). Find the output of the system using the graphical method.

The output is the convolution sum y[n] = Σ x[k] h[n − k].

Signals: x[k] = 1 for k = −1, 0, 1; h[k] = 1 for k = −1, 0, 1.

Graphical method:

  1. Plot x[k] and h[k] against k.
  2. Fold h[k] about k = 0 to get h[−k] (here it is symmetric, so it is unchanged).
  3. Shift it by n to get h[n − k].
  4. Multiply x[k] · h[n − k] point by point and add all the products. This sum is y[n].
  5. Slide (change n) and repeat.

h[n − k] is non-zero for k = n − 1, n, n + 1. Overlap with x[k] (k = −1 … 1):

nNon-zero h[n−k] at kOverlap with xy[n]
≤ −3n−1 … n+1none0
−2−3, −2, −1k = −11
−1−2, −1, 0k = −1, 02
0−1, 0, 1k = −1, 0, 13
10, 1, 2k = 0, 12
21, 2, 3k = 11
≥ 3–none0
 y[n]
  3 |          o
  2 |       o  |  o
  1 |    o  |  |  |  o
  0 +-o--+--+--+--+--+--o-- n
     -3 -2 -1  0  1  2  3

Answer: y[n] = {1, 2, 3, 2, 1} for n = −2 … 2 (the bold centre sample 3 is at n = 0).

Check: Σy = 9 = (Σx)(Σh) = 3 × 3. The output length is 3 + 3 − 1 = 5.

✓ Answer checked by Claude Opus 5.5 (high effort)

All Digital Signal Analysis and Processing chapter 1 questions →