u-substitution shows 0=1

2.5k Views Asked by At

This question/observation is inspired by the integral:

$$\int_0^{\sqrt{\pi}}x\sin(x^2)\cos(x^2)dx$$

The $u$-substitution $u=\sin(x^2)$ yields $du=2x\cos(x^2)dx$ and

$$\int_0^{\sqrt{\pi}}x\sin(x^2)\cos(x^2)dx=\frac{1}{2}\int_0^0 u du=0,$$

right? Wolframalpha certainly agrees.

Great, now consider the much harder integral $$\int_0^1 dx.$$

After banging our heads against the wall for hours we take $u=x^2-x$ so $du=(2x-1)dx=\pm\sqrt{1+4u}*dx$ by the quadratic formula, so

$$\int_0^1 dx=\int_0^0\frac{du}{\pm\sqrt{1+4u}}=0$$

The problem is wolframalpha says this integral should be $1$. Well, I guess it is a unit square.


Since $0\neq 1$ there is something fishy going on - I'm just trying to fully nail down the issue here. I think it boils down to hidden division by $0$ like most false proofs. In particular we can't solve the equation $du=(2x-1)dx$ for $dx$ if $x=\frac{1}{2}$, which happens inside the domain of integration. This isn't a problem for the original integral because even though there is a place where $\frac{du}{dx}=0$ inside the domain of integration $(x=\sqrt{\frac{\pi}{2}})$ there is no issue because we don't have to divide by this expression to make all the $x$s cancel. Anyway, I'm curious for further explanation and to know if there are any references which carefully explain subtleties such as this for integration by substitution.

1

There are 1 best solutions below

0
On BEST ANSWER

Formally, substitution says that if $g$ is differentiable on an interval, and $f$ is continuous on the image interval of $g$, then

$$ \int_a^b f(g(x)) g'(x) \, dx = \int_{g(a)}^{g(b)} f(u) \, du.$$

In our case, when we try to write the simple yet problematic integral in the form required by the left-hand side, we get

$$ \int_0^1 \, dx = \int_0^1 \frac1{2x-1}(2x-1)\, dx = \int_0^1 \, \frac1{\pm\sqrt{1+4(x^2 -x)}}(2x-1) \, dx, $$

but the sign ambiguity tells us that we must proceed more carefully (or else what single $f$ do we choose?). Indeed $2x - 1 = \sqrt{1+4(x^2-x)}$ when $x > 1/2$, whereas $2x - 1 = -\sqrt{1+4(x^2-x)}$ when $x < 1/2$. So really we should have written

$$ \int_0^{1/2} \, \frac1{-\sqrt{1+4(x^2 -x)}}(2x-1) \, dx + \int_{1/2}^{1} \, \frac1{\sqrt{1+4(x^2 -x)}}(2x-1) \, dx,$$ or via $u = g(x)$

$$ \int_0^{-1/4} \, \frac1{-\sqrt{1+4u}} \, du + \int_{-1/4}^{0} \, \frac1{\sqrt{1+4u}} \, du = \frac12 + \frac12 = 1,$$

which is the correct answer.