From here:
The overall goal of symbolic computation is typically to get formulas that are valid for many possible values of the variables that appear in them. It is however often not practical to try to get formulas that are valid for absolutely every possible value of each variable.
...
The basic operations of Mathematica are nevertheless carefully set up so that whenever possible the results obtained will be valid for almost all values of each variable.
So, congratulations; the solution Mathematica got for you happens to be indeterminate at the particular argument you are interested in. Nevertheless, taking limits yields the result you seem to expect:
Limit[y^2 (y - 1) Hypergeometric2F1[-(1/2), 1/4, 5/4, -(y/(y - 1))^2],
y -> 1] // FullSimplify
1/3
Since Mathematica doesn't know everything (GASP!), any result it gives will sometimes need further massage before you obtain a more practical form. In this case, we apply one of the Euler transformations of the Gaussian hypergeometric function to give a form that seems more suited to your needs:
anush[y_] :=
y^2 Sqrt[1 + 2 y (y - 1)] Hypergeometric2F1[-1/2, 1, 5/4, y^2/(1 + 2 y (y - 1))]
Check:
anush[1] // FullSimplify
1/3
Compare with the original integral:
With[{y = 9/10}, {NIntegrate[Sqrt[x^4 + (y - y^2)^2], {x, 0, y}, WorkingPrecision -> 20],
N[anush[y], 20]}]
{0.27187611249376847527, 0.27187611249376847433}
Close enough for me!
It should be noted that the particular solution I gave gives the same results as the integral only over $[0,\infty)$; if you're evaluating for negative y
, then you will have to do some sign-flipping on your own.
FWIW, what you have there is what's called an elliptic integral, since you have the square root of a quartic polynomial present. The general form of your particular integral will involve the incomplete elliptic integrals of the first and second kinds (EllipticF[]
and EllipticE[]
in Mathematica, respectively). I don't think much of Mathematica's symbolic capabilities with respect to elliptic integrals, so I'd give you the advice to look at a book like Byrd/Friedman (in particular, see section 260 onwards) if you really, truly, genuinely need the expression in terms of elliptic integrals.
y=1
, you have a0 * ∞
indeterminacy. When you take a limity -> 1
, you recover that result you mention, but you have to take that limit, and Mathematica is IMO correct to draw your attention to it, since it is not possible for it to see whether or not the function is well-defined at that point without some further analysis, which was not requested. $\endgroup$y==1
. Nevertheless you can do it simply with assumption :Integrate[Sqrt[x^4 + (y - y^2)^2], {x, 0, y}, Assumptions -> y == 1]
yields $\frac{1}{3}$. $\endgroup$Integrate[Sqrt[x^4 + (1 - 1^2)^2], {x, 0, 1}] = 1/3
. You don't need to take limits. $\endgroup$