← 2025 Paper 2
UPSC 2025 Maths Optional Paper 2 Q7b — Step-by-Step Solution 15 marks · Section B
Lagrange's interpolation · Numerical Analysis · asked 5× in 13 yrs · Read the full method →
Question
Find the unique polynomial of degree 2 or less which fits the following data:
x : 0 , 1 , 3 f ( x ) : 1 , 3 , 55 x : 0, 1, 3 \qquad f(x) : 1, 3, 55 x : 0 , 1 , 3 f ( x ) : 1 , 3 , 55
Also obtain the bound on the truncation error.
Technique
Use Newton’s divided-difference interpolation on the three unequally spaced points to get the unique polynomial of degree ≤ 2 \le 2 ≤ 2 . The truncation error uses the standard remainder f ( x ) − P 2 ( x ) = f ′ ′ ′ ( ξ ) 3 ! ω ( x ) f(x) - P_2(x) = \dfrac{f'''(\xi)}{3!}\,\omega(x) f ( x ) − P 2 ( x ) = 3 ! f ′′′ ( ξ ) ω ( x ) with ω ( x ) = ( x − x 0 ) ( x − x 1 ) ( x − x 2 ) \omega(x) = (x-x_0)(x-x_1)(x-x_2) ω ( x ) = ( x − x 0 ) ( x − x 1 ) ( x − x 2 ) .
Solution
Data points: ( x 0 , f 0 ) = ( 0 , 1 ) (x_0,f_0) = (0,1) ( x 0 , f 0 ) = ( 0 , 1 ) , ( x 1 , f 1 ) = ( 1 , 3 ) (x_1,f_1) = (1,3) ( x 1 , f 1 ) = ( 1 , 3 ) , ( x 2 , f 2 ) = ( 3 , 55 ) (x_2,f_2) = (3,55) ( x 2 , f 2 ) = ( 3 , 55 ) .
Newton’s divided differences
First order:
f [ x 0 , x 1 ] = 3 − 1 1 − 0 = 2 , f [ x 1 , x 2 ] = 55 − 3 3 − 1 = 52 2 = 26. f[x_0,x_1] = \frac{3 - 1}{1 - 0} = 2,\qquad f[x_1,x_2] = \frac{55 - 3}{3 - 1} = \frac{52}{2} = 26. f [ x 0 , x 1 ] = 1 − 0 3 − 1 = 2 , f [ x 1 , x 2 ] = 3 − 1 55 − 3 = 2 52 = 26.
Second order:
f [ x 0 , x 1 , x 2 ] = 26 − 2 3 − 0 = 24 3 = 8. f[x_0,x_1,x_2] = \frac{26 - 2}{3 - 0} = \frac{24}{3} = 8. f [ x 0 , x 1 , x 2 ] = 3 − 0 26 − 2 = 3 24 = 8.
P 2 ( x ) = f 0 + f [ x 0 , x 1 ] ( x − x 0 ) + f [ x 0 , x 1 , x 2 ] ( x − x 0 ) ( x − x 1 ) . P_2(x) = f_0 + f[x_0,x_1](x - x_0) + f[x_0,x_1,x_2](x - x_0)(x - x_1). P 2 ( x ) = f 0 + f [ x 0 , x 1 ] ( x − x 0 ) + f [ x 0 , x 1 , x 2 ] ( x − x 0 ) ( x − x 1 ) .
P 2 ( x ) = 1 + 2 ( x − 0 ) + 8 ( x − 0 ) ( x − 1 ) = 1 + 2 x + 8 x 2 − 8 x . P_2(x) = 1 + 2(x - 0) + 8(x - 0)(x - 1) = 1 + 2x + 8x^2 - 8x. P 2 ( x ) = 1 + 2 ( x − 0 ) + 8 ( x − 0 ) ( x − 1 ) = 1 + 2 x + 8 x 2 − 8 x .
P 2 ( x ) = 8 x 2 − 6 x + 1. \boxed{P_2(x) = 8x^2 - 6x + 1.} P 2 ( x ) = 8 x 2 − 6 x + 1.
Check: P 2 ( 0 ) = 1 P_2(0)=1 P 2 ( 0 ) = 1 , P 2 ( 1 ) = 8 − 6 + 1 = 3 P_2(1)=8-6+1=3 P 2 ( 1 ) = 8 − 6 + 1 = 3 , P 2 ( 3 ) = 72 − 18 + 1 = 55 P_2(3)=72-18+1=55 P 2 ( 3 ) = 72 − 18 + 1 = 55 . ✓
Truncation-error bound
For interpolation at three nodes, the error at a point x x x is
E ( x ) = f ( x ) − P 2 ( x ) = f ′ ′ ′ ( ξ ) 3 ! ω ( x ) , ω ( x ) = x ( x − 1 ) ( x − 3 ) , E(x) = f(x) - P_2(x) = \frac{f'''(\xi)}{3!}\,\omega(x),\qquad \omega(x) = x(x-1)(x-3), E ( x ) = f ( x ) − P 2 ( x ) = 3 ! f ′′′ ( ξ ) ω ( x ) , ω ( x ) = x ( x − 1 ) ( x − 3 ) ,
for some ξ \xi ξ in the smallest interval containing { 0 , 1 , 3 , x } \{0,1,3,x\} { 0 , 1 , 3 , x } . Hence
∣ E ( x ) ∣ ≤ M 3 6 ∣ ω ( x ) ∣ , M 3 = max [ 0 , 3 ] ∣ f ′ ′ ′ ( ξ ) ∣ . |E(x)| \le \frac{M_3}{6}\,|\omega(x)|,\qquad M_3 = \max_{[0,3]}|f'''(\xi)|. ∣ E ( x ) ∣ ≤ 6 M 3 ∣ ω ( x ) ∣ , M 3 = [ 0 , 3 ] max ∣ f ′′′ ( ξ ) ∣.
To bound ∣ ω ( x ) ∣ |\omega(x)| ∣ ω ( x ) ∣ on [ 0 , 3 ] [0,3] [ 0 , 3 ] : ω ′ ( x ) = 3 x 2 − 8 x + 3 = 0 \omega'(x) = 3x^2 - 8x + 3 = 0 ω ′ ( x ) = 3 x 2 − 8 x + 3 = 0 gives x = 8 ± 64 − 36 6 = 4 ± 7 3 x = \dfrac{8 \pm \sqrt{64-36}}{6} = \dfrac{4 \pm \sqrt7}{3} x = 6 8 ± 64 − 36 = 3 4 ± 7 , i.e. x ≈ 0.4514 , 2.2153 x \approx 0.4514,\,2.2153 x ≈ 0.4514 , 2.2153 . Evaluating:
∣ ω ( 0.4514 ) ∣ ≈ 0.6311 , ∣ ω ( 2.2153 ) ∣ ≈ 2.1126 , |\omega(0.4514)| \approx 0.6311,\qquad |\omega(2.2153)| \approx 2.1126, ∣ ω ( 0.4514 ) ∣ ≈ 0.6311 , ∣ ω ( 2.2153 ) ∣ ≈ 2.1126 ,
and ω = 0 \omega = 0 ω = 0 at the nodes. So
max [ 0 , 3 ] ∣ ω ( x ) ∣ = ∣ ω ( 2.2153 ) ∣ ≈ 2.1126 ( exactly at x = 4 + 7 3 ) . \max_{[0,3]}|\omega(x)| = |\omega(2.2153)| \approx 2.1126\quad\Big(\text{exactly at } x = \tfrac{4+\sqrt7}{3}\Big). [ 0 , 3 ] max ∣ ω ( x ) ∣ = ∣ ω ( 2.2153 ) ∣ ≈ 2.1126 ( exactly at x = 3 4 + 7 ) .
Therefore the uniform bound on the truncation error over [ 0 , 3 ] [0,3] [ 0 , 3 ] is
∣ f ( x ) − P 2 ( x ) ∣ ≤ M 3 6 max [ 0 , 3 ] ∣ ω ( x ) ∣ ≈ M 3 6 ( 2.1126 ) ≈ 0.3521 M 3 , M 3 = max [ 0 , 3 ] ∣ f ′ ′ ′ ∣ . \boxed{\,|f(x) - P_2(x)| \le \frac{M_3}{6}\,\max_{[0,3]}|\omega(x)| \approx \frac{M_3}{6}(2.1126) \approx 0.3521\,M_3,\quad M_3 = \max_{[0,3]}|f'''|.} ∣ f ( x ) − P 2 ( x ) ∣ ≤ 6 M 3 [ 0 , 3 ] max ∣ ω ( x ) ∣ ≈ 6 M 3 ( 2.1126 ) ≈ 0.3521 M 3 , M 3 = [ 0 , 3 ] max ∣ f ′′′ ∣.
(If the underlying f f f is itself a polynomial of degree ≤ 2 \le 2 ≤ 2 , then f ′ ′ ′ ≡ 0 f''' \equiv 0 f ′′′ ≡ 0 and the interpolation is exact.)
Answer
P 2 ( x ) = 8 x 2 − 6 x + 1 P_2(x) = 8x^2 - 6x + 1 P 2 ( x ) = 8 x 2 − 6 x + 1 . Truncation error E ( x ) = f ′ ′ ′ ( ξ ) 6 x ( x − 1 ) ( x − 3 ) E(x) = \dfrac{f'''(\xi)}{6}\,x(x-1)(x-3) E ( x ) = 6 f ′′′ ( ξ ) x ( x − 1 ) ( x − 3 ) , bounded on [ 0 , 3 ] [0,3] [ 0 , 3 ] by M 3 6 max ∣ ω ∣ ≈ 0.3521 M 3 \dfrac{M_3}{6}\max|\omega| \approx 0.3521\,M_3 6 M 3 max ∣ ω ∣ ≈ 0.3521 M 3 , the maximum of ∣ ω ∣ |\omega| ∣ ω ∣ occurring at x = 4 + 7 3 x = \tfrac{4+\sqrt7}{3} x = 3 4 + 7 .