Question: Given the initial-value problem 2 y' ==y+tet, 1t 2, with exact solution y(t) = t(et e). Modify the Euler code I provided to solve
Given the initial-value problem 2 y' ==y+tet, 1t 2, with exact solution y(t) = t(et e). Modify the Euler code I provided to solve this problem with the following different N's: N = 10, 20, 40, 80,and 160 - y(1) = 0, (a) Plot the numerical solutions vs. the exact solutions for N = 10, 20, and 40. (b) List the errors at t - doubled? : 2 for N = 10, 20, 40, 80, and 160. How much is the error decreased when N is
Step by Step Solution
3.44 Rating (160 Votes )
There are 3 Steps involved in it
Heres the modified Euler code to solve the initialvalue problem for different N values and plotting the results python import matplotlibpyplot as plt ... View full answer
Get step-by-step solutions from verified subject matter experts
