Divided Difference Examples
Divided Difference Examples
03
Newtons Divided Difference Interpolation
More Examples
Electrical Engineering
Example 1
Thermistors are used to measure the temperature of bodies. Thermistors are based on materials
change in resistance with temperature. To measure temperature, manufacturers provide you with
a temperature vs. resistance calibration curve. If you measure resistance, you can find the
temperature. A manufacturer of thermistors makes several observations with a thermistor, which
are given in Table 1.
Table 1 Temperature as a function of resistance.
05.03.1
R ohm
T C
1101.0
911.3
636.0
451.1
25.113
30.131
40.120
50.128
R1 636.0, T ( R1 ) 40.120
gives
b0 T ( R0 )
30.131
T (R 1 ) T (R 0 )
b1
R1 R 0
40.120 30.131
636.0 911.3
0.036284
T ( R) b0 b1 ( R R0 )
30.131 0.036284( R 911.3),
636.0 R 911.3
R
754
.
8
At
T (754.8) 30.131 0.036284(754.8 911.3)
35.809 C
If we expand
T ( R ) 30.131 0.036284( R 911.3),
636.0 R 911.3
we get
T ( R ) 63.197 0.036284 R,
636.0 R 911.3
This is the same expression that was obtained with the direct method.
Example 2
Thermistors are used to measure the temperature of bodies. Thermistors are based on materials
change in resistance with temperature. To measure temperature, manufacturers provide you with
a temperature vs. resistance calibration curve. If you measure resistance, you can find the
temperature. A manufacturer of thermistors makes several observations with a thermistor, which
are given in Table 2.
Table 2 Temperature as a function of resistance.
R ohm
T C
1101.0
911.3
636.0
451.1
25.113
30.131
40.120
50.128
Determine the temperature corresponding to 754.8 ohms using Newtons divided difference
method of interpolation and a second order polynomial. Find the absolute relative approximate
error for the second order polynomial approximation.
Solution
For quadratic interpolation, the temperature is given by
T ( R ) b0 b1 ( R R0 ) b2 ( R R0 )( R R1 )
Since we want to find the temperature at R 754.8 and we are using a second order polynomial,
we need to choose the three data points that are closest to R 754.8 that also bracket R 754.8
to evaluate it. The three points are R0 911.3, R1 636.0 and R2 451.1 .
Then
R0 911.3, T ( R0 ) 30.131
R1 636.0, T ( R1 ) 40.120
R2 451.1, T ( R2 ) 50.128
05.03.4
gives
Hence
Chapter 05.03
b0 T ( R0 )
30.131
T ( R1 ) T ( R0 )
b1
R1 R0
40.120 30.131
636.0 911.3
0.036284
T ( R2 ) T ( R1 ) T ( R1 ) T ( R0 )
R2 R1
R1 R0
b2
R2 R0
50.128 40.120 40.120 30.131
636.0 911.3
451.1 636.0
451.1 911.3
0.054127 0.036284
460.2
3.8771 10 5
T ( R ) b0 b1 ( R R0 ) b2 ( R R0 )( R R1 )
The absolute relative approximate error a obtained between the results from the first and
second order polynomial is
35.089 35.809
a
100
35.089
2.0543%
If we expand,
T ( R) 30.131 0.036284( R 911.3) 3.8771 10 5 ( R 911.3)( R 636.0),
451.1 R 911.3
we get
T R 85.668 0.096275 R 3.8771 10 5 R 2 ,
451.1 R 911.3
This is the same expression that was obtained with the direct method.
Example 3
Thermistors are used to measure the temperature of bodies. Thermistors are based on materials
change in resistance with temperature. To measure temperature, manufacturers provide you with
a temperature vs. resistance calibration curve. If you measure resistance, you can find the
T C
1101.0
911.3
636.0
451.1
25.113
30.131
40.120
50.128
T C
x ln R
1101.0
911.3
636.0
451.1
25.113
30.131
40.120
50.128
7.0040
6.8149
6.4552
6.1117
1
y T
0.039820
0.033188
0.024925
0.019949
Find the calibration curve and find the temperature corresponding to 754.8 ohms. What is the
difference between the results from part (a)? Is the difference larger using results from part (a) or
part (b), if the actual measured value at 754.8 ohms is 35.285 C ?
Solution
a) For cubic interpolation, the temperature is given by
T ( R) b0 b1 ( R R0 ) b2 ( R R0 )( R R1 ) b3 ( R R0 )( R R1 )( R R2 )
Since we want to find the temperature at R 754.8, we need to choose the four data points that
are closest to R 754.8 that also bracket R 754.8 to evaluate it. The four data points are
R0 1101.0, R1 911.3, R2 636.0 and R3 451.1 .
Then
R0 1101.0, T ( R0 ) 25.113
05.03.6
Chapter 05.03
R1 911.3, T ( R1 ) 30.131
R2 636.0, T ( R2 ) 40.120
R3 451.1, T ( R3 ) 50.128
gives
b0 T [ R0 ]
T ( R0 )
25.113
b1 T [ R1 , R0 ]
T ( R1 ) T ( R0 )
R1 R0
30.131 25.113
911.3 1101.0
0.026452
b2 T [ R2 , R1 , R0 ]
T [ R2 , R1 ] T [ R1 , R0 ]
R 2 R0
T ( R2 ) T ( R1 )
T [ R2 , R1 ]
R2 R1
40.120 30.131
636.0 911.3
0.036284
T [ R1 , R0 ] 0.026452
T [ R2 , R1 ] T [ R1 , R0 ]
b2
R 2 R0
0.036284 0.026452
636.0 1101.0
2.1144 10 5
b3 T [ R3 , R2 , R1 , R0 ]
T [ R3 , R2 , R1 ] T [ R2 , R1 , R0 ]
R3 R0
T [ R3 , R2 ] T [ R2 , R1 ]
T [ R3 , R2 , R1 ]
R3 R1
T ( R3 ) T ( R2 )
T [ R3 , R2 ]
R3 R2
50.128 40.120
451.1 636.0
0.054127
T [ R2 , R1 ] 0.036284
T [ R3 , R2 ] T [ R2 , R1 ]
R3 R1
0.054127 0.036284
451.1 911.3
3.8771 10 5
T [ R 2 , R1 , R0 ] 2.1144 10 5
T [ R3 , R2 , R1 ]
b3
T [ R3 , R2 , R1 ] T [ R2 , R1 , R0 ]
R3 R0
3.8771 10 5 2.1144 10 5
451.1 1101.0
2.7124 10 8
Hence
T ( R) b0 b1 ( R R0 ) b2 ( R R0 )( R R1 ) b3 ( R R0 )( R R1 )( R R2 )
The absolute relative approximate error a obtained between the results from the second and
third order polynomial is
35.242 35.089
a
100
35.242
0.43458%
If we expand
T R 25.113 0.026452( R 1101.0) 2.1144 10 5 ( R 1101.0)( R 911.3)
2.7124 10 8 ( R 1101.0)( R 911.3)( R 636.0),
451.1 R 1101.0
we get
T R 92.759 0.13093R 9.2975 10 5 R 2 2.7124 10 8 R 3 , 451.1 R 1101.0
This is the same expression that was obtained with the direct method.
b) Finding the cubic interpolant using Newtons divided difference for
y ( x) b0 b1 ( x x 0 ) b2 ( x x 0 )( x x1 ) b3 ( x x0 )( x x1 )( x x 2 )
requires that we first calculate the new values of x and y .
05.03.8
Then
Chapter 05.03
x ln R
1
y T
7.0040
6.8149
6.4552
6.1117
0.039820
0.033188
0.024925
0.019949
x0 7.0040, y x 0 0.039820
x1 6.8149, y x1 0.033188
x 2 6.4552, y x 2 0.024925
x3 6.1117, y x3 0.019949
gives
b0 y[ x 0 ]
y( x0 )
0.039820
b1 y[ x1 , x 0 ]
y ( x1 ) y ( x0 )
x1 x0
0.033188 0.039820
6.8149 7.0040
0.035069
b2 y[ x 2 , x1 , x 0 ]
y[ x 2 , x1 ] y[ x1 , x 0 ]
x2 x0
y ( x 2 ) y ( x1 )
y[ x 2 , x1 ]
x 2 x1
0.024925 0.033188
6.4552 6.8149
0.022974
y[ x1 , x 0 ] 0.035069
y[ x 2 , x1 ] y[ x1 , x 0 ]
x2 x0
0.022974 0.035069
6.4552 7.0040
0.022040
b2
b3 y[ x3 , x 2 , x1 , x 0 ]
y[ x3 , x 2 , x1 ] y[ x 2 , x1 , x0 ]
x3 x 0
y[ x3 , x 2 ] y[ x 2 , x1 ]
y[ x3 , x 2 , x1 ]
x3 x1
y ( x3 ) y ( x 2 )
y[ x3 , x 2 ]
x3 x 2
0.019949 0.024925
6.1117 6.4552
0.014487
y[ x 2 , x1 ] 0.022974
y[ x3 , x 2 ] y[ x 2 , x1 ]
y[ x3 , x 2 , x1 ]
x3 x1
0.014487 0.022974
6.1117 6.8149
0.012070
y[ x 2 , x1 , x0 ] 0.022040
y[ x3 , x 2 , x1 ] y[ x 2 , x1 , x 0 ]
b3
x3 x 0
0.012070 0.022040
6.1117 7.0040
0.011173
Hence
y ( x) b0 b1 ( x x 0 ) b2 ( x x 0 )( x x1 ) b3 ( x x0 )( x x1 )( x x 2 )
0.039820 0.035069( x 7.0040) 0.022974( x 7.0040)( x 6.8149)
0.011173( x 7.0040)( x 6.8149)( x 6.4552), 6.1117 x 7.0040
Since were looking for the temperature at R 754.8 , we will be using
x ln( 754.8)
6.6265
x
6
.
6265
,
At
y (6.6265) 0.039820 0.035071(6.6265 7.0040)
0.028285
05.03.10
Chapter 05.03
35.355 C
Since the actual measured value at 754.8 ohms is 35.285 C, the absolute relative true error for
the value found in part (a) is
35.285 35.242
t
100
35.285
0.12253%
and for part (b) is
35.285 35.355
t
100
35.285
0.19825%
Therefore, the cubic polynomial interpolant given by Newtons divided difference method, that
is,
T ( R) b0 b1 ( R R0 ) b2 ( R R0 )( R R1 ) b3 ( R R0 )( R R1 )( R R2 )
obtained more accurate results than the calibration curve of
1
b0 b1 (ln R ln R0 ) b2 (ln R ln R0 )(ln R ln R1 ) b3 (ln R ln R0 )(ln R ln R1 )(ln R ln R2 )
T
INTERPOLATION
Topic
Newtons Divided Difference Interpolation
Summary Examples of Newtons divided difference interpolation.
Major
Electrical Engineering
Authors
Autar Kaw
Date
June 10, 2016
Web Site http://numericalmethods.eng.usf.edu