Browse papers
A

Section A: Long Answer Questions

Attempt all / any as specified.

4 questions
1long12 marks

(a) Derive the iterative formula for the Newton-Raphson method for finding a real root of the equation f(x)=0f(x)=0, and state its order of convergence. Mention two situations in which the method fails. [6]

(b) Find a real root of the equation x32x5=0x^3 - 2x - 5 = 0 correct to four decimal places using the Newton-Raphson method, taking x0=2x_0 = 2. Compare the number of iterations required with the Bisection method to achieve the same accuracy in the interval [2,3][2, 3]. [6]

(a) Newton-Raphson iterative formula

Let xnx_n be an approximation to a root of f(x)=0f(x)=0. Expanding ff in a Taylor series about xnx_n and retaining the linear term:

f(xn+h)f(xn)+hf(xn)=0    h=f(xn)f(xn).f(x_n + h) \approx f(x_n) + h\,f'(x_n) = 0 \;\Rightarrow\; h = -\frac{f(x_n)}{f'(x_n)}.

Since the improved estimate is xn+1=xn+hx_{n+1}=x_n+h, the Newton-Raphson formula is:

xn+1=xnf(xn)f(xn),f(xn)0\boxed{\,x_{n+1} = x_n - \dfrac{f(x_n)}{f'(x_n)},\quad f'(x_n)\neq 0\,}

Order of convergence. If α\alpha is a simple root, the error satisfies en+1f(α)2f(α)en2e_{n+1}\approx \dfrac{f''(\alpha)}{2f'(\alpha)}e_n^{2}, so the method is quadratically convergent (order 2).

Two situations in which it fails:

  1. When f(xn)=0f'(x_n)=0 (or is very small) at an iterate — the tangent is horizontal and xn+1x_{n+1}\to\infty.
  2. When the initial guess is poor or near a turning point/inflection — iterates may oscillate or diverge (it also converges only linearly at a multiple root).

(b) Root of x32x5=0x^3-2x-5=0

Here f(x)=x32x5f(x)=x^3-2x-5, f(x)=3x22f'(x)=3x^2-2. With x0=2x_0=2:

nnxnx_n
02.000000
12.100000
22.094568
32.094551
42.094551

So the root, correct to four decimals, is   x2.0946\;x \approx 2.0946, reached in 3 iterations.

Comparison with Bisection on [2,3][2,3]. Bisection needs nn such that ba2n104\dfrac{b-a}{2^{n}}\le 10^{-4}, i.e. 12n1042n104nlog210413.3\dfrac{1}{2^{n}}\le 10^{-4}\Rightarrow 2^{n}\ge 10^{4}\Rightarrow n\ge \log_2 10^{4}\approx 13.3. Hence Bisection requires about 14 iterations.

Conclusion: Newton-Raphson reaches the same accuracy in ~3 iterations versus ~14 for Bisection, reflecting its quadratic versus linear convergence.

roots-of-equationsnewton-raphsonbisection
2long12 marks

(a) Construct Newton's divided difference table for the following data and hence estimate the value of f(3)f(3).

xx01245
f(x)f(x)2312147326

[7]

(b) Explain why Newton's divided difference formula is preferred over Lagrange's interpolation formula when a new data point is added to an existing set. Illustrate your answer briefly. [5]

(a) Newton's divided difference table

Data: x=0,1,2,4,5x=0,1,2,4,5, f=2,3,12,147,326f=2,3,12,147,326.

xxff1st DD2nd DD3rd DD4th DD
02
1
134
93.875
21219.50.10833
67.54.41667
414741.5
179
5326

Sample computations: f[0,1]=3210=1f[0,1]=\frac{3-2}{1-0}=1, f[1,2]=12321=9f[1,2]=\frac{12-3}{2-1}=9, f[0,1,2]=9120=4f[0,1,2]=\frac{9-1}{2-0}=4, etc.

Newton's divided-difference polynomial:

f(x)=2+1(x0)+4(x0)(x1)+3.875(x0)(x1)(x2)+0.10833(x0)(x1)(x2)(x4).f(x)=2 + 1\,(x-0) + 4\,(x-0)(x-1) + 3.875\,(x-0)(x-1)(x-2) + 0.10833\,(x-0)(x-1)(x-2)(x-4).

Estimate f(3)f(3): with x=3x=3,

f(3)=2+(3)+4(3)(2)+3.875(3)(2)(1)+0.10833(3)(2)(1)(1).f(3)=2 + (3) + 4(3)(2) + 3.875(3)(2)(1) + 0.10833(3)(2)(1)(-1). f(3)=2+3+24+23.250.6551.6.f(3)=2 + 3 + 24 + 23.25 - 0.65 \approx \boxed{51.6}.

(b) Why divided differences are preferred when a point is added

When a new data point is appended, Newton's divided-difference formula only requires one extra term to be computed and added — all previously computed differences and coefficients remain valid:

Pn+1(x)=Pn(x)+f[x0,,xn+1]i=0n(xxi).P_{n+1}(x)=P_n(x)+f[x_0,\dots,x_{n+1}]\prod_{i=0}^{n}(x-x_i).

In contrast, Lagrange's formula must be rebuilt entirely, because every basis polynomial Li(x)L_i(x) contains the factor (xxnew)(x-x_{new}) and every denominator changes, forcing a full recomputation.

Illustration: Given points at x=0,1,2x=0,1,2 we have a quadratic; adding x=4x=4 in Newton's form just adds the term 3.875(x)(x1)(x2)3.875\,(x)(x-1)(x-2), whereas Lagrange requires recomputing all four basis polynomials from scratch. Hence Newton's form is more economical and incremental.

interpolationnewton-divided-differencelagrange
3long12 marks

(a) Derive the composite Simpson's 1/31/3 rule for numerical integration and write down the expression for its error term. [6]

(b) Evaluate 06dx1+x2\displaystyle\int_{0}^{6}\frac{dx}{1+x^2} by taking 6 sub-intervals using (i) the Trapezoidal rule and (ii) Simpson's 1/31/3 rule. Compare both results with the exact value and comment on the accuracy. [6]

(a) Composite Simpson's 1/3 rule

Divide [a,b][a,b] into an even number nn of equal sub-intervals of width h=banh=\dfrac{b-a}{n}, with nodes xi=a+ihx_i=a+ih. Over each pair of strips [x2k,x2k+2][x_{2k},x_{2k+2}], approximating ff by a parabola gives

x2kx2k+2fdxh3(f2k+4f2k+1+f2k+2).\int_{x_{2k}}^{x_{2k+2}} f\,dx \approx \frac{h}{3}\big(f_{2k}+4f_{2k+1}+f_{2k+2}\big).

Summing over all pairs:

abfdxh3[f0+fn+4 ⁣ ⁣iodd ⁣ ⁣fi+2 ⁣ ⁣ieveni0,n ⁣ ⁣fi].\boxed{\int_a^b f\,dx \approx \frac{h}{3}\Big[f_0+f_n + 4\!\!\sum_{i\,\text{odd}}\!\! f_i + 2\!\!\sum_{i\,\text{even}}^{i\neq 0,n}\!\! f_i\Big].}

Error term. The composite error is

E=(ba)h4180f(4)(ξ),a<ξ<b,E = -\frac{(b-a)h^{4}}{180}\,f^{(4)}(\xi),\qquad a<\xi<b,

so the rule is O(h4)O(h^4) and is exact for polynomials up to degree 3.

(b) Evaluate 06dx1+x2\displaystyle\int_0^6 \frac{dx}{1+x^2}, n=6n=6, h=1h=1

Nodes and values of f(x)=11+x2f(x)=\frac{1}{1+x^2}:

xx0123456
ff1.00.50.20.10.058820.038460.02703

(i) Trapezoidal rule

IT=h[12(f0+f6)+(f1+f2+f3+f4+f5)]=1[0.51351+0.89728]1.41080.I_T = h\Big[\tfrac{1}{2}(f_0+f_6) + (f_1+f_2+f_3+f_4+f_5)\Big] = 1\big[0.51351 + 0.89728\big] \approx 1.41080.

(ii) Simpson's 1/3 rule

IS=13[(f0+f6)+4(f1+f3+f5)+2(f2+f4)]=13[1.02703+4(0.63846)+2(0.25882)]1.36617.I_S = \frac{1}{3}\big[(f_0+f_6) + 4(f_1+f_3+f_5) + 2(f_2+f_4)\big] = \frac{1}{3}\big[1.02703 + 4(0.63846) + 2(0.25882)\big] \approx 1.36617.

Exact value: 06dx1+x2=tan161.40565\int_0^6 \frac{dx}{1+x^2}=\tan^{-1}6 \approx 1.40565.

MethodValueError
Trapezoidal1.41080+0.00515
Simpson 1/31.36617−0.03948
Exact1.40565

Comment: Although Simpson's rule is normally more accurate, here the integrand 11+x2\frac{1}{1+x^2} varies very rapidly near x=0x=0 where the coarse h=1h=1 grid samples it poorly, so with only 6 strips the Trapezoidal result happens to lie closer to the exact value. Refining the mesh (larger nn/smaller hh) makes Simpson's O(h4)O(h^4) result converge far faster than the Trapezoidal O(h2)O(h^2) result.

numerical-integrationtrapezoidal-rulesimpsons-rule
4long12 marks

(a) Describe the fourth-order Runge-Kutta method for solving a first-order ordinary differential equation dydx=f(x,y)\dfrac{dy}{dx}=f(x,y) with the initial condition y(x0)=y0y(x_0)=y_0, clearly writing all four slope expressions. [6]

(b) Using the fourth-order Runge-Kutta method, compute y(0.2)y(0.2) for the initial value problem dydx=x+y,  y(0)=1\dfrac{dy}{dx}=x+y,\; y(0)=1, taking a step size h=0.1h=0.1. [6]

(a) Fourth-order Runge-Kutta method

For dydx=f(x,y)\dfrac{dy}{dx}=f(x,y), y(x0)=y0y(x_0)=y_0, with step size hh, the RK4 method advances ynyn+1y_n\to y_{n+1} using four slope estimates:

k1=hf(xn,yn),k_1 = h\,f(x_n,\,y_n), k2=hf ⁣(xn+h2,  yn+k12),k_2 = h\,f\!\left(x_n+\tfrac{h}{2},\; y_n+\tfrac{k_1}{2}\right), k3=hf ⁣(xn+h2,  yn+k22),k_3 = h\,f\!\left(x_n+\tfrac{h}{2},\; y_n+\tfrac{k_2}{2}\right), k4=hf ⁣(xn+h,  yn+k3).k_4 = h\,f\!\left(x_n+h,\; y_n+k_3\right).

The weighted average gives the increment:

yn+1=yn+16(k1+2k2+2k3+k4)\boxed{\,y_{n+1} = y_n + \tfrac{1}{6}\big(k_1 + 2k_2 + 2k_3 + k_4\big)\,}

It is a single-step, self-starting method of local error O(h5)O(h^5) and global accuracy O(h4)O(h^4).

(b) Solve dydx=x+y\dfrac{dy}{dx}=x+y, y(0)=1y(0)=1, h=0.1h=0.1, find y(0.2)y(0.2)

Step 1 (x0=0,y0=1x_0=0,\,y_0=1):

k1=0.1(0+1)=0.10000,k2=0.1(0.05+1.05)=0.11000,k_1=0.1(0+1)=0.10000,\quad k_2=0.1(0.05+1.05)=0.11000, k3=0.1(0.05+1.055)=0.11050,k4=0.1(0.1+1.1105)=0.12105.k_3=0.1(0.05+1.055)=0.11050,\quad k_4=0.1(0.1+1.1105)=0.12105. y1=1+16(0.10000+0.22000+0.22100+0.12105)=1.110342.y_1 = 1 + \tfrac{1}{6}(0.10000+0.22000+0.22100+0.12105) = 1.110342.

So y(0.1)1.11034y(0.1)\approx 1.11034.

Step 2 (x1=0.1,y1=1.110342x_1=0.1,\,y_1=1.110342):

k1=0.1(0.1+1.110342)=0.121034,k2=0.1(0.15+1.170859)=0.132086,k_1=0.1(0.1+1.110342)=0.121034,\quad k_2=0.1(0.15+1.170859)=0.132086, k3=0.1(0.15+1.176385)=0.132638,k4=0.1(0.2+1.242980)=0.144298.k_3=0.1(0.15+1.176385)=0.132638,\quad k_4=0.1(0.2+1.242980)=0.144298. y2=1.110342+16(0.121034+0.264172+0.265277+0.144298)=1.242805.y_2 = 1.110342 + \tfrac{1}{6}(0.121034+0.264172+0.265277+0.144298) = 1.242805. y(0.2)1.2428\boxed{y(0.2) \approx 1.2428}

(Exact: y=2exx1y=2e^{x}-x-1, y(0.2)=1.24281y(0.2)=1.24281 — agreement to 4 decimals.)

numerical-solution-odesrunge-kuttaeuler-method
B

Section B: Short Answer Questions

Attempt all / any as specified.

8 questions
5short7 marks

Solve the following system of linear equations using Gauss elimination with partial pivoting, and explain why partial pivoting is necessary:

2x+y+z=10,3x+2y+3z=18,x+4y+9z=16.2x + y + z = 10,\quad 3x + 2y + 3z = 18,\quad x + 4y + 9z = 16.

Gauss elimination with partial pivoting

System (augmented matrix):

[211103231814916]\left[\begin{array}{ccc|c} 2 & 1 & 1 & 10 \\ 3 & 2 & 3 & 18 \\ 1 & 4 & 9 & 16 \end{array}\right]

Column 1 pivot: largest ai1|a_{i1}| is 3 (row 2) → swap R1↔R2:

[323182111014916]\left[\begin{array}{ccc|c} 3 & 2 & 3 & 18 \\ 2 & 1 & 1 & 10 \\ 1 & 4 & 9 & 16 \end{array}\right]

Eliminate: R2R223R1R_2\leftarrow R_2-\tfrac{2}{3}R_1, R3R313R1R_3\leftarrow R_3-\tfrac{1}{3}R_1:

[3231800.33331203.3333810]\left[\begin{array}{ccc|c} 3 & 2 & 3 & 18 \\ 0 & -0.3333 & -1 & -2 \\ 0 & 3.3333 & 8 & 10 \end{array}\right]

Column 2 pivot: 3.3333>0.3333|3.3333|>|{-0.3333}| → swap R2↔R3:

[3231803.333381000.333312]\left[\begin{array}{ccc|c} 3 & 2 & 3 & 18 \\ 0 & 3.3333 & 8 & 10 \\ 0 & -0.3333 & -1 & -2 \end{array}\right]

Eliminate: R3R30.33333.3333R2=R3+0.1R2R_3\leftarrow R_3-\tfrac{-0.3333}{3.3333}R_2 = R_3+0.1\,R_2:

[3231803.3333810000.21]\left[\begin{array}{ccc|c} 3 & 2 & 3 & 18 \\ 0 & 3.3333 & 8 & 10 \\ 0 & 0 & -0.2 & -1 \end{array}\right]

Back substitution:

z=10.2=5,y=108(5)3.3333=303.3333=9,x=182(9)3(5)3=213=7.z = \frac{-1}{-0.2}=5,\qquad y=\frac{10-8(5)}{3.3333}=\frac{-30}{3.3333}=-9,\qquad x=\frac{18-2(-9)-3(5)}{3}=\frac{21}{3}=7. x=7,y=9,z=5\boxed{x=7,\quad y=-9,\quad z=5}

Why partial pivoting is necessary: It places the entry of largest magnitude on the diagonal before elimination, which (i) avoids division by a zero or very small pivot, and (ii) keeps the multipliers 1\le 1 in magnitude, suppressing the growth of round-off error and improving numerical stability.

linear-systemsgauss-eliminationpartial-pivoting
6short7 marks

State the condition for convergence of the Gauss-Seidel iterative method. Apply the method to solve the following system, performing three iterations starting from (0,0,0)(0,0,0):

20x+y2z=17,3x+20yz=18,2x3y+20z=25.20x + y - 2z = 17,\quad 3x + 20y - z = -18,\quad 2x - 3y + 20z = 25.

Gauss-Seidel method

Convergence condition: The iteration converges (for any starting vector) if the coefficient matrix is diagonally dominant, i.e. for every row aiijiaij|a_{ii}| \ge \sum_{j\neq i}|a_{ij}| with strict inequality for at least one row. Here:

  • Row 1: 20>1+2=3|20| > |1|+|{-2}| = 3
  • Row 2: 20>3+1=4|20| > |3|+|{-1}| = 4
  • Row 3: 20>2+3=5|20| > |2|+|{-3}| = 5

So the system is diagonally dominant and Gauss-Seidel converges.

Iteration formulas:

x=17y+2z20,y=183x+z20,z=252x+3y20.x = \frac{17 - y + 2z}{20},\quad y = \frac{-18 - 3x + z}{20},\quad z = \frac{25 - 2x + 3y}{20}.

Starting from (0,0,0)(0,0,0), using the most recent values:

Iterxxyyzz
10.85000−1.027501.01088
21.00246−0.999830.99978
30.99997−1.000011.00000

The values are converging to the exact solution

x=1,y=1,z=1.\boxed{x=1,\quad y=-1,\quad z=1.}
linear-systemsgauss-seideliterative-methods
7short7 marks

Fit a straight line of the form y=a+bxy = a + bx to the following data using the method of least squares, and estimate yy when x=6x = 6.

xx12345
yy1427405568

Least-squares straight-line fit y=a+bxy=a+bx

The normal equations are

y=na+bx,xy=ax+bx2.\sum y = na + b\sum x,\qquad \sum xy = a\sum x + b\sum x^{2}.

With n=5n=5:

xxyyxyxyx2x^2
114141
227544
3401209
45522016
56834025
Σ=15Σ=204Σ=748Σ=55

Normal equations:

204=5a+15b,748=15a+55b.204 = 5a + 15b,\qquad 748 = 15a + 55b.

Solving:

b=nxyxynx2(x)2=5(748)15(204)5(55)152=37403060275225=68050=13.6,b = \frac{n\sum xy - \sum x\sum y}{n\sum x^2-(\sum x)^2} = \frac{5(748)-15(204)}{5(55)-15^2} = \frac{3740-3060}{275-225}=\frac{680}{50}=13.6, a=ybxn=20413.6(15)5=2042045=0.a = \frac{\sum y - b\sum x}{n} = \frac{204 - 13.6(15)}{5} = \frac{204-204}{5}=0.

Best-fit line:   y=13.6x\;\boxed{y = 13.6\,x}

Estimate at x=6x=6:   y=13.6(6)=81.6.\;y = 13.6(6) = \boxed{81.6}.

curve-fittingleast-squareslinear-regression
8short6 marks

The following table gives the value of a function f(x)f(x). Using Newton's forward difference formula, find the first and second derivatives f(x)f'(x) and f(x)f''(x) at x=1.0x = 1.0.

xx1.01.11.21.31.4
f(x)f(x)7.9898.4038.7819.1299.451

Derivatives by Newton's forward-difference formula

With h=0.1h=0.1 and x0=1.0x_0=1.0, build the forward-difference table:

xxffΔf\Delta fΔ2f\Delta^2 fΔ3f\Delta^3 fΔ4f\Delta^4 f
1.07.9890.414−0.0360.006−0.002
1.18.4030.378−0.0300.004
1.28.7810.348−0.026
1.39.1290.322
1.49.451

At the leading point (p=0p=0), the formulas are

f(x0)=1h[Δf012Δ2f0+13Δ3f014Δ4f0],f'(x_0)=\frac{1}{h}\Big[\Delta f_0 - \tfrac{1}{2}\Delta^2 f_0 + \tfrac{1}{3}\Delta^3 f_0 - \tfrac{1}{4}\Delta^4 f_0\Big], f(x0)=1h2[Δ2f0Δ3f0+1112Δ4f0].f''(x_0)=\frac{1}{h^{2}}\Big[\Delta^2 f_0 - \Delta^3 f_0 + \tfrac{11}{12}\Delta^4 f_0\Big].

First derivative at x=1.0x=1.0:

f(1.0)=10.1[0.41412(0.036)+13(0.006)14(0.002)]=10.1(0.4345)=4.345.f'(1.0)=\frac{1}{0.1}\Big[0.414-\tfrac{1}{2}(-0.036)+\tfrac{1}{3}(0.006)-\tfrac{1}{4}(-0.002)\Big]=\frac{1}{0.1}(0.4345)= \boxed{4.345}.

Second derivative at x=1.0x=1.0:

f(1.0)=10.01[0.036(0.006)+1112(0.002)]=10.01(0.043833)=4.3833.f''(1.0)=\frac{1}{0.01}\Big[-0.036-(0.006)+\tfrac{11}{12}(-0.002)\Big]=\frac{1}{0.01}(-0.043833)= \boxed{-4.3833}.
numerical-differentiationforward-differencebackward-difference
9short6 marks

(a) Distinguish between round-off error and truncation error with a suitable example of each. [3]

(b) The number π=3.14159265\pi = 3.14159265 is rounded to 3.14163.1416. Compute the absolute error, the relative error, and the percentage error. [3]

(a) Round-off vs truncation error

Round-off error arises from representing numbers with a finite number of digits (limited machine/decimal precision); the exact value is replaced by its nearest representable approximation. Example: storing 1/3=0.3333331/3 = 0.333333\ldots as 0.33330.3333 introduces a round-off error of about 3.3×1053.3\times10^{-5}.

Truncation error arises from terminating an infinite mathematical process (a series, limit, or iteration) after finitely many terms — independent of machine precision. Example: approximating sinxxx36\sin x \approx x - \dfrac{x^3}{6} drops the remaining +x5120+\dfrac{x^5}{120}-\cdots terms; the omitted tail is the truncation error.

(b) Errors in rounding π\pi

True value π=3.14159265\pi = 3.14159265, approximation πˉ=3.1416\bar\pi = 3.1416.

Absolute error:

Ea=ππˉ=3.141592653.1416=7.35×106  (0.00000735).E_a = |\pi-\bar\pi| = |3.14159265 - 3.1416| = 7.35\times10^{-6}\;(\approx 0.00000735).

Relative error:

Er=Eaπ=7.35×1063.141592652.339×106.E_r = \frac{E_a}{|\pi|} = \frac{7.35\times10^{-6}}{3.14159265} \approx 2.339\times10^{-6}.

Percentage error:

Ep=Er×1002.34×104%  (0.000234%).E_p = E_r\times 100 \approx 2.34\times10^{-4}\,\% \;(\approx 0.000234\%).
error-analysisround-off-errortruncation-error
10short6 marks

(a) Write down the iterative formula of the Secant method and explain how it differs from the Newton-Raphson method. [3]

(b) Perform two iterations of the Secant method to find a root of f(x)=cosxxex=0f(x) = \cos x - x e^{x} = 0 taking initial approximations x0=0x_0 = 0 and x1=1x_1 = 1. [3]

(a) Secant method formula and comparison

Iterative formula:

xn+1=xnf(xn)xnxn1f(xn)f(xn1).x_{n+1} = x_n - f(x_n)\,\frac{x_n - x_{n-1}}{f(x_n)-f(x_{n-1})}.

Difference from Newton-Raphson: Newton-Raphson uses the exact derivative f(xn)f'(x_n) and needs one starting point; the Secant method replaces f(xn)f'(x_n) by the slope of the secant through the two previous points f(xn)f(xn1)xnxn1\dfrac{f(x_n)-f(x_{n-1})}{x_n-x_{n-1}}, so it needs two initial approximations and does not require f(x)f'(x). Its order of convergence is 1.618\approx 1.618 (superlinear), lower than Newton's 2, but each step is cheaper since no derivative is evaluated.

(b) Two iterations for f(x)=cosxxex=0f(x)=\cos x - x\,e^{x}=0

f(x0)=f(0)=cos00=1.000000f(x_0)=f(0)=\cos 0 - 0 = 1.000000,   f(x1)=f(1)=cos1e=0.5403022.718282=2.177980\;f(x_1)=f(1)=\cos 1 - e = 0.540302 - 2.718282 = -2.177980.

Iteration 1:

x2=x1f(x1)x1x0f(x1)f(x0)=1(2.177980)102.1779801=12.1779803.1779800.314665.x_2 = x_1 - f(x_1)\frac{x_1-x_0}{f(x_1)-f(x_0)} = 1 - (-2.177980)\frac{1-0}{-2.177980-1} = 1 - \frac{2.177980}{3.177980}\approx 0.314665.

f(x2)=cos(0.314665)0.314665e0.3146650.519871f(x_2)=\cos(0.314665) - 0.314665\,e^{0.314665} \approx 0.519871.

Iteration 2:

x3=x2f(x2)x2x1f(x2)f(x1)=0.3146650.5198710.31466510.519871(2.177980).x_3 = x_2 - f(x_2)\frac{x_2-x_1}{f(x_2)-f(x_1)} = 0.314665 - 0.519871\frac{0.314665-1}{0.519871-(-2.177980)}. x3=0.3146650.5198710.6853352.6978510.314665+0.132063=0.446728.x_3 = 0.314665 - 0.519871\cdot\frac{-0.685335}{2.697851} \approx 0.314665 + 0.132063 = 0.446728.

f(x3)0.203545f(x_3)\approx 0.203545.

After two iterations   x0.4467  \;\boxed{x \approx 0.4467}\; (continuing converges to the true root 0.5178\approx 0.5178).

roots-of-equationssecant-methodfixed-point-iteration
11short7 marks

Using Newton's forward difference interpolation formula, estimate the population in the year 1925 from the following census data, and state the assumption on which the formula is based.

Year19111921193119411951
Population (in thousands)1215202739

Population in 1925 by Newton's forward-difference interpolation

Years are equally spaced (h=10h=10), so use the forward formula with x0=1911x_0=1911. Difference table (population in thousands):

YearffΔ\DeltaΔ2\Delta^2Δ3\Delta^3Δ4\Delta^4
1911123203
192115523
19312075
19412712
195139

Let p=xx0h=1925191110=1.4p=\dfrac{x-x_0}{h}=\dfrac{1925-1911}{10}=1.4.

Newton's forward formula:

f=f0+pΔf0+p(p1)2!Δ2f0+p(p1)(p2)3!Δ3f0+p(p1)(p2)(p3)4!Δ4f0.f = f_0 + p\,\Delta f_0 + \frac{p(p-1)}{2!}\Delta^2 f_0 + \frac{p(p-1)(p-2)}{3!}\Delta^3 f_0 + \frac{p(p-1)(p-2)(p-3)}{4!}\Delta^4 f_0.

Substituting p=1.4p=1.4, Δf0=3, Δ2f0=2, Δ3f0=0, Δ4f0=3\Delta f_0=3,\ \Delta^2 f_0=2,\ \Delta^3 f_0=0,\ \Delta^4 f_0=3:

f=12+1.4(3)+(1.4)(0.4)2(2)+(1.4)(0.4)(0.6)6(0)+(1.4)(0.4)(0.6)(1.6)24(3).f = 12 + 1.4(3) + \frac{(1.4)(0.4)}{2}(2) + \frac{(1.4)(0.4)(-0.6)}{6}(0) + \frac{(1.4)(0.4)(-0.6)(-1.6)}{24}(3). f=12+4.2+0.56+0+0.067216.83 thousand.f = 12 + 4.2 + 0.56 + 0 + 0.0672 \approx \boxed{16.83\text{ thousand}}.

Assumption: The formula assumes the tabulated data can be represented by a single polynomial through all the points and that the arguments are equally spaced; it is best applied near the beginning of the table (small pp), which is why the forward formula is appropriate for 1925.

interpolationnewton-forward-differencefinite-differences
12short6 marks

Using the Modified Euler (Heun's) method, compute y(0.1)y(0.1) and y(0.2)y(0.2) for the initial value problem dydx=x2+y,  y(0)=1\dfrac{dy}{dx} = x^2 + y,\; y(0) = 1 with step size h=0.1h = 0.1, iterating the corrector until two successive values agree to three decimal places.

Modified Euler (Heun's) method

For dydx=f(x,y)=x2+y\dfrac{dy}{dx}=f(x,y)=x^2+y, y(0)=1y(0)=1, h=0.1h=0.1. Predictor (Euler) then corrector iterated:

yn+1P=yn+hf(xn,yn),yn+1(k+1)=yn+h2[f(xn,yn)+f(xn+1,yn+1(k))].y^{P}_{n+1}=y_n + h f(x_n,y_n),\qquad y^{(k+1)}_{n+1}=y_n + \tfrac{h}{2}\big[f(x_n,y_n)+f(x_{n+1},y^{(k)}_{n+1})\big].

Step 1: x0=0,y0=1x_0=0,\,y_0=1

f(0,1)=0+1=1f(0,1)=0+1=1. Predictor: yP=1+0.1(1)=1.1y^P = 1 + 0.1(1) = 1.1.

  • Corrector 1: y=1+0.05[1+(0.12+1.1)]=1+0.05(2.11)=1.10550y = 1 + 0.05[\,1 + (0.1^2+1.1)\,]=1+0.05(2.11)=1.10550.
  • Corrector 2: y=1+0.05[1+(0.01+1.10550)]=1+0.05(2.11550)=1.10578y = 1 + 0.05[\,1 + (0.01+1.10550)\,]=1+0.05(2.11550)=1.10578.
  • Corrector 3: y=1+0.05[1+(0.01+1.10578)]=1.10579y = 1 + 0.05[\,1 + (0.01+1.10578)\,]=1.10579.

Converged:   y(0.1)1.1058\;\boxed{y(0.1) \approx 1.1058}.

Step 2: x1=0.1,y1=1.10579x_1=0.1,\,y_1=1.10579

f(0.1,1.10579)=0.01+1.10579=1.11579f(0.1,1.10579)=0.01+1.10579=1.11579. Predictor: yP=1.10579+0.1(1.11579)=1.21737y^P = 1.10579 + 0.1(1.11579)=1.21737.

  • Corrector 1: y=1.10579+0.05[1.11579+(0.22+1.21737)]=1.10579+0.05(2.37316)=1.22445y = 1.10579 + 0.05[\,1.11579 + (0.2^2+1.21737)\,]=1.10579+0.05(2.37316)=1.22445.
  • Corrector 2: y=1.10579+0.05[1.11579+(0.04+1.22445)]=1.10579+0.05(2.38024)=1.22480y = 1.10579 + 0.05[\,1.11579 + (0.04+1.22445)\,]=1.10579+0.05(2.38024)=1.22480.
  • Corrector 3: y=1.10579+0.05[1.11579+(0.04+1.22480)]=1.22482y = 1.10579 + 0.05[\,1.11579+(0.04+1.22480)\,]=1.22482.

Converged:   y(0.2)1.2248\;\boxed{y(0.2) \approx 1.2248}.

(Exact solution y=3exx22x2y=3e^{x}-x^2-2x-2 gives y(0.1)=1.10571y(0.1)=1.10571, y(0.2)=1.22461y(0.2)=1.22461 — close agreement.)

numerical-solution-odesmodified-eulerpredictor-corrector

Frequently asked questions

Where can I find the BE Computer Engineering (Pokhara University) Numerical Methods (PU, MTH 252) question paper 2079?
The full BE Computer Engineering (Pokhara University) Numerical Methods (PU, MTH 252) 2079 (regular) question paper is available free on Kekkei. You can read every question online and attempt the paper under timed exam conditions.
Does the Numerical Methods (PU, MTH 252) 2079 paper come with solutions?
Yes. Every question on this Numerical Methods (PU, MTH 252) past paper includes a step-by-step solution, plus instant AI feedback when you attempt it on Kekkei.
How many marks is the BE Computer Engineering (Pokhara University) Numerical Methods (PU, MTH 252) 2079 paper?
The BE Computer Engineering (Pokhara University) Numerical Methods (PU, MTH 252) 2079 paper carries 100 full marks and is meant to be completed in 180 minutes, across 12 questions.
Is practising this Numerical Methods (PU, MTH 252) past paper free?
Yes — reading and attempting this Numerical Methods (PU, MTH 252) past paper on Kekkei is completely free.