I'm trying to compute a definite integral of the form $$\int_{0.2}^{0.5} \frac{1}{(1 - y)y^2\sqrt{0.5 - y^2 + y^3}}$$ in Mathematica. WolframAlpha will calculate this but Mathematica only outputs the integral in nice text.
This is the command I type in
Integrate[1/((1 - y)*y^2*Sqrt[0.5 - y^2 + y^3]), {y, 0.2, 0.5}]
Is this wrong? If it helps at all Mathematica will on the other hand compute this similar integral with no constant under the square root. $$\int_{0.2}^{0.5} \frac{1}{(1 - y)y^2\sqrt{- y^2 + y^3}}$$
NIntegrate
. I suppose alpha automatically switches to numeric integration, with mathematica you need to tell it to. (your second integral has a nice closed form ) $\endgroup$indef = Integrate[1/((1 - y)*y^2*Sqrt[1/2 - y^2 + y^3]), y]; (indef /. y -> .5 ) - (indef /. y -> .2) // N // Chop
.indef
is such a nasty expression i'm not sure there is any advantage over usingNIntegrate
$\endgroup$