# Thread: What Am I Doing Wrong? - Integral

1. ## What Am I Doing Wrong? - Integral

Back of the book says the answer is zero, but I keep getting infinity (which I think means it is divergent), and I don't know where the discrepancy lies :/

$\displaystyle \int_{-\infty}^\infty xe^{-x^2}$

$\displaystyle =\lim_{N\to\infty}\int_0^N xe^{-x^2} + \lim_{B\to\infty}\int_{-B}^0 xe^{-x^2}$

$\displaystyle =\lim_{N\to\infty}\left[\frac {-1}2e^{-x^2}\right]_0^N + \lim_{B\to\infty}\left[\frac {-1}2e^{-x^2}\right]_{-B}^0$

$\displaystyle =\lim_{N\to\infty}\left[\frac {-1}{2e^{x^2}}\right]_0^N + \lim_{B\to\infty}\left[\frac {-1}{2e^{x^2}}\right]_{-B}^0$

$\displaystyle =\lim_{N\to\infty}\left[\frac{-1}{2e^{N^2}}+\frac{1}{2e^{0^2}}\right] +\lim_{B\to\infty}\left[\frac {-1}{2e^{0^2}}+\frac {1}{2e^{-B^2}}\right]$

$\displaystyle =\lim_{N\to\infty}\left[\frac{-1}{2e^{N^2}}+\frac{1}{2}\right] +\lim_{B\to\infty}\left[\frac {-1}{2}+\frac {e^{B^2}}{2}\right]$

$\displaystyle =\left[\frac{-1}{2e^{\infty^2}}+\frac{1}{2}\right] +\left[\frac {-1}{2}+\frac {e^{\infty^2}}{2}\right]$

$\displaystyle =\frac{-1}{\infty}+\frac{1}{2} + \frac {-1}{2}+\frac {\infty}{2}$

$\displaystyle =\frac{-1}{\infty}+\frac {\infty}{2}$

$\displaystyle =0+\infty$

$\displaystyle =\infty$

2. Originally Posted by angel.white
Back of the book says the answer is zero, but I keep getting infinity (which I think means it is divergent), and I don't know where the discrepancy lies :/

$\displaystyle \int_{-\infty}^\infty xe^{-x^2}$

$\displaystyle =\lim_{N\to\infty}\int_0^N xe^{-x^2} + \lim_{B\to\infty}\int_{-B}^0 xe^{-x^2}$

$\displaystyle =\lim_{N\to\infty}\left[\frac {-1}2e^{-x^2}\right]_0^N + \lim_{B\to\infty}\left[\frac {-1}2e^{-x^2}\right]_{-B}^0$

$\displaystyle =\lim_{N\to\infty}\left[\frac {-1}{2e^{x^2}}\right]_0^N + \lim_{B\to\infty}\left[\frac {-1}{2e^{x^2}}\right]_{-B}^0$

$\displaystyle =\lim_{N\to\infty}\left[\frac{-1}{2e^{N^2}}+\frac{1}{2e^{0^2}}\right] +\lim_{B\to\infty}\left[\frac {-1}{2e^{0^2}}+\frac {1}{2e^{-B^2}}\right]$

$\displaystyle =\lim_{N\to\infty}\left[\frac{-1}{2e^{N^2}}+\frac{1}{2}\right] +\lim_{B\to\infty}\left[\frac {-1}{2}+\frac {e^{B^2}}{2}\right]$

$\displaystyle =\left[\frac{-1}{2e^{\infty^2}}+\frac{1}{2}\right] +\left[\frac {-1}{2}+\frac {e^{\infty^2}}{2}\right]$

$\displaystyle =\frac{-1}{\infty}+\frac{1}{2} + \frac {-1}{2}+\frac {\infty}{2}$

$\displaystyle =\frac{-1}{\infty}+\frac {\infty}{2}$

$\displaystyle =0+\infty$

$\displaystyle =\infty$
You're integrating an odd function. Letting the integral limits be x = -L and x = L, the integral will equal zero. And of course you can then take the limit L --> oo and get zero .....

3. Originally Posted by angel.white
Back of the book says the answer is zero, but I keep getting infinity (which I think means it is divergent), and I don't know where the discrepancy lies :/

$\displaystyle \int_{-\infty}^\infty xe^{-x^2}$

$\displaystyle =\lim_{N\to\infty}\int_0^N xe^{-x^2} + \lim_{B\to\infty}\int_{-B}^0 xe^{-x^2}$

$\displaystyle =\lim_{N\to\infty}\left[\frac {-1}2e^{-x^2}\right]_0^N + \lim_{B\to\infty}\left[\frac {-1}2e^{-x^2}\right]_{-B}^0$

$\displaystyle =\lim_{N\to\infty}\left[\frac {-1}{2e^{x^2}}\right]_0^N + \lim_{B\to\infty}\left[\frac {-1}{2e^{x^2}}\right]_{-B}^0$

$\displaystyle =\lim_{N\to\infty}\left[\frac{-1}{2e^{N^2}}+\frac{1}{2e^{0^2}}\right] +\lim_{B\to\infty}\left[\frac {-1}{2e^{0^2}}+\frac {1}{2e^{-B^2}}\right]$ Mr F says: And the mistake is in this line ..... When you sub $\displaystyle \, x = -B \,$ into $\displaystyle \, x^2\,$, the result is $\displaystyle \, B^2\,$, not $\displaystyle \, -B^2\,$ .....

$\displaystyle =\lim_{N\to\infty}\left[\frac{-1}{2e^{N^2}}+\frac{1}{2}\right] +\lim_{B\to\infty}\left[\frac {-1}{2}+\frac {e^{B^2}}{2}\right]$

$\displaystyle =\left[\frac{-1}{2e^{\infty^2}}+\frac{1}{2}\right] +\left[\frac {-1}{2}+\frac {e^{\infty^2}}{2}\right]$

$\displaystyle =\frac{-1}{\infty}+\frac{1}{2} + \frac {-1}{2}+\frac {\infty}{2}$

$\displaystyle =\frac{-1}{\infty}+\frac {\infty}{2}$

$\displaystyle =0+\infty$

$\displaystyle =\infty$
..

4. Thank you, glad it was something stupid and not a complete lack of understanding on how to do these.

Pretty confident, then, that I can do these now, but I already uploaded my next two problems, so if someone wouldn't mind checking the answers, I would appreciate it. They're even problems, so not in the back of the book, and the calculator I usually use to check my work doesn't seem to like infinite boundaries.

----------------

5. Originally Posted by angel.white
Thank you, glad it was something stupid and not a complete lack of understanding on how to do these.

Pretty confident, then, that I can do these now, but I already uploaded my next two problems, so if someone wouldn't mind checking the answers, I would appreciate it. They're even problems, so not in the back of the book, and the calculator I usually use to check my work doesn't seem to like infinite boundaries.

[snip]
Instant feedback: The first one is wrong I'm sorry to say. Note that ln(0) is undefined, NOT 1 ..... There's a couple of other things wrong too ... You can't multiply oo by 2 ....!! Under the change of variable a = 2x - 5, x = -oo => a = -oo.

6. Originally Posted by angel.white
Thank you, glad it was something stupid and not a complete lack of understanding on how to do these.

Pretty confident, then, that I can do these now, but I already uploaded my next two problems, so if someone wouldn't mind checking the answers, I would appreciate it. They're even problems, so not in the back of the book, and the calculator I usually use to check my work doesn't seem to like infinite boundaries.

[snip]

Your answer is correct, but again the error of treating oo like a number. Under the change of variable a = x^2 + 2, x = +oo => a = +oo .....

7. Originally Posted by mr fantastic
Instant feedback: The first one is wrong I'm sorry to say. Note that ln(0) is undefined, NOT 1
>.< not my night, think I'll pick these back up tomorrow when my mind is fresher.
Originally Posted by mr fantastic
..... There's a couple of other things wrong too ... You can't multiply oo by 2 ....!! Under the change of variable a = 2x - 5, x = -oo => a = -oo.
Okay, how do I remedy that? Put the limit in place pior to changing the limits?

It's so hard to force myself to do these, I know what I want to do, I have like the next 3 or 4 steps planned in my mind, and then I get bogged down writing out the notation.

Thank you for your help, btw.

8. there's another nice substitution for your second problem, hope you'll find it helpful:

$\displaystyle \begin{gathered} \int_0^\infty {\frac{x} {{\left( {x^2 + 2} \right)^2 }}dx} \hfill \\ \hfill \\ x = \sqrt 2 \tan u \hfill \\ dx = \frac{{\sqrt 2 }} {{\cos ^2 u}}du \hfill \\ \end{gathered}$

the new limits are:

$\displaystyle \begin{gathered} 0 < \sqrt 2 \tan u < \infty \hfill \\ 0 < u < \frac{\pi } {2} \hfill \\ \end{gathered}$

$\displaystyle \int_0^{\frac{\pi } {2}} {\frac{{\sqrt 2 \tan u}} {{\left( {2\tan ^2 u + 2} \right)^2 }}\frac{{\sqrt 2 }} {{\cos ^2 u}}du} = \frac{1} {2}\int_0^{\frac{\pi } {2}} {\sin u\cos udu} = \frac{1} {4}\int_0^{\frac{\pi } {2}} {\sin 2udu} =$

$\displaystyle = \left. { - \frac{1} {8}\cos 2u} \right|_0^{\frac{\pi } {2}} = \frac{1} {4}$

9. Originally Posted by mr fantastic
Your answer is correct, but again the error of treating oo like a number. Under the change of variable a = x^2 + 2, x = +oo => a = +oo .....
Okay, I redid the problem, trying to use all limits until the end when I couldn't simplify any more without plugging infinity back into the problem. I am hoping that this fixes the problem of "treating oo like a number." Can someone let me know if this is the correct way to handle this type of problem?

10. Originally Posted by angel.white
Okay, I redid the problem, trying to use all limits until the end when I couldn't simplify any more without plugging infinity back into the problem. I am hoping that this fixes the problem of "treating oo like a number." Can someone let me know if this is the correct way to handle this type of problem?

Looks much better.

This is not a criticism, but I'd be inclined to do it the following way:

The substitution $\displaystyle a = 2x - 5$ means that the integral limits change from $\displaystyle -\infty < x < 0$ to $\displaystyle -\infty < a < -5$.

So the integral becomes $\displaystyle \frac{1}{2} \int_{-\infty}^{-5} \frac{1}{a} \, da$.

Then I'd do the limit business on this improper integral ..... I just find it makes life a bit easier.

But there is nothing wrong with your approach.