Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Assessment of Interpolation Methods For Solving The Real Life Problem

Download as pdf or txt
Download as pdf or txt
You are on page 1of 6

INTERNATIONAL JOURNAL OF MATHEMATICAL SCIENCES AND APPLICATIONS

Volume 5 • Number 1 • January-June 2015

ASSESSMENT OF INTERPOLATION METHODS FOR SOLVING THE


REAL LIFE PROBLEM
Shadab Hussain1, Vivek Kumar Srivastav2 and Srinivasarao Thota3
1,2,3
Department of Applied Sciences, United Institute of Technology, Allahabad, U.P., India-211010
E-mail: 1shadab.entrepreneur@outlook.com, 2vivekapril@gmail.com, 3srinithota@ymail.com

Abstract: In the present paper, four different interpolation methods, namely Newton-Gregory Forward, Newton-
Gregory Backward, Lagrange and Newton divided difference, are used for solving the real life problem. These
methods are used to solve the following problem:
The following table represents the number of students obtained marks in the specified ranges. From the table, our
aim is to estimate the number of students who obtained marks between 40 and 45.

Marks 30-40 40-50 50-60 60-70 70-80


Number of students 31 42 51 35 31

The estimated result shows that first two interpolation methods (Newton-Gregory Forward and Newton-Gregory
Backward) give the same values. Since the range (40-45) is near to the starting point therefore Newton-forward is
suitable for this case however Newton backward method is found computationally expensive for this case. The last
two methods (Lagrange and Newton divided difference) are generally used for unequal intervals. All four methods
are gives same results but computational point of view, the last three are more expensive because of the point of
interest and equation complexity.
Keywords: Interpolation methods, Real life problem, equal and unequal intervals.

1. INTRODUCTION
Interpolation techniques are used to find the value of function at any point using given data points. It is very useful
for interpolating the experimental data because during the experimentation it is not always possible to take all the
readings. There are several methods for interpolating the data but difficult to solves all the problems because of
their limitations. In the present work only four methods are used to solve a particular problem therefore the
following paragraphs discuss only these methods:
Newton: Gregory forward and backward methods are used to solve those problems where point of interest is
near to starting and ending point respectively. Also, these two methods are applies for equal intervals. However,
Lagrange and Newton's-divided interpolation techniques are used for both equal and unequal intervals. Lagrange
and Newton's divided difference methods needs more calculations than other two methods [1, 2].
Generally, the real life problems have large data points at different locations. Therefore in those cases Newton-
Gregory forward and backward fails to solve because of its limitation of equal intervals.
The mathematical formulations of all these methods are discussed in the following section:

2. PROBLEM DEFINITION
In this section, the specified problem is solved using the four methods.
92 SHADAB HUSSAIN, VIVEK KUMAR SRIVASTAV AND SRINIVASARAO THOTA

2.1 Newton’s Forward Difference Formula


Newton’s forward difference formula is

u (u � 1) 2 u (u � 1)(u � 2)� (u � n � 1) n
f ( a � hu ) � f ( a) � u �f (a ) � � f (a) � � � � f ( a) (1)
2 n

The following Table-1 is forward difference table and used for finding the value of f (45):

Table 1: Forward Difference Table

x y = f(x) � f (x) ��f (x) ��f (x) ��f(x)


40 31
50 73 42
60 124 51 9
70 159 35 –16 –25
80 190 31 –4 12 37

First Term, a = 40, interval h = 10 and a + hu = 45, therefore u = 0.5. Putting the values in the above
mentioned formula (1):

u (u � 1) 2
f (45) � f (40) � u �f (40) � � f (40)
2
u (u � 1)(u � 2) 3 u (u � 1)(u � 2)(u � 3) 4
� � f (40) � � f (40)
3 4
0.5 � (0.5 � 1)
� 31 � 0.5 � 42 � �9
2
0.5 � (0.5 � 1)(0.5 � 2) 0.5 � (0.5 � 1)(0.5 � 2)(0.5 � 3)
� � � �25 � � � 37
3 4
� 47.8672 � 48

Hence, the number of students getting marks less than 45 is 48, but the number of students getting marks less
than 40 is 31. Therefore the number of students getting marks between 40 and 45 is 48 – 31 = 17.

2.2 Newton’s Backward Difference Formula


Newton’s backward difference formula is

f (a � nh � uh) � f (a � nh) � u�f (a � nh)


u (u � 1) 2 u (u � 1) � (u � n � 1) n
� � f (a � nh) � � � � f (a � nh) (2)
2 n
ASSESSMENT OF INTERPOLATION METHODS FOR SOLVING THE REAL LIFE PROBLEM 93

The following Table-2 is backward difference table and used for finding the value of f (45):

Table 2: Backward Difference Table

x y = f(x) � f (x) ��f (x) ��f (x) ��f(x)


40 31
50 73 42
60 124 51 9
70 159 35 –16 –25 37
80 190 31 –4 12

First Term, a = 40, interval h = 10 and a + hu = 80 and also n = 4, therefore u = – 3.5. Putting the values in
the above mentioned formula (2):

u (u � 1) 2 u (u � 1)(u � 2) 3
f (45) � y (80) � u�y (80) � � y (80) � � y (80)
2 3
u (u � 1)(u � 2)(u � 3) 4
� � y (80)
4

� 190 � � �3.5 � � 31 �
� �3.5�� �3.5 � 1� �
� �4 �
2
� �3.5 �� �3.5 � 1� (�3.5 � 2) � �3.5 �� �3.5 � 1� (�3.5 � 2)(�3.5 � 3)
� � 12 � � 37
3 4
� 47.8672 � 48

Hence, number of students getting marks less than 45 is 48. Therefore as mentioned in above method, the
number of students getting marks between 40 and 45 is 17.

2.3 Lagrange Interpolation Formula


The Lagrange interpolation formula for this problem is

( x � x1 )( x � x2 )( x � x3 )( x � x4 ) ( x � x0 )( x � x2 )( x � x3 )( x � x4 )
f ( x) � f ( x0 ) � f ( x1 )
( x0 � x1 )( x0 � x2 )( x0 � x3 )( x0 � x4 ) ( x1 � x0 )( x1 � x2 )( x1 � x3 )( x1 � x4 )
( x � x0 )( x � x1 )( x � x3 )( x � x4 ) ( x � x0 )( x � x1 )( x � x2 )( x � x4 )
� f ( x2 ) � f ( x3 ) (3)
( x2 � x0 )( x2 � x1 )( x2 � x3 )( x2 � x4 ) ( x3 � x0 )( x3 � x1 )( x3 � x2 )( x3 � x4 )
( x � x0 )( x � x1 )( x � x2 )( x � x3 )
� f ( x4 )
( x4 � x0 )( x4 � x1 )( x4 � x2 )( x4 � x3 )

Putting all these values of x0 = 40, x1 = 50, x2 = 60, x3 = 70 and x4 = 80 and corresponding functions are
f(x0) = 31, f(x1) = 42, f(x2) = 51, f(x3) = 35 and f(x4) = 31 in formula (3). We have to find the value of f(x) at x
= 45. Now
94 SHADAB HUSSAIN, VIVEK KUMAR SRIVASTAV AND SRINIVASARAO THOTA

(45 � 50)(45 � 60)(45 � 70)(45 � 80) (45 � 40)(45 � 60)(45 � 70)(45 � 80)
f (45) � � 31 � � 73
(40 � 50)(40 � 60)(40 � 70)(40 � 80) (50 � 40)(50 � 60)(50 � 70)(50 � 80)
(45 � 40)(45 � 50)(45 � 70)(45 � 80) (45 � 40)(45 � 50)(45 � 60)(45 � 80)
� �124 � � 159
(60 � 40)(60 � 50)(60 � 70)(60 � 80) (70 � 40)(70 � 50)(70 � 60)(70 � 80)
(45 � 40)(45 � 50)(45 � 60)(45 � 70)
� � 190
(80 � 40)(80 � 50)(80 � 60)(80 � 70)
� 8.4765625 � 79.84375 � ( �67.8125) � 34.78125 � ( �7.421875)
� 47.8671875 � 48
Therefore, Number of students getting marks between 40 and 45 = 48 – 31 = 17

2.4 Newton-Divided Interpolation Formula


The Newton-Divided interpolation formula for this problem is

f ( x ) � f (0) � ( x � x0 )� f (0) � ( x � x0 )( x � x1 )�2 f (0) � ( x � x0 )( x � x1 )( x � x2 )�3 f (0)


(4)
� ( x � x0 )( x � x1 )( x � x2 )( x � x3 )�4 f (0)

Below in the mentioned table, we have given the calculated values which will be used for calculating f(45):

x y=f(x) ?f ?2 f ?3f ?4f


40 31
50 73 4.2
60 124 5.1 0.045
70 159 3.5 –0.08 4.17*10–3 1.54 *1 0– 4

80 190 3.1 –0.02 – 2*10–3

Putting all these values in the above mentioned formula (4):

f (45) � 31 � (45 � 40)4.2 � (45 � 40)( x � 50)0.045


� (45 � 40)(45 � 50)(45 � 60)( �0.00417)
� (45 � 40)(45 � 50)(45 � 60)(45 � 70)(0.0001542)

� 47.86718790625 � 48
Therefore, Number of students getting marks between 40 and 45 is 17.
It is found from all the methods that the number of students getting marks between 40 and 45 are 17.

3. RESULTS AND DISCUSSION


The solutions are obtained by all the methods i.e., Newton-Gregory Forward and Backward formula, Lagrange's
formula and Newton-Divided formula and then it is compared analytically. The result obtained by all the methods
is found to be approximately equal. Hence this result gives us an expanding opportunity to find the solution by any
of these methods. Since the range (40-45) is near the starting of the given data therefore Newton-forward is
suitable for this case however Newton backward method is found computationally expensive for this case. Rests
ASSESSMENT OF INTERPOLATION METHODS FOR SOLVING THE REAL LIFE PROBLEM 95

of the two methods (Lagrange and Newton-Divided difference method) are also useful but analytically more
expensive from calculation point of view.

REFERENCES
[1] G. Manish, N. P. Bali: “A Text Book of Engineering Mathematics”, University Science Press, 6th Edition,
2013.
[2] H.K. Das and Rama Verma: “Introduction to Engineering Mathematics”, 3, 5th edition, 2014.

You might also like