Im trying to find the resulting distribution for a convolution (of sorts) of two normal distributions as follows, such that the pdf is given by
The problem I'm having (and the reason this is in the calculus thread) is that the integral can't be evaluated in closed form, so a numerical solution is needed. I've started with Gaussian integration such that the problem becomes
In my example, I'm using mu1=5, mu2=6, s1=0.5, s2=2 for 0<z<12
However, this doesn't give a good approximation for large(ish) z. (which can be proved by setting Pr(N1=x)=1 for all x and performing the integration. This becomes the integration of a PDF, which should converge to 1). I think the problem comes down to the fact that the absiccia are appropriately spaced for the x variable, but not for the \ part. I'm not sure if a different numerical integration scheme would be more appropriate.
I have found, practically, that the following provides a good approximation when z is reasonably large (say >10).
Which I think works because it effectively samples both PDFs in the good/bad regions. I'm aware that it's not a mathematical solution and won't work for all mu,sigma,z combinations.
As you can tell, i'm not a mathematician, so am struggling with the literature surrounding this. I have found the following paper, but am struggling to deciper it. Gaussian Quadrature Formulae for Arbitrary Positive Measures
It would be great if anyone can shed any light on a more rigorous solution