Symbolic Integration: Explicit integral could not be found
Show older comments
Hi all,
I got a problem when trying to run a symbolic integration. Since lognormal distribution is not defined in the symbolic tools, I just write it out in an explicit way. The code is as follows:
syms w mu sigma positive
t = (w-6.5)*(w*sigma)^(-1)*(1/sqrt(2*pi)*exp(-(log(w)-mu)^2/sigma^2/2));
c = int(t,w,6.5,inf);
And the error msg is:
Warning: Explicit integral could not be found.
Can anybody please give some hint how to get the integration?
Thanks very much!!
Sonia
1 Comment
David
on 22 Oct 2012
Sonia, I had a similar problem and your post really help me, but I do not understand your formula:
(w-6.5).*(w*sigma).^(-1).*(1/sqrt(2*pi)*exp(-(log(w)-mu).^2/sigma^2/2));
could it be: (w-6.5).*(sigma).^(-1).*(1/sqrt(2*pi)*exp(-(log(w)-mu).^2/sigma^2/2));
Is this ok?
Accepted Answer
More Answers (1)
Walter Roberson
on 1 Apr 2012
limit(-(1/2)*exp(mu+(1/2)*sigma^2)*erf((1/2)*2^(1/2)*(sigma^2-U+mu)/sigma)+(13/4)*erf((1/2)*2^(1/2)*(-U+mu)/sigma)+(1/2)*exp(mu+(1/2)*sigma^2)*erf((1/2)*2^(1/2)*(-ln(13/2)+mu+sigma^2)/sigma)+(13/4)*erf((1/2)*2^(1/2)*(ln(13/2)-mu)/sigma), U = infinity)
Note, in this expression, U is an introduced variable for the purpose of the limit()
Categories
Find more on Programming in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!