# Graphical DT Convolution

Attached is the question 1 part B, solution and my attempt. My attempt seems to be not correct. can someone comment?

• I'm not familiar with your notation, but you seem to have calculated the cross correlation instead of the convolution. So, mirror $h(n)$ and try again. – Max Apr 2 at 6:11
• There are two methods to do DT Convolutions: graphical method of flip & slide. The other is demonstrated above which is numerically for short sequences. – Leo Apr 2 at 6:15
• Ok, now I see what you did there. The mistake is that you kind of "wrapped around" $h(n)$. This is wrong. Do not wrap it around, shift it in a linear way and zero-pad it. E.g. the second line of your equation for $y(n)$ should be $\{-1\}\{0,0,0,-1,2,1\} + \{0\}\{0,0,0,0,-1,2,1\}$. Then you should obtain the correct result. – Max Apr 2 at 6:54

What you did there is a kind of circular convolution, where you thought of the impulse response $$h(t)$$ as periodic, i.e. the system triggered by $$\delta(0)$$ would oscillate until infinity. The periodicity is represented by your "wrapping around" the impulse response. The output you calculated is actually just one period of the output signal.
This is different from the linear convolution that the task formulation obviously expects to be applied here. With the linear convolution, the impulse response is thought to be the graph representing $$h(n)$$ padded by zeros from $$-\infty$$ to $$0$$ and from $$3$$ to $$\infty$$. Here, if the system is triggered by $$\delta(0)$$, you would get $$h(n)$$ and then all zeros to infinity.
• There is not really a size, as both the signal an the impulse response go from $-\infty$ to $+\infty$ but I see what you mean. The maximum distance between two non-zero samples in the output signal will be the same distances of both input and response added minus one. – Max Apr 4 at 6:28