Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Integrating exp(mod(x))

  1. Nov 10, 2007 #1

    I need to calculate [tex]\int_{-\infty}^{\infty} x^{2} e^{-\frac{|x|}{b} dx[/tex] and I know the answer should involve [tex]\pi[/tex].
    I've tried splitting the integral for x and -x with limits from 0 to infty and -infinty to 0, which gives me the answer of 2b. But I don't think this is correct. Does anyone have any hints or tips on what to do?
  2. jcsd
  3. Nov 10, 2007 #2
    That's a correct way to approach this.

    Post your work here, and we'll try to help you.

    Oh, BTW, the answer does not involve pi, unless you want to write it as answer*pi/pi or something. :wink:
  4. Nov 10, 2007 #3


    User Avatar
    Science Advisor
    Homework Helper
    Gold Member
    Dearly Missed

    Note that your integrand is even. Thus, you may simplify your problem as follows:
    where I've omitted the absolute value sign about x, since for x>=0, we have |x|=x.
  5. Nov 10, 2007 #4
    Here is a continuation of arildno post. Let [tex]t=-x/b[/tex] (assuming [tex]b>0[/tex]) and preform substitution. Then do integration by parts twice.
  6. Nov 10, 2007 #5


    User Avatar
    Science Advisor
    Homework Helper
    Gold Member
    Dearly Missed

    Wouldn't it just be simpler to let t=x/b so that we don't need to change our limits to 0 and and negative infinity?
  7. Nov 10, 2007 #6
    Why do a normal substitution?

    It looks like one should use integration by parts twice.
  8. Nov 11, 2007 #7
    One more hint, there are two answers. The reason is that you don't know what the value of b is.
  9. Nov 11, 2007 #8
    You don't need to do integration by parts. Just substitute b ---> 1/p
    so that the exponential becomes exp(-p x) . Integrate exp(p x) and differentiate twice w.r.t. p to bring down a factor x^2 in the integrand.

    The integral is thus 1/p. Differentiating twice w.r.t. p gives 2/p^3. Multiply by 2 and put back b to obtain the answer: 4 b^3.
  10. Nov 11, 2007 #9
    I don't understand what method you are using. Is this some sort of DE trick? I would appreciate learning this method. Please post the full solution.

    (Note: If b is negative, the integral diverges.)
    Last edited: Nov 11, 2007
  11. Nov 11, 2007 #10
    It is explained in detail http://en.wikipedia.org/wiki/Differentiation_under_the_integral_sign" [Broken].


    [tex]\int_{0}^{\infty}\exp(-p x)dx=\frac{1}{p} [/tex]

    Differentiate both sides w.r.t. p:

    [tex]\frac{d}{dp}\int_{0}^{\infty}\exp(-p x)dx=-\frac{1}{p^2} [/tex]

    Interchange the order of integration and differentiation to obtain:

    [tex]\int_{0}^{\infty}x\exp(-p x)dx=\frac{1}{p^2} [/tex]
    Last edited by a moderator: May 3, 2017
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook