Question: This exercise aims to solve the ODE problem u 1 [0.20]. - = 10u 0, u(0) = 0.2, for a) Identify the mathematical function
This exercise aims to solve the ODE problem u 1 [0.20]. - = 10u 0, u(0) = 0.2, for a) Identify the mathematical function f(u,t) in the generic ODE form u' = f(u.1). b) Implement the f(u, t) function in a Python function. c) Use the ForwardEuler function from Sect. E.1.3 to compute a numerical solu- tion of the ODE problem. Use a time step At = 5. d) Plot the numerical solution and the exact solution (7) = 0.20.1. e) Save the numerical solution to file. Decide upon a suitable file format. f) Perform simulations for smaller At values and demonstrate visually that the numerical solution approaches the exact solution.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
