Question: Wierd thing. I just couldn't reliably evaluate the convolution of this function

Hi all,

I am helping a friend on this. We would like to evaluate the
convolution of

f(x)=exp(3 * x) / (1 + exp(x) ^ 5).

However, in Maple and Mathematica, using symbolic calculations, after computing the integral in closed-form, the
convolution results in numerical oscillation (lots of spikeness). We
don't know why. We just couldn't get rid of the spikeness.

So our first question is that how do we remove the spikeness and oscillation of the convolution of the above function.

The second question: the above convolution is not our end goal, we need to build more complicated functionals involving the convolution. And at the end of day, our end-goal is to numerically evaluate
some functions involving the convolution of f(x) and we decided to do that numerical part in Matlab for the sake of speed. So it might be
better to directly handle the convolution in discrete domain and using
Matlab's conv function.

So the second question is: is using discrete convolution to approximate continuous approximation doable in theory?

So we wrote the following program; but we just couldn't get the
scaling and positioning right. For example, let's call the convolution
g(x)=f(x) ** f(x), g(0) should correspond to the 20000th element in
the resultant z, but z(20000) doesn't give a correct number, compared
to the theoretical result of the convolution.

Could anybody please help us? We need a way to figure out the scaling
factor on the convolution result and how does it map into the
continuous convolution result. And hopefully with lots of samples, we
would be able to approximate the continuous convolution using discrete
convolution. We have to take this approach because the closed-form
expression for g(x) gives a lot spikeness and we just couldn't get a
stable convolution result via evaluating the closed-form expression at
all points.

Thanks a lot!

-------------------------------------------------------

deltat=0.001;

x= [-10:deltat:10-deltat];

y= exp(3 * x) ./ (1 + exp(x) .^ 5);

z=conv(y, y)*deltat;

figure;

plot(z);

Please Wait...