Compute Taylor Series & Approximate Integral of Exponential Function

Click For Summary
SUMMARY

The discussion focuses on computing the Taylor Series expansion of the function f(x) = exp(-x^2) around 0 and using it to approximate the integral from 0 to 0.1 of exp(-t^2) dt. The Taylor Series is expressed as 1 - (x^2) + (x^4)/2! - (x^6)/3! and a closed form solution is provided. The integral approximation method discussed involves evaluating the Taylor Series at specific points and highlights the need for determining the appropriate number of terms to achieve an accurate result. A suggestion is made to compute the integral of the Taylor Series directly rather than subtracting evaluated points.

PREREQUISITES
  • Understanding of Taylor Series expansion
  • Familiarity with the exponential function and its properties
  • Basic calculus concepts, particularly integration
  • Knowledge of error estimation in series approximations
NEXT STEPS
  • Learn how to compute integrals of Taylor Series directly
  • Study error estimation techniques for Taylor Series approximations
  • Explore higher-order Taylor Series expansions for improved accuracy
  • Investigate numerical integration methods for functions like exp(-x^2)
USEFUL FOR

Mathematicians, students in calculus, and anyone interested in numerical methods for approximating integrals and understanding Taylor Series expansions.

asif zaidi
Messages
56
Reaction score
0
Problem Statement
Compute the Taylor Series expansion of f(x) = exp(-x^2) around 0 and use it to find an approximate value of the integral (from 0 to 0.1) of exp(-t^2) dt

Solution

Part1:
First to compute the Taylor Series - I am pretty sure about this step so I will not give details. But if I am wrong, please correct.

Taylor Series = 1 - (x^2) + (x^4)/2! - (x^6)/3! + ... --- EQUATION 1

And a closed form solution is from Sum (i from 0 to inf) of (-1^i)* (x^2*i)/i!

Part2:
This is the part I am not doing right - maybe I am not approaching the problem in the right way.
To solve the integral evaluate the Taylor Series in equation 1 above at 0.1 and 0 and subtract. Also, I took just the first 4 terms of equation 1. Is there a way I can determine how many terms I should take?

At x = 0.1: Equation 1 is evaluated to 0.99004983375
At x = 0.0: Equation 1 is evaluated to 1.000000000000
Subtracting above gives me an integral value of -0.00995016625.

So my two questions are:

1- Now this I know is clearly wrong as the value should be positive but I cannot figure out what I am doing wrong. The absolute value above is right but why am I getting a negative. I tried above method for positive exponentials and it worked but any negative exponential, I am always getting the negative answer.

2- How do I determine how many terms I should use in my Taylor Series expression.


Thanks


Asif
 
Physics news on Phys.org
Actually, don't you think you should rather calculate
\int_0^{0.1} T_n(x) \, \mathrm{d}x
instead of
T_n(0.1) - T_n(0)
where T_n(x) is the n-th order Taylor series for the function
(so for example, T_4(x) = T_5(x) = 1 - x^2 + x^4/2 and T_6(x) = 1 - x^2 + x^4/2 - x^6/6).

Then you can just take it up to order 6 and already get an error of less than 10^{-10}. You could do look at the terms you have neglected to estimate the error (e.g. neglecting x^8 and higher, the error you make will be at most of order 1/9 (0,1)^9).
 
i don't know abput you. but i only got notes on these questions. cheak then for refernbce. my blog can be found at the top blogs section. kaixuan
 

Similar threads

Replies
4
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 27 ·
Replies
27
Views
3K
Replies
4
Views
2K
  • · Replies 12 ·
Replies
12
Views
3K
Replies
6
Views
3K
Replies
5
Views
2K
  • · Replies 10 ·
Replies
10
Views
2K
  • · Replies 11 ·
Replies
11
Views
3K
  • · Replies 1 ·
Replies
1
Views
2K