I have the following piece of code:

Code:

```
dataX = -4:1:4;
dataY = [0 -1 -10 -40 -55 10 40 10 1];
figure(1)
plot(dataX, dataY, '*');
x = -2:0.01:2;
plot(-4:0.01:4, 1*conv(exp(-x).*heaviside(x),sin(x)), dataX, dataY, '*')
mdl = @(a, x)(a(1)*conv(exp(-x).*heaviside(x),sin(x)));
par=[1];
[fitted_par, r, J, cov, mse] = nlinfit(dataX, dataY, mdl, par);
```

Regards, Niels.