0
$\begingroup$

I have this function, $e^{-x}$ bounded between 0 and 1500 and I have an approximation by Taylor Series of the same function bounded between 0 and 0.5. I would like to express my function $e^{-x}$ bounded between 0 and 15oo in terms of the last approximation I described, what is bounded between 0 and 0.5. Does anyone know how I can do it? Thank you.

NOTE: This question is related with Development of a hardware arquitecture for a particular algorithm.

  • 0
    possible duplicate of [Development of a specific hardware architecture for a particular algorithm. Modelling fuctions by Taylor Series.](http://math.stackexchange.com/questions/15330/development-of-a-specific-hardware-architecture-for-a-particular-algorithm-model)2010-12-24

1 Answers 1

3

Where is the Taylor series for (0,1500) centered? If at zero, it is the same Taylor series as for (0,0.5). But you really don't want a Taylor series for (0,1500)-it would take an enormous number of terms for any reasonable accuracy. Numerical Recipes (chapters 5 and 6) and all other numerical analysis books have suggestions for better models. Abramowitz and Stegun has a polynomial fit over (0,1) that is much more accurate than you need. Given what you had in the previous question, you can't represent $\exp(-x)$ for $x$ much over 11 because you will underflow.

  • 0
    If I were in his shoes, I'd do scaling and squaring: for positive argument, keep dividing by 2 until it's small enough, evaluate a Padé approximant of appropriate order, and square the result of that an appropriate number of times, and then reciprocate.2010-12-24
  • 0
    (Answer to "Where is the Taylor series for (0,1500) centered?"): I was thinking about two possibilities. One, to use the maclaurin series, the other, would be to chose a middle point in the bound, for the bound (0,1500), I would chose as middle point, 750.2010-12-30
  • 0
    @Peterstone: Those are both possibilities. The middle point will give better accuracy, as the ends of the interval are not so far away. But can you fit exp(-1500) in your data type without underflow? Even exp(-15)?2010-12-30