Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 27

Further Pure 1 Chapter 8 ::

Numerical Methods
jamie@drfrostmaths.com
www.drfrostmaths.com
@DrFrostMaths

Last modified: 8th March 2021


www.drfrostmaths.com Register now to interactively practise questions on this topic, including
past paper questions and extension questions (including UKMT).
Everything is completely free. Teachers: you can create student accounts (or students can register
Why not register? themselves), to set work, monitor progress and even create worksheets.

With questions by:

Dashboard with points,


trophies, notifications
and student progress.

Questions organised by topic,


Teaching videos with topic difficulty and past paper.
tests to check understanding.
Solutions to differential equations
What does it mean to solve the differential equation ?
It means to obtain the direct relationship between and , that is, an equation in
terms of and (possibly in terms of ), without any
?

𝑑𝑦 𝟐
=2 𝑥 → 𝒚 = 𝒙 + 𝒄
𝑑𝑥
Clearly, it is possible to solve this differential
equation directly analytically (i.e. using direct
integration). But what if we couldn’t find this
solution analytically (e.g. because we had an
expression which is not integratable)…
Solutions to differential equations
𝑑𝑦
=2 𝑥
𝑑𝑥
This is known as a vector field
plot or tangent field.

It shows the gradient for


any value of and on the
-plane.

A good idea therefore would be


to keep using these directions
to gradually form the solution
curve.

This corresponds to a
Suppose we picked a random particular solution to the
The vector field plot shows the
starting point. differential equation (rather
gradient of the curve for that
This point forms part of some than the ‘general’ solution),
point, i.e. the direction the
solution curve to this because by fixing a point, we fix
curve is moving in.
differential equation. the in
Solutions to differential equations

This is the gist therefore of


Euler’s method:

We start with some point on


the solution curve, and then
follow the direction of the
curve (using ) to generate the
rest of the solution curve.

Depending on where your


starting point is (which can be
anywhere on the vector field
where the gradient is defined for
that point), you get different
solution curves, corresponding
to different in
Solutions to differential equations

𝑑𝑦 2 3
=𝑥 + 𝑦 This differential equation is not
𝑑𝑥 actually solvable!
(i.e. no expressible using conventional
algebraic notation)

But again, starting with a suitable


starting point, we can easily find a
solution curve by following the
gradients in the field.
Numerically getting the next point
Suppose that we started with
𝑑𝑦 2 3 If we increased by a small amount (‘step
=𝑥 + 𝑦 size’) of .
𝑑𝑥 How would we work out the next point?

0.1 ( )
𝑑𝑦
𝑑𝑥 0

( 1 , 0.5 )h=0.1
The gradient by definition tells us
what would increase by for each
unit increase in .
Therefore new coordinate:
?
Gradient at :

Therefore new point:


Euler’s Method

! Euler’s method for finding approximate solutions to first-order


differential equations uses the approximation

We can use the iterative formula:

Actual point on
solution curve.
Predicted point on
solution curve.

(
( 𝑥 𝑟 +1 , 𝑦 𝑟 +1 ) = 𝑥 𝑟 + h , 𝑦 𝑟 +h
𝑑𝑥 ) )
( 𝑑𝑦 𝑟

h
( )
𝑑𝑦
𝑑𝑥 𝑟

( 𝑥𝑟 , 𝑦𝑟 )
Test Your Understanding
Edexcel FP1 SAM Q6

?
(Extra Practice)
Use Euler’s method to estimate the value at of the particular solution to the differential equation ,
which passes through the point . Use a step length of 0.5.

Gradient at :

Gradient at :
?
The point is
Exercise 8A
Pearson Further Pure 1
Pages 164-165
Midpoint method
Actual point on
solution curve.
Predicted point on Euler’s method leads to
Error solution curve. quite a large amount of
(
( 𝑥 𝑟 +1 , 𝑦 𝑟 +1 ) = 𝑥 𝑟 + h , 𝑦 𝑟 +h ( ))
𝑑𝑦
𝑑𝑥 𝑟
error. Reducing the step
size will help…
( 𝑑𝑦
h 𝑑𝑥
) 𝑟

( 𝑥𝑟 , 𝑦𝑟 )

𝑃 𝑖 +1 Suppose we had three points on a solution


curve equally spaced on the -axis.
Notice that the gradient at is similar to the
gradient of the straight line segment between
the two points either side…

𝑃 𝑖 −1 𝑃𝑖
Midpoint method
This suggests that to get
from to an Actual point on
approximation of , we
𝑃 𝑖 +1 can add 2 lots of the
𝑃 𝑖 +1 solution curve.
Predicted point on
gradient of the tangent solution curve.
of the middle point to
the -value.

𝑃𝑖 𝑃 𝑖 −1 𝑃𝑖
2 ( )
𝑑𝑦
𝑑𝑥 𝑖
𝑃 𝑖 −1
h h

! The midpoint method for finding approximate solutions to first-order


differential equations uses the formula

We can use the iterative formula:


Example
[Textbook] Use the midpoint formula with a step length of 0.25 to estimate the
value at of the particular solution to the differential equation

Which passes through the point . Give your answer correct to 4dp.

𝑥 0 𝑥1 𝑥 2
0 0.25 0.5
Using Euler’s method:
We need to work out from
? Work out and
STEP 1: Use Euler’s method
to get from to :
Using midpoint formula:
STEP 2: Now that we have 2
points, we can use midpoint
formula to get from :

? Work out
Exercise 8B
Pearson Further Pure 1
Pages 167-168
Solving second-order differential equations

Suppose now, in order to solve a second-


𝑃1 order differential equation, we want to
find at a point .
( )
𝒅𝒚
𝒅𝒙 𝟎

We have previously used to mean the


( ) 𝒅𝒚
𝒅𝒙 −𝟏
𝑃0
gradient at , which is approximately the
gradient between and , e.g.
𝑃 −1

h h

𝑑𝑦
( )( )
𝑑𝑦
means “the rate of change of
gradient”. So similarly we could
consider how changes across an −
( ) 𝑑𝑥 0 ? 𝑑𝑥
2
interval :
𝑑𝑦 −1
2

𝑑𝑥 0 h
?
Solving second-order differential equations
! To solve second-order differential equations using Euler’s method, use

We can use the iterative formula:


Example
[Textbook] . When and .
Use the approximations and to obtain estimates for at and , giving your answers correct to 4 decimal
places.

Similar to the previous lesson:


(the only change is the second formula)

STEP 1: Use Euler’s method to get


from to :

STEP 2: Now that we have 2


points, we can use midpoint
? formula to get from :
Example using 1st and 2nd derivatives
[Textbook] The curve satisfies the differential equation . When , and and with to estimate the value of
when .

, Advice: Just substitute everything


into the available approximations.
Because 1.2 is 0.2 above 1, we
? want for .

Using the two approximation will


? 1 result in two equations involving ,
which we can solve
simultaneously.

Solving (1) and (2) simultaneously:


? 2

?
Test Your Understanding
Edexcel FP1 Mock Set 2 Q2
Exercise 8C
Pearson Further Pure 1
Pages 171-172
Simpson’s Rule

𝑦
We want to 𝑦 There’s of course
approximate this the trapezium rule
area. What methods (say with 2 strips)
do you know?

∫ 𝑓 ( 𝑥 ) 𝑑𝑥
𝑎

𝑥 𝑥
𝑎 𝑏 𝑎 h 𝑏
𝑦 You may have also 𝑦 We will look at
heard of the Simpson’s Rule, which
midordinate rule. fits a quadratic curve
within each interval.

𝑥 𝑥
𝑎 h 𝑏 𝑎 h 𝑏
Simpson’s Rule
𝑦 𝑦 0.5 For each interval, we use the
𝑦0 𝑦1 values of the two endpoints
and the midpoint.

A quadratic has three


unknowns, so three points
will uniquely determine the
curve.
𝑥 0 𝑥 0.5 𝑥1
𝑥
𝑎 h 𝑏
Note that is half the width of each quadratic.

 Simpson’s rule for strips of width is given by:

or informally:
Example
𝑏
1
∫ 𝑓 ( 𝑥 ) 𝑑𝑥 ≈
3
h ¿ ¿
𝑎

[Textbook] Use Simpson’s rule with 4 intervals to estimate

?
Area under curve
(4sf)

Fro note: ‘Odd value’ means at an odd


position in the table, i.e. 3rd, 5th, 7th, …
Test Your Understanding
𝑏
1
∫ 𝑓 ( 𝑥 ) 𝑑𝑥 ≈
3
h ¿ ¿
𝑎

Edexcel FP1 June 2019 Q1

?
Exercise 8D
Pearson Further Pure 1
Pages 174-175

You might also like