Question #74942 - Math - Quantitative Methods
use modified euler's method to find the approximate solution of IVP y′=2xy , y(1)=1 , at x=1.5 with h=0.1 . If the exact solution is y(x)=ex2−1 , find the error.
**Solution:** for the numerical solution of the differential equation:
y′=f(x,y),f(x,y)=2⋅x⋅y
use the explicit midpoint method also known as the modified Euler method:
yn+1=yn+h⋅f(xn+2h,yn+2h⋅f(xn,yn)),h=0.1,x0=1,y0=1
to find the approximate solution of IVP at x=1.5 , it takes 5 steps:
x1=x0+h=1.1,y1=y0+h⋅f(x0+2h,y0+2h⋅f(x0,y0))=1+0.1⋅f(1.05,1+0.05⋅f(1,1))=1+0.1⋅f(1.05,1.1)=1.2310x2=x1+h=1.2,y2=y1+h⋅f(x1+2h,y1+2h⋅f(x1,y1))=1.231+0.1⋅f(1.15,1.231+0.05⋅f(1.1,1.231))=1.231+0.1⋅f(1.15,1.3664)=1.5453x3=x2+h=1.3,y3=y2+h⋅f(x2+2h,y2+2h⋅f(x2,y2))=1.5453+0.1⋅f(1.25,1.5453+0.05⋅f(1.2,1.5453))=1.5453+0.1⋅f(1.25,1.7307)=1.97795x4=x3+h=1.4,y4=y3+h⋅f(x3+2h,y3+2h⋅f(x3,y3))=1.97795+0.1⋅f(1.35,1.97795+0.05⋅f(1.3,1.97795))=1.97795+0.1⋅f(1.35,2.2351)=2.5814x5=x4+h=1.5,y5=y4+h⋅f(x4+2h,y4+2h⋅f(x4,y4))=2.5814+0.1⋅f(1.45,2.5814+0.05⋅f(1.4,2.5814))=2.5814+0.1⋅f(1.45,2.9428)=3.4348
exact solution:
y(x)=ex2−1,y(1.5)=3.4903error=3.4903−3.4348=0.0555(∼1.6%)
Answer: y5=3.4348 , error =0.0555 ( ∼1.6% )
Answer provided by https://www.AssignmentExpert.com