Attached is my implementation (and explanation, partly for my own sake) of RK4. I ran out of time to do anything particularly interesting with it, but it works.

Looks good.

If you want to try RK4 on something meaty ... perhaps as a lead in to another topic, check out https://en.wikipedia.org/wiki/Double_pendulum .

Or trajectories in the potential that I did my PhD thesis on :

$$ V(x,y) = \left( y - \frac{x^2}{2} \right)^2 + \frac{\mu \, x^2}{2} $$

where \( \mu = 0.1 \).

See

Tangentially related to that : Pollack and fractal dimensions

Chaos : An Introduction to Dynamical Systems - Alligood, Sauer, & Yorke

https://cs.marlboro.college /cours /spring2018 /jims_tutorials /computational_science /apr2

last modified Thu July 25 2024 12:51 am

last modified Thu July 25 2024 12:51 am

last modified | size | ||

runge_kutta.html |
Thu Jul 25 2024 12:51 am | 300K | |

runge_kutta.ipynb |
Thu Jul 25 2024 12:51 am | 42K |