Understanding Interpolation in Numerical Methods

Slide Note
Embed
Share

Interpolation is a fundamental mathematical operation used in numerical methods to find the value of a function between known data points. It involves computing the value of a function at any point within a given interval based on existing data. Newton's forward interpolation formula is commonly used for this purpose. In this technique, values are interpolated based on equi-distant intervals to estimate unknown values. This method is applied to interpolate values near the beginning of tabular data. An example problem involving the interpolation of steam pressure based on temperature data illustrates the practical application of Newton's formula.


Uploaded on Aug 04, 2024 | 0 Views


Download Presentation

Please find below an Image/Link to download the presentation.

The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author. Download presentation by click this link. If you encounter any issues during the download, it is possible that the publisher has removed the file from their server.

E N D

Presentation Transcript


  1. NUMERICAL METHODS

  2. INTERPOLATION AND SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL EQUATIONS. INTRODUCTION

  3. Interpolation denotes the process of computing the value of a function for any value of the independent variable within the interval for which some values are given.

  4. Interpolation is a fundamental operation in mathematics it has been described as a art of reading between the lines of the tables.

  5. Suppose the following table represents a set of corresponding values of two equations X and y . X : x x x ..xn Y : y y y yn. We may require the value of y=yr corresponding to a value x=xr between x0 and xn .

  6. Suppose the following table represents a set of corresponding values of two equations X and y . X : x x x ..xn Y : y y y yn. We may require the value of y=yr corresponding to a value x=xr between x0 and xn . Thus interpolation denotes the process of computing the value of a function for any value of the independent variable within the interval for which some values are given.

  7. The term extrapolation is used to denote the process of finding the values outside this interval. However the term interpolation is supplied to both process. Example : Y=X3+2X+5

  8. Let yX=f(x) be a function which takes a value y0,y1,y2 .yn corresponding to the value x0,x1,x2 .xn of the independent variable of x. let the value of x be at the equi-distant intervals. yp=y0+p y0+p(p-1) 2y0+ p(p-1)(p-2) 3y0+ 2 3 p(p-1(p-2) (p-(n-1)) ny0 It is known as newtons forward interpolation formula. n

  9. This formula is used to interpolate the value of y near the beginning of a set of tabular value. Problem 1.Following are the data from the steam table. Temperature C 140 180 Pressure 3.685 4.854 6.302 8.076 10.225 Using newtons formula find the pressure of a steam for a temperature 142 ? 150 160 170

  10. Solution: x 140 150 160 6.302 170 8.076 180 10.225 yp=y0+p y0+p(p-1) 2y0+ p(p-1)(p-2) 3y0+ 2 3 p(p-1(p-2) (p-(n-1)) ny0 y0=3.685 p=x-x0 y0=1.169 2y0=0.279 3y0=0.047 4y0=0.002 Yp=3.685+0.2(1.169)+0.2(0.2-1)0.279+0.2(0.2-1)(0.2-2)0.047+0.2(0.2- 2 6 24 1)(0.2-2)(0.2-3)0.002 24 =3.685+0.2338+0.0223+0.0022+0.00007 =3.89863 =3.899 y 3.685 4.854 y 1.169 1.448 1.774 2.149 2y 0.279 0.326 0.375 3y 0.047 0.049 4y 0.002 n h =(142-140)/10=0.2

  11. 2.Following data gives the value x and y. find the value of y when x is 21. From the table X 20 23 Y 0.3420 0.3907 Solution: x y y 120 0.3420 0.0487 23 0.3907 0.0477 26 0.4384 0.0464 29 0.4848 Formula yp=y0+p y0+p(p-1) 2y0+ p(p-1)(p-2) 3y0+ p(p-1(p-2) (p-(n-1)) ny0 Y0=0.3420 y0=0.0487 2y0=-0.001 3y0=0.0003 yp= 0.3420+0.3(0.0487)+0.3(0.3-1)(-0.001)+0.3(0.3-1)(0.3-2)0.0003 2 =0.3420+0.01461+0.000105+0.00001785 =0.3567 26 0.4384 29 0.4848 2y -0.001 -0.0013 3y 0.0003 2 3 n p=x-x0 h =(21-20)/3=0.3 6

  12. 3.Using newtons forward interpolation formula. Calculate x is 1.02 upto 3 decimal places in the table given below X 1.0 1.1 1.2 1.3 F(x) 0.841 0.89 1.932 0.964 Solution X f(x) y 1.0 0.841 0.05 1.1 0.891 0.041 1.2 0.932 0.032 1.3 0.964 0.021 1.4 0.985 yp=y0+p y0+p(p-1) 2y0+ p(p-1)(p-2) 3y0+ p(p-1(p-2) (p-(n-1)) ny0 y0=0.841 y0=0.05 2y0=-0.009 3y0=0 4y0=-0.002 Yp=0.841+0.2(0.05)+0.2(0.2-1)(-0.009)+0.2(0.2-1)(0.2-2)0+0.2(0.2-1)(0.2-2)(0.2-3)(-0.009) 2 6 =0.841+0.01+0.00072+0+0.0000672 =0.851 1.4 0.985 2y -0.009 3y 0 4y -0.002 -0.0009 -0.011 -0.002 2 3 n p=x-x0 h =(1.02-1)/0.1=0.2 24

  13. NEWTONS GREGORY BACKWARD INTERPOLATION FORMULA Let yx=f(x) be a function which takes the value y0,y1,y2 .yn corresponding to the value x0,x1,x2 .xn of the independent variable x. let the value of x be at equi-distance intervals. Let x=xn + ph Yp=yn+ p yn+p(p+1) 2yn+ p(p+1)(p+2) 3yn + p(p+1(p+2) (p+(n-1)) nyn Note: This formula is used to interpolate the value of y near the end of a set of tabular values . Problem: 2 3 n

  14. From the following table of half yearly premium of policies maturing at qunnial ages estimate the premium for polices maturing at age 63 Age(x) : 45 50 55 Premium(y): 114.84 96.16 83.32 Solution: Age premium y 2y 45 114.84 -18.68 5.84 50 96.16 -12.84 4 55 83.32 -8.84 2.84 60 74.48 -6 65 68.4 Formula: Yp=yn+ p yn+p(p+1) 2yn+ p(p+1)(p+2) 3yn + p(p+1(p+2) (p+(n-1)) nyn yn=68.48 yn=-6 2yn=2.84 3yn=-1.16 Yp=68.48+(-0.4)(-6)+(-0.4)(0.4+1)2.84+(-0.4)(-0.2+1)(-0.4+2)(-1.16)+(-0.4)(-0.2+1)(-0.4+2)(0.4+3)(0.68) 2 =68.48+2.4-0.3400+0.07424-0.02828 =70.58 60 74.48 65 64.48 3y 4y -1-84 0.68 -1.16 2 3 n 6 24

  15. 2. The amount A of a substance remaining reacting of interveral of time t in certain chemical experiment is given below T(min) 2 5 8 A(gm) 94.8 87.9 81.3 Obtain the value of A where t=9 mints using newton backward difference interpolation formula. T A y 2 94.8 -6.9 5 87.9 -6.6 8 81.3 -6.2 11 75.1 Yp=yn+ p yn+p(p+1) 2yn+ p(p+1)(p+2) 3yn + p(p+1(p+2) (p+(n-1)) nyn yn=75.1 yn=-6.2 2yn=0.4 3yn=0.1 Yp=75.1+(-0.6)(-6.2)+(-0.6)(0.6+1)0.4+(-0.6)(-0.6+1)(-0.6+2)(0.1) 2 =75.1-3.72-0.048-0.0056+4.12 =79.20 11 75.1 2y 0.3 3y 0.1 0.4 2 3 n 6

  16. 3.Using newtons formula the value of x=27 X 10 15 Y 35.4 32.2 Solution: X y y 10 35.4 -3.2 15 32.2 -3.1 20 29.1 -3.1 25 26 -2.9 30 23.1 Yp=yn+ p yn+p(p+1) 2yn+ p(p+1)(p+2) 3yn + p(p+1(p+2) (p+(n-1)) nyn yn=23.1 yn=-2.9 2yn=0.2 3yn=0.2 4yn=0.3 Yp=23.1+(-0.6)(-2.9)+(-0.6)(0.6+1)0.2+(-0.6)(-0.6+1)(-0.6+2)(0.2) +(-0.6)(-0.6+1)(- 2 6 24 0.6+2)(0.3) =23.1+1.74+-0.024-0.01008-0.0112 =24.7947 20 29.1 25 26 30 23.1 2y 0.1 0 0.2 3y -0.1 0.2 4y 0.3 2 3 n

  17. LAGRANGES INTERPOLATION FORMULA Let f(x) = y be a function which takes the values y0,y1,y2 yn corresponding to the value x = x0,x1,x2 .xn .Since there are n+1 values of y corresponding to n+1 value of x. we can represent the function f(x) by a polynomial in x of degree n. y=f(x)=(x-x1)(x-x2) .(x-xn)y0 + (x-x0)(x-x2) .(x-xn)y1+ +(x-x0)(x-x1) .(x-xn-1)yn (x0-x1)(x0-x2) .(x0-xn) (x1-x0)(x1-x2) .(x1-xn) (xn-x0)(xn-x1) .(xn-xn-1) is known as lagrange s interpolation formula. It can be used whether the values x0,x1,x2 .xn are equally spaced or not and whether the differences of y become smaller or not.

  18. 1.Given the values 17 f(x): 64 find the value of f(x) corresponding of x=27 x :14 31 35 44 39.1 solution: since there are only fours corresponding pairs of values given in the polynomial representing the data is x0=14 y0=68.7 y1=64 x1=17 x2=31 x3=35 y2=44 y3=39.1 by lagrange s interpolation formula y=f(x)=(x-x1)(x-x2) .(x-xn)y0 + (x-x0)(x-x2) .(x-xn)y1+ +(x-x0)(x- x1) .(x-xn-1)yn (x0-x1)(x0-x2) .(x0-xn) (x1-x0)(x1-x2) .(x1-xn) (xn-x0)(xn- x1) .(xn-xn-1) = (27-17)(27-31)(27-35)68.7+(27-17)(27-31)(27-35)64+ (27-17)(27-31)(27-35)44 (14-17)(14-31)(14-35) (17-14)(17-31)(17-35) (31-14)(31-17)(31-35) +(27-14)(27-31)(27-17)39.1 (35.4-14)(35-17)(35-31) =20.5266+35.2169+48.0672-13.4479 =49.3104

Related


More Related Content