The three methods that this simulation provides are the Euler method, the Heun method (otherwise known as the Improved Euler method), and the Runge-Kutta method (specifically RK4).
There are two graphs shown in the simulation. The one of the left shows visually how well each method approximates the equation y = e^x, while the graph on the right shows the relative deviation of each method from the actual curve formed by y = e^x
Each numerical method of solving the differential equation y' = y is color-coded as shown on both graphs:
The number of intervals (steps) can be adjusted with the slider at the top, going up to n = 25. The button at the top right resets the simulation.
As the number of intervals increase, note how the approximations become more accurate to the original curve.

No comments:
Post a Comment