Taylor series

The tailor series provides a means to predict a function value at one point in
terms of the function value and its derivatives at another point.

The theorem states that any smooth function can be approximated as a
polynomial.



To understand: if u want to determine value of x^100 at x=20. You know
suppose, at x=1 x^100=1. Now with this point (x=1) by using Taylor series you can
determine the value of x^100 at x=20 or others.

How?

Suppose at x=a you know the value of the given function.

From Taylor expansion:
                                ( )∗          ( )∗                  ( )∗
  ( ) = ( )+       ( )∗ℎ+               +            	+ ......+             +
                                  !             !                      !

Here, a= the known point. For this example a=1, f(a) =1.

       h=x-a. Where at x=x f(x) wanted to determine. In this example x=20.

       Rn = Remainder.

Its need infinite term for 100% accuracy.

But as its not possible we cut the series in a significant figure say n. it is called nth
order equation.

To compensate we add a remainder Rn for the remaining term.

If n is equal to the actual order of the analytical equation than Rn is not needed.
Effects of step size:



Suppose,      ( )=         at x=1 f(1)=1. Now we want to know f(2) =?



True value: f(2)=2^4=16

If expand       with Taylor series,

                                                                          ℎ
            ( 	 + 1) = 	      + 	4 ∗    ∗ℎ+6∗         ∗ ℎ + 	2 ∗   ∗ℎ +
                                                                          12


Now, h=1 and X i+1=2, so x= X i+1 – h= 2-1 =1

      f(2)=1+4+6+2+1/12=13.08333

      et= ( (16 – 13.08333) / 16) * 100% = 18.229%



Now h=0.5 and X i+1=2, so x= X i+1 – h = 2 – 0.5 =1.5

      f(2) = 15.5677

      et=2.7018%

Now h=0.25 and X i+1=2, so x= 1.75

      F(2)=15.9417

      et=0.036%

look, as we decreasing step size true error is also decreasing. That means if step
size is smaller, accuracy will be higher.
Effect of order:
Again consider ( ) =

At X i+1 =2 and h = 0.5 we want to determine f(x) by adding term one after one.

So xi=1.5

If we expand      with Taylor series zero order approximation,

         ( 	 + 1) = 	

       f(2)=5.0625

      et = 68.3594%

if we expand with first order approximation,

        ( 	 + 1) = 	      + 	4 ∗     ∗ℎ

      f(2) = 11.8125

      et = 26.1719%



again expand with 2nd order approximation,

        ( 	 + 1) = 	      + 	4 ∗     ∗ℎ+6∗         ∗ℎ

       f(2) = 15.1875

      et = 5.078%

This says that, if we add more terms or increase order, result will goes to close to
the true value.

Taylor series

  • 1.
    Taylor series The tailorseries provides a means to predict a function value at one point in terms of the function value and its derivatives at another point. The theorem states that any smooth function can be approximated as a polynomial. To understand: if u want to determine value of x^100 at x=20. You know suppose, at x=1 x^100=1. Now with this point (x=1) by using Taylor series you can determine the value of x^100 at x=20 or others. How? Suppose at x=a you know the value of the given function. From Taylor expansion: ( )∗ ( )∗ ( )∗ ( ) = ( )+ ( )∗ℎ+ + + ......+ + ! ! ! Here, a= the known point. For this example a=1, f(a) =1. h=x-a. Where at x=x f(x) wanted to determine. In this example x=20. Rn = Remainder. Its need infinite term for 100% accuracy. But as its not possible we cut the series in a significant figure say n. it is called nth order equation. To compensate we add a remainder Rn for the remaining term. If n is equal to the actual order of the analytical equation than Rn is not needed.
  • 2.
    Effects of stepsize: Suppose, ( )= at x=1 f(1)=1. Now we want to know f(2) =? True value: f(2)=2^4=16 If expand with Taylor series, ℎ ( + 1) = + 4 ∗ ∗ℎ+6∗ ∗ ℎ + 2 ∗ ∗ℎ + 12 Now, h=1 and X i+1=2, so x= X i+1 – h= 2-1 =1 f(2)=1+4+6+2+1/12=13.08333 et= ( (16 – 13.08333) / 16) * 100% = 18.229% Now h=0.5 and X i+1=2, so x= X i+1 – h = 2 – 0.5 =1.5 f(2) = 15.5677 et=2.7018% Now h=0.25 and X i+1=2, so x= 1.75 F(2)=15.9417 et=0.036% look, as we decreasing step size true error is also decreasing. That means if step size is smaller, accuracy will be higher.
  • 3.
    Effect of order: Againconsider ( ) = At X i+1 =2 and h = 0.5 we want to determine f(x) by adding term one after one. So xi=1.5 If we expand with Taylor series zero order approximation, ( + 1) = f(2)=5.0625 et = 68.3594% if we expand with first order approximation, ( + 1) = + 4 ∗ ∗ℎ f(2) = 11.8125 et = 26.1719% again expand with 2nd order approximation, ( + 1) = + 4 ∗ ∗ℎ+6∗ ∗ℎ f(2) = 15.1875 et = 5.078% This says that, if we add more terms or increase order, result will goes to close to the true value.