# Control systems and convolution

I think i am not understanding the concept of convolution well.

Lets say we are given a system impulse response in the S-domain, and we have implemented a controller $G_c(s)$ that will adjust the system response to some kind of input. Now when we are implementing this controller say using an operational amp. circuit all we need to do is to get the differential equation of $G_c(s)$ and start implementing it with the correct component values. Is this correct?

And if so, lets say we are trying to implement this controller on a computer, where our inputs, outputs are no longer continuous signals. And our controller in the Z-domain is represented by $G_c(z)$. Now the next step to implement this controller in a computer is to get the difference equation and implement it in a software. Is this correct?

And if so, what is the difference between implementing the controller difference equation on a software and implementing the convolution algorithm on the software?

For example if we are given g[n] as an array of samples representing the the controller unit impulse response, and our input is stored inside x[n] a simple for loop might do this algorithm for us. As far as i know

for i in len(x):      #loop through the input elements
for j in len(g):     #loop through the controller unit impulse response elements
y[i+j] += x[i]*g[j]  #Store the conv. result in the output array y


Which is just telling the software to scale every point in the impulse response by x[n] and then shift the response by n, then add them all up.

I am probably missing something here !