Numerical solution of differential equations

Numerical solution of differential equations Test

Spec 6.1 · Edexcel A-Level Further Maths: Subtopic test

Studying this course? Keep your progress in one place.

Two ways to do this test

Question by question

One question at a time. Each answer is marked the moment you hand it in, so you learn as you go. Drago helps if you get stuck. All 10 questions, or just 5.

Exam mode

The whole paper in one go, timed like the real exam. Nothing is marked until you hand it in, then you get every mark explained.

10 questions, 27 marks

Edexcel A-Level Further Maths

Numerical solution of differential equations

Total 27 marks

Name

Class

Date

  1. 1
    The differential equation dydx=x+y\frac{dy}{dx}=x+y, with y=1y=1 when x=0x=0, is solved numerically using the approximation (dydx)n=yn+1−ynh\left(\frac{dy}{dx}\right)_n=\frac{y_{n+1}-y_n}{h} with h=0.2h=0.2. Here xn=0.2nx_n=0.2n and yny_n is the approximation to yy at xnx_n.
    (a)
    Find the approximation y1y_1 to y(0.2)y(0.2).
    [1 mark]
    • A1.241.24
    • B1.21.2
    • C1.11.1
    • D22
    Show the mark scheme

    Mark scheme

    Answer: B
    (b)
    Find the approximation y2y_2 to y(0.4)y(0.4).
    [1 mark]
    • A1.441.44
    • B1.521.52
    • C1.41.4
    • D1.481.48
    Show the mark scheme

    Mark scheme

    Answer: D
    (c)
    Given that y3=1.856y_3=1.856, and that the exact solution is y=2ex−x−1y=2e^x-x-1, calculate the percentage error in y3y_3 as an approximation to y(0.6)y(0.6).
    [2 marks]
    Show the mark scheme

    Mark scheme

    M1: exact value y(0.6)=2e0.6−1.6=2.044…y(0.6)=2e^{0.6}-1.6=2.044\ldots
    A1:
    9.2%9.2\%

    Total for question 1: 4 marks

  2. 2
    The differential equation dydx=x−y\frac{dy}{dx}=x-y, with y=1y=1 when x=0x=0, is solved numerically using the approximation (dydx)n=yn+1−yn−12h\left(\frac{dy}{dx}\right)_n=\frac{y_{n+1}-y_{n-1}}{2h} with h=0.1h=0.1. Here xn=0.1nx_n=0.1n, y0=1y_0=1, and the value y1=0.9y_1=0.9 is found from the approximation (dydx)n=yn+1−ynh\left(\frac{dy}{dx}\right)_n=\frac{y_{n+1}-y_n}{h}.
    (a)
    Which formula gives yn+1y_{n+1} in terms of earlier values?
    [1 mark]
    • Ayn+1=yn−1+2h(xn−yn)y_{n+1}=y_{n-1}+2h(x_n-y_n)
    • Byn+1=yn+2h(xn−yn)y_{n+1}=y_n+2h(x_n-y_n)
    • Cyn+1=yn−1+h(xn−yn)y_{n+1}=y_{n-1}+h(x_n-y_n)
    • Dyn+1=yn+h(xn+1−yn+1)y_{n+1}=y_n+h(x_{n+1}-y_{n+1})
    Show the mark scheme

    Mark scheme

    Answer: A
    (b)
    Find y2y_2.
    [1 mark]
    • A0.820.82
    • B0.860.86
    • C0.840.84
    • D1.21.2
    Show the mark scheme

    Mark scheme

    Answer: C
    (c)
    Find y3y_3.
    [2 marks]
    Show the mark scheme

    Mark scheme

    M1: y3=y1+0.2(x2−y2)=0.9+0.2(0.2−0.84)y_3=y_1+0.2(x_2-y_2)=0.9+0.2(0.2-0.84)
    A1:
    0.7720.772
    Accept: follow-through from their
    y2y_2

    Total for question 2: 4 marks

  3. 3
    The function yy satisfies d2ydx2=−y\frac{d^2y}{dx^2}=-y, with y=0y=0 and dydx=1\frac{dy}{dx}=1 when x=0x=0. It is solved numerically with step length h=0.1h=0.1, where xn=0.1nx_n=0.1n and yny_n approximates yy at xnx_n, using (d2ydx2)n=yn+1−2yn+yn−1h2\left(\frac{d^2y}{dx^2}\right)_n=\frac{y_{n+1}-2y_n+y_{n-1}}{h^2} and (dydx)n=yn+1−yn−12h\left(\frac{dy}{dx}\right)_n=\frac{y_{n+1}-y_{n-1}}{2h}.
    (a)
    Show that yn+1=1.99yn−yn−1y_{n+1}=1.99y_n-y_{n-1}.
    [3 marks]
    Show the mark scheme

    Mark scheme

    M1: substitutes the second-derivative approximation into d2ydx2=−y\frac{d^2y}{dx^2}=-y, i.e. yn+1−2yn+yn−10.01=−yn\frac{y_{n+1}-2y_n+y_{n-1}}{0.01}=-y_n
    A1:
    yn+1−2yn+yn−1=−0.01yny_{n+1}-2y_n+y_{n-1}=-0.01y_n
    A1:
    yn+1=1.99yn−yn−1y_{n+1}=1.99y_n-y_{n-1}
    AG: the final line must be reached from correct working
    (b)
    Use the formula in part (a) with n=0n=0, together with the approximation for dydx\frac{dy}{dx}, to find y1y_1. Hence find y2y_2.
    [4 marks]
    Show the mark scheme

    Mark scheme

    M1: y1−y−10.2=1\frac{y_1-y_{-1}}{0.2}=1, so y1−y−1=0.2y_1-y_{-1}=0.2
    M1:
    n=0n=0 in the formula, y1=1.99y0−y−1=−y−1y_1=1.99y_0-y_{-1}=-y_{-1}, as y0=0y_0=0
    A1:
    y1=0.1y_1=0.1
    A1:
    y2=1.99(0.1)−0=0.199y_2=1.99(0.1)-0=0.199

    Total for question 3: 7 marks

  4. 4
    The function yy satisfies d2ydx2+2dydx+y=0\frac{d^2y}{dx^2}+2\frac{dy}{dx}+y=0, with y=1y=1 and dydx=0\frac{dy}{dx}=0 when x=0x=0. It is solved numerically with h=0.5h=0.5, where xn=0.5nx_n=0.5n and yny_n approximates yy at xnx_n, using (d2ydx2)n=yn+1−2yn+yn−1h2\left(\frac{d^2y}{dx^2}\right)_n=\frac{y_{n+1}-2y_n+y_{n-1}}{h^2} and (dydx)n=yn+1−yn−12h\left(\frac{dy}{dx}\right)_n=\frac{y_{n+1}-y_{n-1}}{2h}.
    (a)
    (i) Show that 6yn+1−7yn+2yn−1=06y_{n+1}-7y_n+2y_{n-1}=0.
    (ii) Find
    y1y_1.
    [6 marks]
    Show the mark scheme

    Mark scheme

    M1: (i) substitutes both approximations with h=0.5h=0.5, 4(yn+1−2yn+yn−1)+2(yn+1−yn−1)+yn=04(y_{n+1}-2y_n+y_{n-1})+2(y_{n+1}-y_{n-1})+y_n=0
    A1: (i)
    4yn+1−8yn+4yn−1+2yn+1−2yn−1+yn=04y_{n+1}-8y_n+4y_{n-1}+2y_{n+1}-2y_{n-1}+y_n=0
    A1: (i)
    6yn+1−7yn+2yn−1=06y_{n+1}-7y_n+2y_{n-1}=0
    M1: (ii)
    y1−y−11=0\frac{y_1-y_{-1}}{1}=0, so y−1=y1y_{-1}=y_1
    M1: (ii)
    n=0n=0: 6y1−7y0+2y−1=06y_1-7y_0+2y_{-1}=0 with y0=1y_0=1
    A1: (ii)
    y1=78y_1=\frac78
    Accept:
    0.8750.875
    (b)
    (i) Find y2y_2, an approximation to y(1)y(1).
    (ii) The exact solution is
    y=(1+x)e−xy=(1+x)e^{-x}. Calculate the percentage error in y2y_2.
    (iii) State, with a reason, how the approximation could be improved.
    [6 marks]
    Show the mark scheme

    Mark scheme

    M1: (i) y2=7y1−2y06y_2=\frac{7y_1-2y_0}{6}
    A1: (i)
    1116=0.6875\frac{11}{16}=0.6875
    M1: (ii) exact
    y(1)=2e−1=0.7358…y(1)=2e^{-1}=0.7358\ldots, and error 0.7358−0.68750.7358\frac{0.7358-0.6875}{0.7358}
    A1: (ii)
    6.6%6.6\%
    B1: (iii) use a smaller step length
    hh
    B1: (iii) the difference approximations are then closer to the true derivatives

    Accept: use of a method that is more accurate, with a reason

    Total for question 4: 12 marks

End of questions

Subtopic tests