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

Easier way to do an integral

  1. Oct 25, 2008 #1

    eof

    User Avatar

    Hi,

    I friend of mine gave me the following integral to calculate:

    [tex]\int_0^\infty \frac{e^{ax}-e^{bx}}{(1+e^{ax})(1+e^{bx})}[/tex]

    This can de done by first doing partial fractions which gives you

    [tex]\int_0^\infty \frac{1}{1+e^{bx}}-\frac{1}{1+e^{ax}}[/tex]

    then we can calculate each one by substituting [tex]t=1+e^{ax}[/tex] (and similarly for the other term). Hence

    [tex]dx=\frac{dt}{a(t-1)}[/tex],

    and finally after doing partial fraction again after the substitution, it boils down to

    [tex]
    \frac{(a-b)\ln 2}{ab}+\lim_{x\rightarrow\infty}\ln\frac{(1+e^{ax})^b}{(1+e^{bx})^a}
    =\frac{(a-b)\ln 2}{ab}[/tex]

    where the second term disappears. The calculation is straightforward, though quite messy. This had been on an actuarial exam a few years ago where they were actually expecting you to calculate it in under 2 minutes.

    I've been trying to figure out if there is an "easier" way to see the answer, but haven't come up with anything useful. I can't convert it into any known integral from Fourier analysis or see how to apply the calculus of residues or something similar. Any ideas?
     
  2. jcsd
  3. Oct 25, 2008 #2

    arildno

    User Avatar
    Science Advisor
    Homework Helper
    Gold Member
    Dearly Missed

    There's no particulr reason for why there should exist a quicker way of doing this
     
  4. Oct 25, 2008 #3

    eof

    User Avatar

    Yeah, I've been thinking about the same thing and that is puzzling me. :)

    EDIT: There were some extra conditions given (to ensure that it really converges), but I can't come up with an assumption that would do any good either.
     
  5. Oct 25, 2008 #4

    Mute

    User Avatar
    Homework Helper

    For the first partial fraction separation, you don't actually need to the full partial fractions alculation. Notice that you can add 0 = 1 -1 to the numerator, which gives you (1 + e^(ax)) - (1 + e^(bx)), so you can split it up within seconds to get to your second line.

    For the second partial fraction expansion, you can probably just look at it and guess what the coefficients need to be instead of working them out. You have A/t + B/(t-1), so looking at that, A = -1, B = 1 should do the job, as you can check pretty quickly.

    If you cut corners like that instead of doing the full calculation of the partial fraction separation, it should really cut down on the time taken to do that integral.
     
  6. Nov 2, 2008 #5

    Gib Z

    User Avatar
    Homework Helper

    How do you know it was under 2 minutes? That seems a bit difficult.
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Have something to add?



Similar Discussions: Easier way to do an integral
  1. Do a integral (Replies: 2)

Loading...