Greetings. I am trying to do the convolutions of two lognormal distributions however, I am getting errors. I started to question my method but I cannot find a mistake in my script. Is there a better way? I seem to be getting unexpected numerical values. I would expect like any CDF to approach 1, but this one is not.
%% Convolution of two LogNormal Distributions.
muX = 9.7224;
sigmaX = 0.3332;
muY = 8.6878;
sigmaY = 0.2454;
t = inf;
fun = @(y,x) exp(-0.5.*((log(x) - muX).^2)./(sigmaX.^2))./(x.*sigmaX.*sqrt(2.*pi)) .* exp(-0.5.*((log(y) - muY).^2)./(sigmaY.^2))./(y.*sigmaY.*sqrt(2.*pi));
P = integral2(fun,-inf,t - 'x',-inf,inf,'RelTol',1e-12,'AbsTol',1e-12)