I am not having a problem using code similar to yours. Can you tell me exactly what are the function parameters. so I can run exactly your code and reproduce your problem ?
I suspect is a numerical issue in the function calculation
a Gaussian meant to describe the longitudianal diffusion of a cluster of electrons (described by tf1_L in my code) with a width of sigma_in = 16 (ns).
the product of a sine function, an exponential decay and a 3rd degree polynomial to describe the electronics shaping effects. This is a function of (x-(par[0])/par[1] where par[0] is supposed to be the offset (~9000 ns in my case) and par[1] is the time constant of the decay and is of the order of 600 (ns). I also make sure that the function is only defined for x>par[0] by putting in that condition. par[2] is just a normalization constant so far, I put it equal to 1, so that it’s comparable to the gaussian.
(I will further have to convolute the result of this convolution with a third function containing TMath::Erf).
These functions should be convoluted in the range 0…40000 (ns).
Otherwise I’m just using the parameters in the code above.
Hi,
Yes the convolution is commutative if you define it in the full -[-inf, +inf] range. Otherwise one needs to correct change the range when the order of the functions is reversed (e.g. if the gaussian is the first function)