Why integrals with respect to different variables aren't equal?

I have a function $y=x^2+1$, the integral from $-1$ to $2$ is $\int_{-1}^{2}(x^2+1)dx = 6$.

The function $x=\sqrt{y-1}$ is the same as the above function. The integral would be from $0$ to $(2)^2+1=5$. So I thought that $\int_{0}^{5}(\sqrt{y-1})dy$ would be equal to the first one.

But it turns out that it does not. The integral of the second function actually is $\frac{16}{3}+\frac{2i}{3}$.

So by looking at the graph of this function I realized that I can just add the bottom rectangle to the upper part thus eliminating the dealing with complex numbers like this: $(3\times 1)+\int_{1}^{5}\sqrt{y-1}dy$, but this is equal to $25/3$ or approximately $8$ instead of $6$.

So my question is, why aren't these two integrals equal?

2022-07-25 17:47:13
Source Share
Answers: 0