Skip to main content

Convolve {1,2,1,−1} and {1,2,3,1}

Short answer

With x₁[-1]=1,x₁[0]=2 and x₂[0]=1, tabular convolution yields y[n]={1,4,8,8,3,-2,-1} with y[0]=4, for -1≤n≤5.

Perform convolution between signals: x₁[n] = {1, 2, 1, −1} with origin at second position from left and x₂[n] = {1, 2, 3, 1} with origin at first position from left.

Given (origin marked):

  • x1[n]={1,2↑,1,−1}x_1[n] = \{1, \underset{\uparrow}{2}, 1, -1\}, so x1[−1]=1x_1[-1] = 1, x1[0]=2x_1[0] = 2, x1[1]=1x_1[1] = 1, x1[2]=−1x_1[2] = -1 (−1≤n≤2-1 \le n \le 2).
  • x2[n]={1↑,2,3,1}x_2[n] = \{\underset{\uparrow}{1}, 2, 3, 1\}, so 0≤n≤30 \le n \le 3.
y[n]=x1[n]∗x2[n]=∑kx1[k] x2[n−k]y[n] = x_1[n]*x_2[n] = \sum_k x_1[k]\,x_2[n-k]

Output range: start =−1+0=−1= -1 + 0 = -1; length =4+4−1=7= 4 + 4 - 1 = 7; so −1≤n≤5-1 \le n \le 5.

Tabular method

Each row is one sample of x1x_1 times x2x_2 shifted to that sample's position:

Rown=−1n=-1n=0n=0n=1n=1n=2n=2n=3n=3n=4n=4n=5n=5
x1[−1] x2[n+1]x_1[-1]\,x_2[n+1]1231
x1[0] x2[n]x_1[0]\,x_2[n]2462
x1[1] x2[n−1]x_1[1]\,x_2[n-1]1231
x1[2] x2[n−2]x_1[2]\,x_2[n-2]-1-2-3-1
y[n]y[n]14883-2-1

Direct check of some values

  • y[−1]=x1[−1]x2[0]=1y[-1] = x_1[-1]x_2[0] = 1
  • y[0]=x1[−1]x2[1]+x1[0]x2[0]=2+2=4y[0] = x_1[-1]x_2[1] + x_1[0]x_2[0] = 2 + 2 = 4
  • y[1]=1(3)+2(2)+1(1)=8y[1] = 1(3) + 2(2) + 1(1) = 8
  • y[2]=1(1)+2(3)+1(2)+(−1)(1)=8y[2] = 1(1) + 2(3) + 1(2) + (-1)(1) = 8
  • y[3]=2(1)+1(3)+(−1)(2)=3y[3] = 2(1) + 1(3) + (-1)(2) = 3
  • y[4]=1(1)+(−1)(3)=−2y[4] = 1(1) + (-1)(3) = -2
  • y[5]=(−1)(1)=−1y[5] = (-1)(1) = -1

Sum check: (∑x1)(∑x2)=3×7=21(\sum x_1)(\sum x_2) = 3 \times 7 = 21, and 1+4+8+8+3−2−1=211 + 4 + 8 + 8 + 3 - 2 - 1 = 21.

Answer:

y[n]={1, 4↑, 8, 8, 3, −2, −1}y[n] = \{1,\ \underset{\uparrow}{4},\ 8,\ 8,\ 3,\ -2,\ -1\}

for −1≤n≤5-1 \le n \le 5 (the arrow marks n=0n = 0, so y[0]=4y[0] = 4).

✓ Answer checked by Claude Opus 5.5 (high effort)

All Signals and Systems chapter 6 questions →