Results 1 to 10 of 10

Math Help - Exponential Integral

  1. #1
    Newbie
    Joined
    May 2011
    Posts
    10
    I was hoping to post in here another problem I solved to show what I've learned, but the test data I plug into my solution gives me unexpected results. I looked over it a dozen times.

    This is supposed to evaluate the area under a curve between two points when the curve equation's variable is in the exponent. For example:

    y = a^x

    Such as in the formula for continuously compounded interest:

    A = Pe^{rt}

    where, P is the starting principal,
    e is Euler's Number,
    r is the annual interest rate (e.g. 0.1 is 10%),
    and A is the balance after t years


    So to find the area, I take what I presume is called the integral of its differential:

    \int_{p}^{q}(Pe^{rt})dx

    \int_{p}^{q}\frac{Pe^{rt + 1}}{rt+1}

    \left[\frac{Pe^{rq + 1}}{rq+1}\right] - \left[\frac{Pe^{rp + 1}}{rp+1}\right]

    Substitute simple data to check (P=1, r=0.0, p=0, q=2):

    \left[\frac{1e^{0 \cdot 2 + 1}}{0 \cdot 2+1}\right] - \left[\frac{1e^{0 \cdot 0 + 1}}{0 \cdot 0+1}\right]

    \left[\frac{e^{1}}{1}\right] - \left[\frac{e^{1}}{1}\right]

    Area = 0

    That's not right. Well, you see what I've learned. What am I doing wrong?
    Last edited by qformat; June 2nd 2011 at 05:22 AM. Reason: additional information
    Follow Math Help Forum on Facebook and Google+

  2. #2
    A Plied Mathematician
    Joined
    Jun 2010
    From
    CT, USA
    Posts
    6,318
    Thanks
    4
    Awards
    2
    I presume you actually mean

    \int_{p}^{q}Pe^{rt}\,dt.

    The antiderivative for the exponential function (as opposed to the polynomial function in your other thread) is completely different. Basically, every function has a different antiderivative. In this case, you get the following:

    \int_{p}^{q}Pe^{rt}\,dt=P\int_{p}^{q}e^{rt}\,dt=P \left[ \frac{e^{rt}}{r} \right]_{p}^{q}=P\,\frac{e^{rq}-e^{rp}}{r}.
    Follow Math Help Forum on Facebook and Google+

  3. #3
    Newbie
    Joined
    May 2011
    Posts
    10
    Quote Originally Posted by Ackbeet View Post
    I presume you actually mean

    \int_{p}^{q}Pe^{rt}\,dt.
    Uh..hehe, that makes sense.

    It looks like it works! I spent a day on this, and Ackbar needs barely open one eye. I hope I don't bore this wonderful man (too much).

    If you wanted to know, I'm using this to compute the total number of instructions the world could execute between two arbitrary years (based on the world's combined IPS (instructions per second) and growth rate in 2007).

    Thanks
    Follow Math Help Forum on Facebook and Google+

  4. #4
    A Plied Mathematician
    Joined
    Jun 2010
    From
    CT, USA
    Posts
    6,318
    Thanks
    4
    Awards
    2
    Quote Originally Posted by qformat View Post
    Uh..hehe, that makes sense.

    It looks like it works! I spent a day on this, and Ackbar
    Ack! Not another user who intentionally mis-spells my username! I've already got topsquawk on my case.

    needs barely open one eye. I hope I don't bore this wonderful man (too much).

    If you wanted to know, I'm using this to compute the total number of instructions the world could execute between two arbitrary years (based on the world's combined IPS (instructions per second) and growth rate in 2007).

    Thanks
    Interesting application. What's your final result, out of curiosity?
    Follow Math Help Forum on Facebook and Google+

  5. #5
    Newbie
    Joined
    May 2011
    Posts
    10
    Ahah, sorry!

    Quote Originally Posted by ackbeet
    Interesting application. What's your final result, out of curiosity?
    Alright, I'll post it in an hour or so after I rewrite my worksheet, plug in the data, update the script, and check the results.
    Follow Math Help Forum on Facebook and Google+

  6. #6
    A Plied Mathematician
    Joined
    Jun 2010
    From
    CT, USA
    Posts
    6,318
    Thanks
    4
    Awards
    2
    Quote Originally Posted by qformat View Post
    Ahah, sorry!
    No need to apologize. The staff here at MHF go in for this sort of ribbing.

    Alright, I'll post it in an hour or so after I rewrite my worksheet, plug in the data, update the script, and check the results.
    I'll stay tuned.
    Follow Math Help Forum on Facebook and Google+

  7. #7
    A Plied Mathematician
    Joined
    Jun 2010
    From
    CT, USA
    Posts
    6,318
    Thanks
    4
    Awards
    2
    Incidentally, WolframAlpha can compute lots of integrals, especially the more elementary ones. If you're just in need of some basic integrals, you might check that out.
    Follow Math Help Forum on Facebook and Google+

  8. #8
    Newbie
    Joined
    May 2011
    Posts
    10
    Oh thanks, bookmarked. I'm rewriting my worksheet now, do you have a program to use this Latex syntax at home?
    Follow Math Help Forum on Facebook and Google+

  9. #9
    A Plied Mathematician
    Joined
    Jun 2010
    From
    CT, USA
    Posts
    6,318
    Thanks
    4
    Awards
    2
    Quote Originally Posted by qformat View Post
    Oh thanks, bookmarked. I'm rewriting my worksheet now, do you have a program to use this Latex syntax at home?
    Yes, as do most mathematicians. I have GhostScript, GhostView, MiKTeX, and TextPad, installed in that order, on my machine. Other people I know, like CaptainBlack, use LyX. I don't know what other software you'd need in order to use LyX, but LyX seems like a good option as well. Generally, you need several ingredients for writing in LaTeX: the LaTeX distribution proper, a dvi viewer, and a text editor, preferably with syntax highlighting. Then you're good to go.
    Follow Math Help Forum on Facebook and Google+

  10. #10
    Newbie
    Joined
    May 2011
    Posts
    10
    Wow. I'll have to install one. I've tried to do Calculus in Notepad++ on more than one occasion.

    I finished! The formula I used was:

    TotalInstructions = aP\,\frac{e^{r(y_2 - Y)}-e^{r(y_1 - Y)}}{r}

    where y_1 is the starting year, y2 is the ending year, P is the number is IPS (instructions per second) in year Y, r is the continuously-compounded rate of IPS growth, a is the number of seconds in a year (used to convert P to same unit as the other variables) (i.e. 86400 * 365.25 = 31557600).

    Or, rather, since I'm including more than one type of hardware:

    TotalInstructions = aP_1\,\frac{e^{r_1(y_2 - Y)}-e^{r_1(y_1 - Y)}}{r_1}\,+\,aP_2\,\frac{e^{r_2(y_2 - Y)}-e^{r_2(y_1 - Y)}}{r_2}

    The data I'm using is:

    P_1 = 2.06E17 (general-purpose hardware)
    P_2 = 6.2E18 (application-specific hardware)
    r_2 = 0.4574 (45.74% continuously-compounded growth rate; derived from 58% compound annual rate)
    r_2 = 0.6206 (62.06% continuously-compounded growth rate; derived from 86% compound annual rate)
    Y = 2007 (the year the study was done)

    I sourced my data from the following sites. Unfortunately, a quick search didn't turn up the original study:
    World's total CPU power: one human brain
    The Technological Brain Grows | Mother Jones

    NOTE: IPS is not a determinant way to measure performance, as the amount of work a single instruction can do varies from architecture to architecture.

    NOTE: The growth rates I used were the growth rates reported over the test period. More accurate growth rates may be able to be derived by combining test results from earlier studies.

    Here is my:
    Worksheet
    C# Source Code (can be run directly with CS-Script, or compiled in Visual Studio or C# Express)
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. exponential integral
    Posted in the Calculus Forum
    Replies: 6
    Last Post: July 18th 2010, 06:44 AM
  2. Integral of an exponential
    Posted in the Calculus Forum
    Replies: 5
    Last Post: February 2nd 2010, 04:55 AM
  3. exponential integral
    Posted in the Calculus Forum
    Replies: 5
    Last Post: February 22nd 2009, 05:09 AM
  4. exponential integral
    Posted in the Calculus Forum
    Replies: 3
    Last Post: March 17th 2008, 03:57 PM
  5. exponential integral
    Posted in the Calculus Forum
    Replies: 3
    Last Post: June 5th 2007, 08:31 PM

Search Tags


/mathhelpforum @mathhelpforum