[SOLVED] CSE218 Assignment -ODE

30.00 $

Category:
Click Category Button to View Your Next Assignment | Homework

You will receive the following solution file(s) instantly after successful payment:

zip file icon ODE-ibevau.zip (94 KB)
Assignment Instructions Updated Recently? Submit Below and we will provide new Solution!
Submit New Instructions
🔒 Securely Powered by:
Secure Checkout
5/5 - (2 votes)

Solve the following ODE numerically from x=0 to x=10.

𝑑𝑦 = (𝑥 + 20𝑦) 𝑠𝑖𝑛(𝑥𝑦) 𝑑𝑥

Initial condition: y(0)=4

Apply Euler method, Heun’s method (with a single corrector), Midpoint method, Ralston’s method, and 4th order RK method (as described in the book) to solve it. Write a single function for the 2nd order RK method and pass the value of a2 to the function for implementing Heun’s method, Midpoint method and Ralston’s method.

Use the following step sizes: 0.01, 0.05, 0.1, 0.5
Generate the following graphs from the (x,y) points you get.

• For each method, plot curves for all the step sizes in one graph (total 5 graphs, 4 curves in each graph)

• For each step size, plot curves for all the methods in one graph (total 4 graphs. 5 curves in each graph)

Proper labeling should be done in every graph.

Bonus marks will be awarded if you can solve the ODE analytically and show the exact error in each step.

  • ODE-ibevau.zip