Question: Please provide matlab code! Clear, clc, close all, format compact, format shortg Consider the following initial value problem over the interval from t = 0
Please provide matlab code!

Clear, clc, close all, format compact, format shortg Consider the following initial value problem over the interval from t = 0 to 4 where y(0) = 1 dy/dt = cos(0.8*y)*t (Not necessarily matlab code) Notice that this is a function of BOTH t and y! ! a. Solve analytically using MATLAB's symbolic algebra capabilities By solve I mean... create a symbolic expression for y in terms of t b. Convert your result from part a into an anonymous function called f c. Use Euler's method to solve this problem for y, using a step size of 0.2. Display your results by creating a table showing the t value, the corresponding y value determined with Euler's method, and the analytically determined value of y - which is a function of t Your table should have a title and appropriate column headings d. Plot your results - Be use to add a title and axis labels. Your plot should include two lines - one for the analytical solution and one for the solution based on Euler's method. Show the calculated points from Euler's method as circles - Also include a legend
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
