Consider the IVP dy/dt (t)=f(t,y(t)),t in [a,b],y(a)=alpha in R.

monopolutk

monopolutk

Open question

2022-08-20

Consider the IVP
d y d t ( t ) = f ( t , y ( t ) ) , t [ a , b ] , y ( a ) = α R .
One can show that Euler's method, i.e., the scheme
y i + 1 = y i + h f ( t i . y i ) , y 0 = α , i = 0 , 1 , 2 ,
has local truncation error O ( h 2 ) and global error O ( h ) .
For higher order ODEs one can rewrite the ODE as a first order system and then apply Euler as before.
Should the local truncation error still be O ( h 2 )?
I tried this for a second order ODE
y ( t ) = f ( t , y ( t ) , y ( t ) ) , t [ a , b ] , y ( a ) = α , y ( a ) = β
and arrived at
y i + 2 = 2 y i + 1 y i + h 2 f ( t i , y i , f ( t i , y i , y i + 1 y i h ) ) .
Then the local truncation error is
y ( t i + 1 ) y i + 1 = O ( h 3 ) .
This of course contradicts my expectation that the error would still be O ( h 2 ).

Answer & Explanation

Rayan Ali

Rayan Ali

Beginner2022-08-21Added 8 answers

Your two-step formula y i + 2 2 y i + 1 + y i = h 2 f ( . . . ) actually requires two summations to get the values of y i . So if the truncation error of it is O ( h 3 ), then the first summation gives an error of O ( h 2 ) and the second summation an error of O ( h ) for the final result. There is no magical stuff happening.

Do you have a similar question?

Recalculate according to your conditions!

Ask your question.
Get an expert answer.

Let our experts help you. Answer in as fast as 15 minutes.

Didn't find what you were looking for?